You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to use the list_direct_messages api but any time I try to iterate through the items it returns I get this error
Traceback (most recent call last):
File "reply_dm.py", line 41, in
main()
File "reply_dm.py", line 36, in main
check_messages(api)
File "reply_dm.py", line 29, in check_messages
for message in tweepy.Cursor(api.list_direct_messages).items():
File "C:\Python27\bot\twitter\lib\site-packages\tweepy\cursor.py", line 195, in next
self.current_page = self.page_iterator.next()
File "C:\Python27\bot\twitter\lib\site-packages\tweepy\cursor.py", line 73, in next
**self.kargs)
File "C:\Python27\bot\twitter\lib\site-packages\tweepy\binder.py", line 250, in _call
return method.execute()
File "C:\Python27\bot\twitter\lib\site-packages\tweepy\binder.py", line 233, in execute
raise TweepError(error_msg, resp, api_code=api_error_code)
tweepy.error.TweepError: [{u'message': u'invalid cursor', u'code': 214}]
Now, I may be doing something wrong, but I tested a few other API methods such as followers and others and those worked (so I think I'm using cursors properly).
Can anyone confirm this is working in their version of Python?
The text was updated successfully, but these errors were encountered:
I've made a branch and pull request to fix this. See #1262 for more details.
I'd have liked to release the fix in a v3.8.1 patch release, but I think the change requiring parsers to handle a new return_cursors kwarg warrants waiting until a v3.9 minor version update.
Hi,
I'm trying to use the list_direct_messages api but any time I try to iterate through the items it returns I get this error
Traceback (most recent call last):
File "reply_dm.py", line 41, in
main()
File "reply_dm.py", line 36, in main
check_messages(api)
File "reply_dm.py", line 29, in check_messages
for message in tweepy.Cursor(api.list_direct_messages).items():
File "C:\Python27\bot\twitter\lib\site-packages\tweepy\cursor.py", line 195, in next
self.current_page = self.page_iterator.next()
File "C:\Python27\bot\twitter\lib\site-packages\tweepy\cursor.py", line 73, in next
**self.kargs)
File "C:\Python27\bot\twitter\lib\site-packages\tweepy\binder.py", line 250, in _call
return method.execute()
File "C:\Python27\bot\twitter\lib\site-packages\tweepy\binder.py", line 233, in execute
raise TweepError(error_msg, resp, api_code=api_error_code)
tweepy.error.TweepError: [{u'message': u'invalid cursor', u'code': 214}]
Now, I may be doing something wrong, but I tested a few other API methods such as followers and others and those worked (so I think I'm using cursors properly).
Can anyone confirm this is working in their version of Python?
The text was updated successfully, but these errors were encountered: