googleplay-api icon indicating copy to clipboard operation
googleplay-api copied to clipboard

Fixes app listing offset

Open rscmendes opened this issue 6 years ago • 1 comments

This PR is based in PR #62, which in turn is based on this comment.

This PR fixes the offset field when listing the apps. It also adds a test to check that the offset is working properly.

rscmendes avatar Feb 06 '20 22:02 rscmendes

This code works as long as the offset is below 3500, but for greater (or equal) values it throws an "String index out of range" Error ..

Traceback (most recent call last): File "test.py", line 129, in appList = server.list(cat, catList[0], 100, 3500) File "/mnt/c/Users/virde/Desktop/gpapi/venv/lib/python3.8/site-packages/gpapi/googleplay.py", line 469, in list path += "&ctntkn=" + self.get_token(int(offset)) File "/mnt/c/Users/virde/Desktop/gpapi/venv/lib/python3.8/site-packages/gpapi/googleplay.py", line 444, in get_token token = "C" + key + requests.utils.quote(code_suffix[s]) IndexError: string index out of range

Any help will be appreciated..

smfahadhassan avatar Dec 16 '20 06:12 smfahadhassan