PokemonGo-Bot icon indicating copy to clipboard operation
PokemonGo-Bot copied to clipboard

player_data not in response_dict [dev]

Open TianCNCA opened this issue 10 years ago • 13 comments

This is the log:

Traceback (most recent call last):
  File "pokecli.py", line 183, in <module>
    main()
  File "pokecli.py", line 169, in main
    bot.start()
  File "D:\New folder\PokemonGo-Bot\pokemongo_bot\__init__.py", line 30, in start
    self._setup_api()
  File "D:\New folder\PokemonGo-Bot\pokemongo_bot\__init__.py", line 166, in _setup_api
    player = response_dict['responses']['GET_PLAYER']['player_data']
KeyError: 'player_data'

Can someone help me take a look at this please. Thanks!

TianCNCA avatar Jul 23 '16 19:07 TianCNCA

Try a git pull. I had the same issue with a previous version.

pol0nium avatar Jul 23 '16 19:07 pol0nium

My code is latest. Still the same issue. I looked at the dump of response_dict but there is no 'player_data' field, only 'profile'. Tried to change that to match in the code. Didn't work.

TianCNCA avatar Jul 23 '16 19:07 TianCNCA

Hmm. Are you on master or dev branch ?

pol0nium avatar Jul 23 '16 19:07 pol0nium

I'm on dev. Sorry I forgot to add a tag.

TianCNCA avatar Jul 23 '16 19:07 TianCNCA

your pgoapi is outdated. try pip install -r requirements.txt

earthchie avatar Jul 23 '16 20:07 earthchie

It should be pgoapi-1.1.0 right? I'm still having the error.

TianCNCA avatar Jul 23 '16 20:07 TianCNCA

Have the same issue. Also have pgoapi-1.1.0.

Ecostack avatar Jul 23 '16 20:07 Ecostack

Are you using Windows or OS X?

TianCNCA avatar Jul 23 '16 20:07 TianCNCA

cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=14.04
DISTRIB_CODENAME=trusty
DISTRIB_DESCRIPTION="Ubuntu 14.04.4 LTS"

Ecostack avatar Jul 23 '16 20:07 Ecostack

Try doing a git clone into a new folder, and redoing pip install Or deleting the pgoapi folder.

CapCap avatar Jul 23 '16 20:07 CapCap

Ok, looks like a pip install --upgrade -r requirements.txt did the trick.

Ecostack avatar Jul 23 '16 20:07 Ecostack

http://pastebin.com/aL8duZpj

I am having this issue and pip says all is updated

EDIT: renaming the pgoapi folder inside the dev repo allowed it to run correctly.

DevScarabyte avatar Jul 23 '16 20:07 DevScarabyte

For anyone who have the same problem, delete whole folder and do git pull

TianCNCA avatar Jul 23 '16 22:07 TianCNCA