Skip to main content

pypi youtube2mp3 on pypi PyPI - Downloads Unit Tests

youtube2mp3

A wrapper to simplify youtube downloads with yt-dlp

Downloaded files will be tagged with mutagen.

installation

with pip

pip install youtube2mp3

usage

youtube2mp3 -d DIRECTORY -y YOUTUBE_URL

relative paths are resolved against the current working directory, a missing target directory is created. The exit code is 1 if at least one download failed.

see youtube2mp3 -h for more information

usage: youtube2mp3 [-h] -d DIRECTORY -y YOUTUBE_URL [-V]

Download youtube videos and convert them to tagged mp3 files.

options:
  -h, --help            show this help message and exit
  -d, --directory DIRECTORY
                        directory to store the files
  -y, --youtube-url YOUTUBE_URL
                        link to a youtube video or playlist. Or path to a file
                        with yt urls.
  -V, --version         show version and exit

development

The project is managed with uv. Create the virtual environment and install all dependencies

uv sync

run the tool from source

uv run youtube2mp3 -d <directory> -y <url>

run the tests (ffmpeg is required for the conversion tests)

uv run pytest

the real youtube downloads are skipped by default, enable them with

YOUTUBE2MP3_NETWORK_TESTS=1 uv run pytest

YouTube downloads need a JavaScript runtime for yt-dlp, see yt-dlp EJS (e.g. install deno).

Buy Me a Beer

Metadata

Release files for youtube2mp3 2.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for youtube2mp3 2.2.0
File Size Uploaded Provenance Actions
youtube2mp3-2.2.0.tar.gz 16.7 kB Without provenance Details for youtube2mp3-2.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for youtube2mp3 2.2.0
File Interpreter ABI Platform Actions
youtube2mp3-2.2.0-py3-none-any.whl Python 3 none any Details for youtube2mp3-2.2.0-py3-none-any.whl

Total release size: 28.6 kB

Release files / youtube2mp3-2.2.0.tar.gz

Download URL youtube2mp3-2.2.0.tar.gz
Size 16.7 kB
Tags Source
SHA-256 checksum
How to use checksums
f608fddaab4bfc10c31b73edfe8b14956e296560aab29b2db9ef42c049a5f724
BLAKE2b-256 checksum
How to use checksums
78e5abd6a8140ed4690428e5f17570b0e9f143ef21a131550b019de030260ee9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / youtube2mp3-2.2.0-py3-none-any.whl

Download URL youtube2mp3-2.2.0-py3-none-any.whl
Size 11.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
cd0abbc5eb140f57933e390b24402a1e2c23485bd4e9120b65eca7b0f16fb924
BLAKE2b-256 checksum
How to use checksums
0416b617a2b1bcbaa1b061a160e67c176c419d56308fb73c62b9b582e45ff9f9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Security for youtube2mp3 2.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page