Downloads photos and videos from twitter.
Tested with python3.7 :)
If you have questions, requests or ideas send me a mail or open an issue.
The main branch doesn't support Windows since curses is not included int the windows python libraries.
If you are using Windows please go to the logger branch. That branch uses logging instead of a curses output and is probably more stable.
I wont fix the main branch since this program will be integrated with the Twint project.
https://github.com/twintproject/twint-utils
Get prompted for input:
python3 core.py
Use a list:
python3 core.py list.txt
Dont use the username but the whole link. Like this: https://twitter.com/twitter
from twitter import Twitter
usernames = ["username1", "username2", "username3"]
location = "../Downloads"
t = Twitter(usernames=usernames, location=location)
t.start()
- Write queue to file when exit
- Detect if the photo is already downloaded before making a request (maybe with the id or something)
- Make crawling and downloading run at the same time.
- Only ignore 403 Error while downloading videos. (does youtube dl only output errors as a string or am i retarded?)
- When the program stops while downloading photos write the id of the last downloaded photo to the resume file so the crawler knows where it left off.
- Use pathlib or something so you can use it on Windows