Skip to content

A simple YouTube crawler, allows you to quickly collect data from channels, view and sort them in a table, perform SQL queries and advanced search by various parameters.

Notifications You must be signed in to change notification settings

vshulcz/youtube_crawler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

YouTubeCrawler

YouTubeCrawler is a fast, efficient, and user-friendly tool for collecting data from YouTube channels. It provides a Graphical User Interface (GUI) built with tkinter and uses its own database to store and manage the gathered data. This project leverages only the requests library, ensuring faster performance than the free YouTube API.

Installation

  1. Ensure you have the tkinter installed. On mac os, you should run in the terminal:
    brew install python-tk
  2. Clone this repository to your local machine with:
    git clone https://github.com/Shulcz/youtube_crawler.git
  3. Navigate to the Repository Directory:
    cd YouTubeCrawler
  4. Set up a Virtual Environment (Optional but Recommended):
    python -m venv venv
  • Activate the virtual environment:
    • On macOS and Linux:
    source venv/bin/activate
  1. Install Required Packages:
    pip install -r requirements.txt
  2. Run the Application:
    python main.py

This will launch the application, and you can start using its features via the GUI. Use the GUI to start crawling YouTube channels, managing your collected data, and executing SQL queries.

Usage

YouTube Crawler

Open the "YouTube Crawler" tab in the application. In the first input field, enter the channel name (from the YouTube channel URL, using "@", for example: @PewDiePie, @MrBeast). In the second input field, specify how many videos you want to parse from the channel. In the third input field, set the number of comments to collect for each video. Click the "Run Crawling" button and wait for the progress bar to fill up. After the crawling is complete, you can interact with the data using the built-in tools or for other purposes.

SQLViewer

Open the "SQLViewer" tab in the application. Choose the table you want to view from the dropdown menu. Click the "Show the table" button to display the table's contents. You can also sort the table by clicking on a column header and adjust column widths right in the application.

DataBaseExecutor

Open the "DataBaseExecutor" tab in the application. Enter any SQL query in the input field. Click the "Execute a request" button to execute the query and receive the results.

DataBaseSearcher

Open the "DataBaseSearcher" tab in the application. Choose the parameter for your search: For "User," search for users with the specified name. For "Date," input a date in the format "YYYY-MM-DD" to retrieve comments starting from that date. For "Channel," find all channels with the provided name. For "Word," display comments containing the entered word. For "Min messages," retrieve all users with a message count exceeding the specified value (integer input required).

Contributions

Contributions to YouTubeCrawler are welcome. If you have ideas for improvements or new features, please open an issue or submit a pull request.

About

A simple YouTube crawler, allows you to quickly collect data from channels, view and sort them in a table, perform SQL queries and advanced search by various parameters.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages