def limit_handled(cursor: tweepy.Cursor):
"""Wrap cursor access with rate limiting
:param cursor: The cursor to siphon
:returns: Cursor items
"""
while True:
try:
yield cursor.next()
except tweepy.RateLimitError:
time.sleep(15 * 60)
评论列表
文章目录