An automated, headless YouTube Shorts Watcher and Scraper
Original Authors:
Christian C.,
Moritz M.,
Luca S.
Related Projects:
YouTube Uploader,
Twitch Compilation Creator,
Neural Networks
Adapted for PI by:
Ed Geraghty
Searches YouTube shorts, queries recommended videos and watches them. All fully automated.
This project requires Poetry to install the required dependencies. Check out this link to install Poetry on your operating system.
Make sure you have installed Python 3.8 or later! Otherwise Step 3 will let you know that you have no compatible Python version installed.
- Clone/Download this repository
- Navigate to the root of the repository
- Run
poetry install
to create a virtual environment with Poetry - Ensure the browser you wish to use is installed on the machine.
- Run
poetry run python main.py
to run the program. Alternatively you can runpoetry shell
followed bypython main.py
. By default this connects to MS Edge Browser. To automate a different Browser use the--browser [chrome/firefox/edge]
command line option.
All of these parameters are optional and a default value will be used if they are not defined.
You can also get these definitions by running main.py --help
usage: main.py [-h] [-H] [-B {chromium,firefox,edge}] -s SEARCH_TERMS [-c CHANNEL_URL]
optional arguments:
-h, --help show this help message and exit
-H, --headless run the browser headlessly
-B {chromium,firefox,edge}, --browser {chromium,firefox,edge}
Select the driver/browser to use for executing the script. Defaults to Edge.
-s SEARCH_TERMS, --search-terms SEARCH_TERMS
This argument declares a list of search terms which get viewed.
-c CHANNEL_URL, --channel-url CHANNEL_URL
Channel URL if not declared it uses Privacy International's channel URL as default.