Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update_with_media deprecated #87

Open
scotnewsedits opened this issue Jun 2, 2020 · 0 comments
Open

update_with_media deprecated #87

scotnewsedits opened this issue Jun 2, 2020 · 0 comments

Comments

@scotnewsedits
Copy link

Tweepy has deprecated update_with_media

As a suggestion at the following approx line 86 in twitter.py ;
```
filenames = [diff.thumbnail_path, diff.screenshot_path]
media_ids = []
for filename in filenames:
res = twitter.media_upload(filename)
media_ids.append(res.media_id)
status = twitter.update_status(status=text, media_ids=media_ids)
logging.info( "Status after tweet %s" , status.id_str )
#status = twitter.update_status(status='@' + self.auth.get_username() + ' ' + text, media_ids=media_ids,in_reply_to_status_id=thread_status_id_str,)

in twitter.py this uses the newer api and attaches both images to the tweet. The commented out code is as i had not fully tested the threading of tweets where you need to reference the user_name when replying.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant