Contributing to MeTube

Contributions from the community are welcome! Whether it's submitting a bug report, requesting a feature, or writing code, your help is appreciated.

Submitting Issues and Feature Requests

Before opening a new issue, please use the search function to see if a similar issue or feature request already exists.

MeTube's development relies on community contributions. The program as it currently stands is feature-complete for the maintainer's use cases. While you are welcome to open a feature request, it is unlikely to be implemented unless you or another community member contributes the code.

Bug Reports

MeTube is primarily a user interface for yt-dlp. Most download-related issues (e.g., a specific site not working, authentication problems, post-processing errors) are likely issues with yt-dlp itself.

Before submitting a bug report, you must:

  1. Read the Troubleshooting section below.
  2. Test the download directly with the yt-dlp command-line tool inside the MeTube container. If it fails there, the issue should be reported to the yt-dlp project.
  3. If yt-dlp works correctly but MeTube does not, it is a MeTube issue. Please use the Bug Report Template on GitHub.

Troubleshooting

To test with yt-dlp directly, get a shell inside your running MeTube container. If your container is named metube, run:

docker exec -ti metube sh

Once inside the container, you are in the /app directory. Navigate to your downloads and run your test:

# Navigate to your downloads volume
cd /downloads

# Run yt-dlp with the same URL and options
yt-dlp [your-options] "<VIDEO_URL>"

This will help you determine if the issue is with the underlying tool or the MeTube interface.

Development Setup

To run MeTube locally for development, you'll need Python 3.13 and Node.js installed.

  1. Clone the repository:

    git clone https://github.com/alexta69/metube.git
    cd metube
  2. Set up the Python backend:

    Install pipenv if you don't have it, then install the dependencies from Pipfile.lock.

    pip3 install pipenv
    pipenv install
  3. Build the Angular frontend:

    Navigate to the ui directory, install Node modules, and build the application.

    cd ui
    npm install
    npm run build
    cd ..
  4. Run the application:

    Execute the main Python script using pipenv.

    pipenv run python3 app/main.py

    MeTube will now be running on http://localhost:8081. The repository includes a .vscode/launch.json file for easier debugging in Visual Studio Code.

Code Style

  • Python: Follows standard PEP 8 guidelines. The project uses pylint for linting.
  • TypeScript/Angular: Follows the standard Angular style guide. The project uses tslint.

Pull Requests

Pull requests are welcome! For new features, it's a good idea to open an issue first to discuss the implementation plan. This helps ensure your contribution aligns with the project's goals and reduces the chance of a PR not being accepted.

Continuous Integration

MeTube uses GitHub Actions for its CI/CD pipeline:

  • main.yml: This workflow triggers on pushes to the master branch. It builds and pushes multi-platform Docker images (linux/amd64, linux/arm64) to both Docker Hub and GitHub Container Registry.
  • update-yt-dlp.yml: This workflow runs on a daily schedule (cron). It checks for new versions of yt-dlp, and if one is found, it updates Pipfile.lock and commits the change, triggering a new build.