1 hour running crash - None has type <type 'NoneType'>, but expected one of: (<type 'str'>, <type 'unicode'>)
Expected Behavior
Bot should run without crashing
Actual Behavior
Bot stops running and crashes after 1 hour, giving this error
Traceback (most recent call last):
File "pokecli.py", line 521, in
I've also tried ALL the trick found about that, even adding the token on line 94, but nothing worked
Steps to Reproduce
Let the bot running until the user stops it
Other Information
OS: OSX Last dev commit Python Version: 2.7
same
python 2016-08-09 11:32:17,053 [PokemonGoBot] [INFO] [login_started] Login procedure started. Traceback (most recent call last): File "pokecli.py", line 524, in <module> main() File "pokecli.py", line 140, in main report_summary(bot) File "pokecli.py", line 149, in report_summary metrics.capture_stats() File "/root/Bot/pokemongo_bot/metrics.py", line 76, in capture_stats response_dict = request.call() File "/root/Bot/pokemongo_bot/api_wrapper.py", line 106, in call result = self._call() File "/root/Bot/pokemongo_bot/api_wrapper.py", line 63, in _call return PGoApiRequest.call(self) File "/root/Bot/src/pgoapi/pgoapi/pgoapi.py", line 220, in call response = request.request(self._api_endpoint, self._req_method_list, self.get_position()) File "/root/Bot/src/pgoapi/pgoapi/rpc_api.py", line 126, in request request_proto = self._build_main_request(subrequests, player_position) File "/root/Bot/src/pgoapi/pgoapi/rpc_api.py", line 216, in _build_main_request request.auth_info.token.contents = self._auth_provider.get_access_token() File "/root/Bot/lib/python2.7/site-packages/google/protobuf/internal/python_message.py", line 669, in field_setter new_value = type_checker.CheckValue(new_value) File "/root/Bot/lib/python2.7/site-packages/google/protobuf/internal/type_checkers.py", line 176, in CheckValue raise TypeError(message) TypeError: None has type <type 'NoneType'>, but expected one of: (<type 'str'>, <type 'unicode'>)
Same - 1 hour, bot crashes
Same problem
2016-08-09 04:09:49,761 [RecycleItems] [INFO] [item_discarded] Discarded 1x Greatball (maximum 90).
2016-08-09 04:09:49,768 [MoveToFort] [INFO] [moving_to_lured_fort] Moving towards pokestop Ibirapuera Escultura - 0.07km (attraction of lure 0.07km)
2016-08-09 04:10:03,754 [ cli] [INFO]
2016-08-09 04:10:03,755 [ cli] [INFO] Ran for 0:59:59
2016-08-09 04:10:03,755 [ cli] [INFO] Total XP Earned: 14210 Average: 14214.64/h
2016-08-09 04:10:03,755 [ cli] [INFO] Travelled 1.71km
2016-08-09 04:10:03,755 [ cli] [INFO] Visited 45 stops
2016-08-09 04:10:03,755 [ cli] [INFO] Encountered 26 pokemon, 26 caught, 33 released, 11 evolved, 0 never seen before
2016-08-09 04:10:03,755 [ cli] [INFO] Threw 33 pokeballs
2016-08-09 04:10:03,755 [ cli] [INFO] Earned 5053 Stardust
2016-08-09 04:10:03,755 [ cli] [INFO]
2016-08-09 04:10:03,756 [ cli] [INFO] Highest CP Pokemon: Pinsir [CP: 535] [IV: 15/11/14] Potential: 0.89
2016-08-09 04:10:03,756 [ cli] [INFO] Most Perfect Pokemon: Magikarp [CP: 18] [IV: 15/12/13] Potential: 0.89
Traceback (most recent call last):
File "pokecli.py", line 502, in <module>
main()
File "pokecli.py", line 133, in main
raise e
TypeError: None has type <type 'NoneType'>, but expected one of: (<type 'str'>, <type 'unicode'>)
Removed and updated pgoapi. 1+ hour running right now. No crash. Will update if it crashes (or not). ## Update: Total Run time 1h 08m Traceback (most recent call last): File "/usr/lib/python2.7/logging/init.py", line 851, in emit msg = self.format(record) File "/usr/lib/python2.7/logging/init.py", line 724, in format return fmt.format(record) File "/usr/lib/python2.7/logging/init.py", line 464, in format record.message = record.getMessage() File "/usr/lib/python2.7/logging/init.py", line 328, in getMessage msg = msg % self.args TypeError: not all arguments converted during string formatting Logged from file init.py, line 547
Followed by Traceback (most recent call last):
File "pokecli.py", line 493, in
Duplicate of #2864, #2874
update to latest dev and upgrade pip packages
This should be resolved with #3241 being merged days ago.