Raises an exception if a duplcate status is posted, documentation suggests otherwise
See original GitHub issueIf update_status is called with a duplicate status, a TweepError is raised:
File "/usr/local/lib/python2.7/dist-packages/tweepy/api.py", line 194, in update_status
)(post_data=post_data, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/tweepy/binder.py", line 245, in _call
return method.execute()
File "/usr/local/lib/python2.7/dist-packages/tweepy/binder.py", line 229, in execute
raise TweepError(error_msg, resp, api_code=api_error_code)
tweepy.error.TweepError: [{u'message': u'Status is a duplicate.', u'code': 187}]
Although the documentation says “Statuses that are duplicates or too long will be silently ignored.”
Issue Analytics
- State:
- Created 7 years ago
- Comments:6 (2 by maintainers)
Top Results From Across the Web
Why does upsert cause a DUPLICATE_VALUE error?
When I upsert two records with identical Name/ID, but otherwise different values, in two separate upsert statement, one record results, as ...
Read more >711.3 – Admissibility of Duplicates [Rule 1003] - NC PRO
A duplicate is admissible to the same extent as an original unless (1) a genuine question is raised as to the authenticity of...
Read more >Catch duplicate entry Exception - java - Stack Overflow
I use spring so we resolve it by org.springframework.dao.DataIntegrityViolationException try { ao_history_repository.save(new AoHistory(.
Read more >21.7.9 BMF Duplicate Filing Conditions - IRS
If you determine the return is an amended/corrected/adjusted return, input a Transaction Code (TC) 971 Action Code (AC) 010 to set the -A...
Read more >Error handling with DynamoDB - AWS Documentation
If the request is unsuccessful, DynamoDB returns an error. Each error has three components: An HTTP status code (such as 400 ). An...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
You can use an
if
block inside theexcept
block to specify different treatment of different error types.Twitter is preventing you from posting the duplicate text, so the only way around that is to just wait.
Just change the contents of api.update_status and your program should work fine