Twitter Video Tools is a multi-processing supported video downloader, supports videos from twitter (or specific user from twitter) && monsnode.
Project description
This project is deprecated. Please look at https://github.com/code-yeongyu/twitter_video_tools_v2
Twitter Video Tools
- A multi-processing supported video downloader
- supports downloading videos from twitter (or specific user from twitter) && monsnode.
Install
with PIP
pip install twitter-video-tools
with Poetry
poetry add twitter-video-tools
Usage
Command line
python3 -m twitter_video_tools [link]
Supported link types:
- Video tweet: https://twitter.com/twtvtOfficial/status/1599748329927499777
- Video from monsnode: https://monsnode.com/v1506575871309589251
- Specific user's uploaded videos: https://twitter.com/twtvtOfficial/media
- Specific user's liked videos: https://twitter.com/twtvtOfficial/likes
Python Embedding
from twitter_video_tools import TwitterVideoTools
with TwitterVideoTools() as twitter_video_tools:
twitter_video_tools.download_from_user('twtvtOfficial')
Contribution
Prerequisites
- Python 3.9
- poetry
- code editor (vscode recommended)
Overview of Development Environments
-
Local
-
GitHub Actions
All-in-one
gh repo clone code-yeongyu/twitter_video_tools
python3 -m pip install poetry
poetry install # install dependencies
code --install-extension emeraldwalk.RunOnSave # to force single quote
code --install-extension tamasfe.even-better-toml # for handling toml
Done!
Test
poetry shell
inv test
Inspirations
yt-dlp
- Inspired me to start this project. yt-dlp is a fork project of youtube-dl.
- Since the cookie option of yt-dlp's twitter extractor is not working, I decided to make my own project, using browser automation.
playwright
- Microsoft's browser automation module.
- Another major project to made me to start this project. I made up my mind to make TwitterVideoTools to experience playwright.
- It would be so painful to imagine making this project with selenium, but I enjoyed a lot while writing the twitter crawler part thanks to playwright.
typer
- Ever since I started this project, I always wanted to support CLI with typer's awesome development experience.
- TwitterVideoTools' CLI is written with typer, and it is so beautiful and easy to use at the same time.
pyright & mypy & monkeytype
- These three tools helped me to write fully-typed python code.
- I won't start my python project without these tools.
my python project template
- I made this template to make my python project development experience better.
- Safe & Convient development environment
- Strict type checking
- Amazing linters & formatters
- Unit test supported
- Safe & Convient development environment
- This project is also based on this template.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file twitter_video_tools-2023.4.15.tar.gz
.
File metadata
- Download URL: twitter_video_tools-2023.4.15.tar.gz
- Upload date:
- Size: 11.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.4.2 CPython/3.9.16 Linux/5.15.0-1035-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ac4344a7a85d0440c3cc51d10d5bd2c5285650d08c846a54cd317b3f87356ac0 |
|
MD5 | fb5f889fc6d2bd64c2a24328d984e247 |
|
BLAKE2b-256 | 66fe26a6fa971ba3725f24dfd0c1741c764674c6460b9da60e219b810928ffd0 |
File details
Details for the file twitter_video_tools-2023.4.15-py3-none-any.whl
.
File metadata
- Download URL: twitter_video_tools-2023.4.15-py3-none-any.whl
- Upload date:
- Size: 13.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.4.2 CPython/3.9.16 Linux/5.15.0-1035-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 59a0211ecc9c5c5a323e799a82694e066a4bcc2ea056d3d8e2c6571b0abf0594 |
|
MD5 | 2154b94872b4a99126e7c6d74870ea04 |
|
BLAKE2b-256 | 50fb4d91c7fe7ae798a41946f4f30c6201be04059b8351f70be2598a68f75b86 |