Skip to content

Commit

Permalink
Let the user know that the maps api key exceeded its limits. (#1989)
Browse files Browse the repository at this point in the history
  • Loading branch information
wcastello authored and fredrik-hellmangroup committed Aug 1, 2016
1 parent a809498 commit 494bc05
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pokecli.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
from datetime import timedelta
from getpass import getpass
from pgoapi.exceptions import NotLoggedInException
from geopy.exc import GeocoderQuotaExceeded

from pokemongo_bot import PokemonGoBot, TreeConfigBuilder
from pokemongo_bot import logger
Expand Down Expand Up @@ -76,6 +77,9 @@ def main():
except NotLoggedInException:
logger.log('[x] Error while connecting to the server, please wait %s minutes' % config.reconnecting_timeout, 'red')
time.sleep(config.reconnecting_timeout * 60)
except GeocoderQuotaExceeded:
logger.log('[x] The given maps api key has gone over the requests limit.', 'red')
finished = True
except:
# always report session summary and then raise exception
report_summary(bot)
Expand Down

0 comments on commit 494bc05

Please sign in to comment.