Skip to content

From last saved cursor? #605

Closed Answered by Harmon758
jobqueue asked this question in Questions
Discussion options

You must be logged in to vote

If the pagination is by cursor, as is the case with API.followers_ids, then the iterator you're using is a CursorIterator returned by Cursor.pages:

tweepy/tweepy/cursor.py

Lines 11 to 31 in 8ce6e8c

class Cursor(object):
"""Pagination helper class"""
def __init__(self, method, *args, **kargs):
if hasattr(method, 'pagination_mode'):
if method.pagination_mode == 'cursor':
self.iterator = CursorIterator(method, args, kargs)
elif method.pagination_mode == 'id':
self.iterator = IdIterator(method, args, kargs)
elif method.pagination_mode == 'page':
self.iterator = PageIterator(method, args, kargs)
else:
raise TweepError('Inv…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by Harmon758
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Question This is a question Discussion This was converted/moved from/to a discussion
3 participants
Converted from issue

This discussion was converted from issue #605 on December 16, 2020 07:29.