Open Kazpers opened 7 years ago
+1 to this. Same thing on Ubuntu
Same issue. I have it running for now by creating a loop within main so it doesnt log in every time.
however I would like to re-login every 20 min because after a while no pokis are returned. I can't figure out how to re-login without running into this issue.
+1 please provide a fix
It does work with google auth but only works once with PTC.
same issue here running on Raspberry Pi 1
+1 on this. PTC fails on second run while a google account works fine.
im not sure how correct of a fix this is.... but i have it working by creating a loop in main around the steps loop instead of using threading.
As @StraightCircle did, I just wrapped the contents of main in a while True:
after the login method is called and commented out the register_background_thread()
This isn't a true fix as it will eventually and silently time out and you'll loop but never find any pokemon.
+1 Had also this issue few times recently, but I also got this (pretty close) one : #51
Same here , could a possible solution be to alternate between two PTC accounts every 3 or 4 cicles ?
Expected Behavior
When the program is run first time it logs in and scans for Pokemon as expected. It would be expected to continue doing so subsequently.
Current Behavior
However it resets login_session after each step of the search (found by printing debug info), meaning that it has to re-login before the second run. This re-login always fails with "Wrong username/password" causing the script to grind to a halt.
Possible Solution
I've implemented a workaround by not resetting login_session when the try block fails, but I assume this might cause unanticipated issues down the road.
Steps to Reproduce (for bugs)
Your Environment
Python 2.7 on Debian (Jessie). I have a hunch this might be due to the use of PTC accounts rather than google accounts, but I have no spare google accounts to test with. Behaviour has been observed using both an existing and a newly created PTC account.