Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

exit on fail

  • Loading branch information...
commit ed48cdb05a119c1abf2c763154e2a83c9196459c 1 parent cfda00d
Santiago authored
Showing with 1 addition and 0 deletions.
  1. +1 −0  task_python.py
1  task_python.py
View
@@ -20,6 +20,7 @@ def get_messages_from_user(user, page=0):
try:
messages = api.user_timeline(user_id=user,count=200, page=page)
except:
+ sys.exit()
print "We are on the limit, wait 15 secs, and call this again"
time.sleep(15)
return get_messages_from_user(user,page)
Please sign in to comment.
Something went wrong with that request. Please try again.