Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The Usage: instruction suggests writing "url" between yt-dlp and the actual video and that's redundant #9556

Closed
10 tasks done
rdrg109 opened this issue Mar 29, 2024 · 1 comment
Labels
question Question

Comments

@rdrg109
Copy link

rdrg109 commented Mar 29, 2024

DO NOT REMOVE OR SKIP THE ISSUE TEMPLATE

  • I understand that I will be blocked if I intentionally remove or skip any mandatory* field

Checklist

Provide a description that is worded well enough to be understood

In the latest version 2024.03.10, the information on how to use the command which is shown when executing $ yt-dlp (i.e. without any argument) and $ yt-dlp --help is misleading because it suggests writing url between yt-dlp and the actual url of the video.

The instruction shows Usage: yt-dlp [OPTIONS] URL [URL...], but it should be Usage: yt-dlp [OPTIONS] [URL...].

$ ~/Downloads/yt-dlp  --version
2024.03.10
$ ~/Downloads/yt-dlp           

Usage: yt-dlp [OPTIONS] URL [URL...]

yt-dlp: error: You must provide at least one URL.
Type yt-dlp --help to see a list of all options.
$ ~/Downloads/yt-dlp --help | head -n 3
Usage: yt-dlp [OPTIONS] URL [URL...]

Options:

The "Complete Verbose Output" code block contains the complete output of running yt-dlp -vU. The specific error that is produced by writing url between yt-dlp and the url of the video is shown below.

[CommonMistakes] Extracting URL: url
ERROR: [CommonMistakes] You've asked yt-dlp to download the URL "url". That doesn't make any sense. Simply remove the parameter in your command or configuration.
  File "/home/rodrigo/Downloads/yt-dlp/yt_dlp/extractor/common.py", line 732, in extract
    ie_result = self._real_extract(url)
  File "/home/rodrigo/Downloads/yt-dlp/yt_dlp/extractor/commonmistakes.py", line 25, in _real_extract
    raise ExtractorError(msg, expected=True)

Provide verbose output that clearly demonstrates the problem

  • Run your yt-dlp command with -vU flag added (yt-dlp -vU <your command line>)
  • If using API, add 'verbose': True to YoutubeDL params instead
  • Copy the WHOLE output (starting with [debug] Command-line config) and insert it below

Complete Verbose Output

$ ~/Downloads/yt-dlp -vU url 'https://www.youtube.com/watch?v=W9nZ6u15yis'
[debug] Command-line config: ['-vU', 'url', 'https://www.youtube.com/watch?v=W9nZ6u15yis']
[debug] Encodings: locale UTF-8, fs utf-8, pref UTF-8, out utf-8, error utf-8, screen utf-8
[debug] yt-dlp version stable@2024.03.10 from yt-dlp/yt-dlp [615a84447] (zip)
[debug] Python 3.10.12 (CPython x86_64 64bit) - Linux-6.5.0-26-generic-x86_64-with-glibc2.35 (OpenSSL 3.0.2 15 Mar 2022, glibc 2.35)
[debug] exe versions: ffmpeg 4.4.2 (setts), ffprobe 4.4.2, rtmpdump 2.4
[debug] Optional libraries: Cryptodome-3.11.0, brotli-1.0.9, certifi-2020.06.20, mutagen-1.45.1, pyxattr-0.7.2, requests-2.25.1, secretstorage-3.3.1, sqlite3-3.37.2, urllib3-1.26.5, websockets-9.1
[debug] Proxy map: {}
[debug] Request Handlers: urllib
[debug] Loaded 1803 extractors
[debug] Fetching release info: https://api.github.com/repos/yt-dlp/yt-dlp/releases/latest
Latest version: stable@2024.03.10 from yt-dlp/yt-dlp
yt-dlp is up to date (stable@2024.03.10 from yt-dlp/yt-dlp)
[CommonMistakes] Extracting URL: url
ERROR: [CommonMistakes] You've asked yt-dlp to download the URL "url". That doesn't make any sense. Simply remove the parameter in your command or configuration.
  File "/home/rodrigo/Downloads/yt-dlp/yt_dlp/extractor/common.py", line 732, in extract
    ie_result = self._real_extract(url)
  File "/home/rodrigo/Downloads/yt-dlp/yt_dlp/extractor/commonmistakes.py", line 25, in _real_extract
    raise ExtractorError(msg, expected=True)

[youtube] Extracting URL: https://www.youtube.com/watch?v=W9nZ6u15yis
[youtube] W9nZ6u15yis: Downloading webpage
[youtube] W9nZ6u15yis: Downloading ios player API JSON
[youtube] W9nZ6u15yis: Downloading android player API JSON
[youtube] W9nZ6u15yis: Downloading m3u8 information
[debug] Sort order given by extractor: quality, res, fps, hdr:12, source, vcodec:vp9.2, channels, acodec, lang, proto
[debug] Formats sorted by: hasvid, ie_pref, quality, res, fps, hdr:12(7), source, vcodec:vp9.2(10), channels, acodec, lang, proto, size, br, asr, vext, aext, hasaud, id
[debug] Default format spec: bestvideo*+bestaudio/best
[info] W9nZ6u15yis: Downloading 1 format(s): 244+251
[debug] Invoking http downloader on "https://rr6---sn-uqx2-aph6.googlevideo.com/videoplayback?expire=1711699110&ei=RiAGZubkE_Pd-LAPi_emoA0&ip=2001%3A1388%3A13a7%3A14a4%3Af911%3A6f0f%3Aaad0%3A279&id=o-AJFRDMboL7AnjcVq5bcrUQfiPUzbWbFQDYQ8i2NoLcSO&itag=244&source=youtube&requiressl=yes&xpc=EgVo2aDSNQ%3D%3D&mh=YJ&mm=31%2C29&mn=sn-uqx2-aph6%2Csn-njaeyn7s&ms=au%2Crdu&mv=m&mvi=6&pl=47&initcwndbps=1148750&vprv=1&svpuc=1&mime=video%2Fwebm&gir=yes&clen=9412&dur=10.000&lmt=1671760292336686&mt=1711677172&fvip=3&keepalive=yes&fexp=51141542&c=IOS&txp=443E434&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cxpc%2Cvprv%2Csvpuc%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&sig=AJfQdSswRAIgW4WnoVplStgmGEPWwDazBYDVnbmdyvmCw_oQ5b8qb-ACIFiNilrrOJ794X3TejEIzwU4GGPsd8pi5k7jFeLLMnAl&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALClDIEwRgIhAPa833eTQowGC40xrO4wH5b541G6ggrIdLZMHQWX7qhRAiEAt40H01DDy28aWWxAcMqoBodvjCejiqHe5oBbsrboYbQ%3D"
[download] Destination: Black Screen 10 seconds [W9nZ6u15yis].f244.webm
[download] 100% of    9.19KiB in 00:00:00 at 972.25KiB/s
[debug] Invoking http downloader on "https://rr6---sn-uqx2-aph6.googlevideo.com/videoplayback?expire=1711699110&ei=RiAGZveWH7_41sQPpKupsAM&ip=2001%3A1388%3A13a7%3A14a4%3Af911%3A6f0f%3Aaad0%3A279&id=o-ADa8x41qGx5aZPuodfVIk3sZFvusiorxLKcsTNCgA56z&itag=251&source=youtube&requiressl=yes&xpc=EgVo2aDSNQ%3D%3D&mh=YJ&mm=31%2C29&mn=sn-uqx2-aph6%2Csn-njaeyn7s&ms=au%2Crdu&mv=m&mvi=6&pl=47&initcwndbps=1148750&vprv=1&svpuc=1&mime=audio%2Fwebm&gir=yes&clen=4870&dur=10.101&lmt=1671759752307491&mt=1711677172&fvip=3&keepalive=yes&fexp=51141542&c=ANDROID&txp=4432434&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cxpc%2Cvprv%2Csvpuc%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&sig=AJfQdSswRAIgQ6OMl-DiUFyoFqYmZ7urQeEJeD-Kf17LvJkvOV3w5oICIDVfFJECeCrihBsNDld8u1A0vWkT5dMS3FlQizlCWcSH&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALClDIEwRAIgDg9S2qUX4g7DQiZZB-cV4wunUPzIUkyVecoA6rrcB50CIE9yq8L0mwMh7qK9Rw5rMbY7iQfIE0s1NbUZ0OTNGbRy"
[download] Destination: Black Screen 10 seconds [W9nZ6u15yis].f251.webm
[download] 100% of    4.76KiB in 00:00:00 at 544.73KiB/s
[Merger] Merging formats into "Black Screen 10 seconds [W9nZ6u15yis].webm"
[debug] ffmpeg command line: ffmpeg -y -loglevel repeat+info -i 'file:Black Screen 10 seconds [W9nZ6u15yis].f244.webm' -i 'file:Black Screen 10 seconds [W9nZ6u15yis].f251.webm' -c copy -map 0:v:0 -map 1:a:0 -movflags +faststart 'file:Black Screen 10 seconds [W9nZ6u15yis].temp.webm'
Deleting original file Black Screen 10 seconds [W9nZ6u15yis].f251.webm (pass -k to keep)
Deleting original file Black Screen 10 seconds [W9nZ6u15yis].f244.webm (pass -k to keep)
/tmp
$ echo $?
1
@rdrg109 rdrg109 added bug Bug that is not site-specific triage Untriaged issue labels Mar 29, 2024
@bashonly
Copy link
Member

The instruction shows Usage: yt-dlp [OPTIONS] URL [URL...], but it should be Usage: yt-dlp [OPTIONS] [URL...].

The [URL...] is to signify that you can optionally pass multiple URLs beyond the first URL (which is required, as the program errors if you don't pass one)

@bashonly bashonly added question Question and removed bug Bug that is not site-specific triage Untriaged issue labels Mar 29, 2024
@bashonly bashonly closed this as completed Apr 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Question
Projects
None yet
Development

No branches or pull requests

2 participants