ytdl-org / youtube-dl

Command-line program to download videos from YouTube.com and other video sites
http://ytdl-org.github.io/youtube-dl/
The Unlicense
132.23k stars 10.03k forks source link

[YouTube] Signature videos return 403 forbidden sporadically from multiple locations #24713

Closed MSauce closed 4 years ago

MSauce commented 4 years ago

Checklist

Verbose log

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['--verbose', 'https://www.youtube.com/watch?v=Vs6sWjiE9Yo']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2020.03.24
[debug] Python version 3.8.0 (CPython) - macOS-10.15.4-x86_64-i386-64bit
[debug] exe versions: ffmpeg 4.2.2, ffprobe 4.2.2, rtmpdump 2.4
[debug] Proxy map: {}
[youtube] Vs6sWjiE9Yo: Downloading webpage
[youtube] {18} signature length 112, html5 player vflset
[youtube] {137} signature length 108, html5 player vflset
[youtube] {248} signature length 108, html5 player vflset
[youtube] {136} signature length 112, html5 player vflset
[youtube] {247} signature length 108, html5 player vflset
[youtube] {135} signature length 108, html5 player vflset
[youtube] {244} signature length 112, html5 player vflset
[youtube] {134} signature length 112, html5 player vflset
[youtube] {243} signature length 112, html5 player vflset
[youtube] {133} signature length 112, html5 player vflset
[youtube] {242} signature length 112, html5 player vflset
[youtube] {160} signature length 112, html5 player vflset
[youtube] {278} signature length 112, html5 player vflset
[youtube] {140} signature length 108, html5 player vflset
[youtube] {249} signature length 112, html5 player vflset
[youtube] {250} signature length 112, html5 player vflset
[youtube] {251} signature length 112, html5 player vflset
[debug] Default format spec: bestvideo+bestaudio/best
WARNING: Requested formats are incompatible for merge and will be merged into mkv.
[debug] Invoking downloader on 'https://r5---sn-5ualdn7r.googlevideo.com/videoplayback?expire=1586502501&ei=BMePXtzHOayYkATIxK7ADQ&ip=XXXXXXXXXXX&id=o-AAH0LVoUlAR7RQ1qGwQvTPRuyctCFU5JhzcD7iKPqh6K&itag=137&aitags=133%2C134%2C135%2C136%2C137%2C160%2C242%2C243%2C244%2C247%2C248%2C278&source=youtube&requiressl=yes&mh=Ks&mm=31%2C29&mn=sn-5ualdn7r%2Csn-5uaeznkl&ms=au%2Crdu&mv=m&mvi=4&pl=21&gcr=us&initcwndbps=891250&vprv=1&mime=video%2Fmp4&gir=yes&clen=13539610&dur=156.840&lmt=1569617025630284&mt=1586480860&fvip=5&keepalive=yes&beids=9466585&c=WEB&txp=8311222&sparams=expire%2Cei%2Cip%2Cid%2Caitags%2Csource%2Crequiressl%2Cgcr%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRQIhAIEA4w3kS1womr49qUNdh7X_1lgpaqrXG1UHaqBREOw0AiAzqzIdcowPg-N4dnZH_fJ8cZas3R8Lf2PHlH6Nj5TDdQ%3D%3D&sig=3E777ERE4ptxjqiscEOQz9-1bIMNfwXTJYu9tIti7Tr23jV0BICMYEARq7df8huONwV0uC4INSsqOY_Yn_o0Lkg2lb5rhNgIARwsLlPpJk&ratebypass=yes'
ERROR: unable to download video data: HTTP Error 403: Forbidden
Traceback (most recent call last):
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 1921, in process_info
    partial_success = dl(fname, new_info)
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 1866, in dl
    return fd.download(name, info)
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/common.py", line 366, in download
    return self.real_download(filename, info_dict)
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/http.py", line 341, in real_download
    establish_connection()
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/http.py", line 109, in establish_connection
    ctx.data = self.ydl.urlopen(request)
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 2239, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 531, in open
    response = meth(req, response)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 640, in http_response
    response = self.parent.error(
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 569, in error
    return self._call_chain(*args)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 502, in _call_chain
    result = func(*args)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 649, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden

Another location and video:

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['https://www.youtube.com/watch?v=WSg4sE0k5PY', '--verbose']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2020.03.24
[debug] Python version 3.8.2 (CPython) - Linux-4.15.0-76-generic-x86_64-with-glibc2.27
[debug] exe versions: ffmpeg 3.4.6, ffprobe 3.4.6
[debug] Proxy map: {}
[youtube] WSg4sE0k5PY: Downloading webpage
[youtube] {18} signature length 112, html5 player vflset
[youtube] {137} signature length 112, html5 player vflset
[youtube] {136} signature length 112, html5 player vflset
[youtube] {135} signature length 112, html5 player vflset
[youtube] {134} signature length 112, html5 player vflset
[youtube] {133} signature length 112, html5 player vflset
[youtube] {160} signature length 112, html5 player vflset
[youtube] {140} signature length 112, html5 player vflset
[youtube] {249} signature length 112, html5 player vflset
[youtube] {250} signature length 112, html5 player vflset
[youtube] {251} signature length 112, html5 player vflset
[debug] Default format spec: bestvideo+bestaudio/best
WARNING: Requested formats are incompatible for merge and will be merged into mkv.
[debug] Invoking downloader on 'https://r1---sn-p5qlsndr.googlevideo.com/videoplayback?expire=1586505050&ei=-tCPXsrIDYGL8gSCiZPIBw&ip=XXXXXXXX&id=o-AJXFGqURHkbncbkHOZnVpzWXvTPYURfZmEcRHte0LSB2&itag=137&aitags=133%2C134%2C135%2C136%2C137%2C160&source=youtube&requiressl=yes&mh=Gd&mm=31%2C26&mn=sn-p5qlsndr%2Csn-4g5edney&ms=au%2Conr&mv=m&mvi=0&pl=21&gcr=pe&initcwndbps=417500&vprv=1&mime=video%2Fmp4&gir=yes&clen=24271081&dur=395.200&lmt=1532365167617179&mt=1586483323&fvip=1&keepalive=yes&c=WEB&sparams=expire%2Cei%2Cip%2Cid%2Caitags%2Csource%2Crequiressl%2Cgcr%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRQIgECeJEo-oiiBaUtBZYFsPl14gpJ8sh8ewHPMvPf2hOLMCIQC3R3DBRT042RhF5GTLSCsfor8gUGnzzZHRYxB7xI7HsA%3D%3D&sig=0PlLswRQIhAMrZsSSkdUkL8re3qUP5YX903K-RA8EHwP30X64Av8=pAiBkOvteovBv5844prqcReakbNlmmTosg3MLcRLfLpcG_A===888&ratebypass=yes'
ERROR: unable to download video data: HTTP Error 403: Forbidden
Traceback (most recent call last):
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 1921, in process_info
    partial_success = dl(fname, new_info)
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 1866, in dl
    return fd.download(name, info)
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/common.py", line 366, in download
    return self.real_download(filename, info_dict)
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/http.py", line 341, in real_download
    establish_connection()
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/http.py", line 109, in establish_connection
    ctx.data = self.ydl.urlopen(request)
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 2239, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 531, in open
    response = meth(req, response)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 640, in http_response
    response = self.parent.error(
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 569, in error
    return self._call_chain(*args)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 502, in _call_chain
    result = func(*args)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 649, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden

Description

I understand you are used to seeing many 403 bug reports that are just throttling/client side/provider site issues. This is NOT a duplicate and only seems to be happening in certain videos with signatures. The videos are all available publicly without an account from my location.

I am experiencing this from multiple locations and environments. It is a new issue that I only started noticing in the last week and it is not consistent. If you attempt the same file over and over you will see mixed successes and errors.

dstftw commented 4 years ago
> py -3.7 .\youtube_dl\__main__.py https://www.youtube.com/watch?v=Vs6sWjiE9Yo
[youtube] Vs6sWjiE9Yo: Downloading webpage
WARNING: Requested formats are incompatible for merge and will be merged into mkv.
[download] Destination: Villemann-Vs6sWjiE9Yo.f137.mp4
[download] 100% of 12.91MiB in 00:06
[download] Destination: Villemann-Vs6sWjiE9Yo.f251.webm
[download] 100% of 2.72MiB in 00:01
[ffmpeg] Merging formats into "Villemann-Vs6sWjiE9Yo.mkv"
Deleting original file Villemann-Vs6sWjiE9Yo.f137.mp4 (pass -k to keep)
Deleting original file Villemann-Vs6sWjiE9Yo.f251.webm (pass -k to keep)
> py -3.7 .\youtube_dl\__main__.py https://www.youtube.com/watch?v=WSg4sE0k5PY
[youtube] WSg4sE0k5PY: Downloading webpage
WARNING: Requested formats are incompatible for merge and will be merged into mkv.
[download] Destination: A N° 2-WSg4sE0k5PY.f137.mp4
[download] 100% of 23.15MiB in 00:09
[download] Destination: A N° 2-WSg4sE0k5PY.f251.webm
[download] 100% of 7.32MiB in 00:02
[ffmpeg] Merging formats into "A N° 2-WSg4sE0k5PY.mkv"
Deleting original file A N° 2-WSg4sE0k5PY.f137.mp4 (pass -k to keep)
Deleting original file A N° 2-WSg4sE0k5PY.f251.webm (pass -k to keep)
triplesixman commented 4 years ago

Same problem and yet your topic has also been closed lol Is it random? If you retry the same download a few seconds later, does it work?

MSauce commented 4 years ago

Results seem completely random on signature videos. Sometimes it completes and merges normally and sometimes it gets 403 on the invoke download. It is almost certainly a signature issue (and new) and if Sergey refuses to acknowledge it I will try to fix it myself. On Apr 10, 2020, 6:14 AM -0400, titirino159 notifications@github.com, wrote:

Same problem and yet your topic has also been closed lol Is it random? If you retry the same download a few seconds later, does it work? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

MSauce commented 4 years ago

Sergey - are you trying to say this is somehow python 3.8 related? Is that why your responses specifically use 3.7? Did you try each video 10+ times to see if you can reproduce the random errors?

I’ve been using YouTube-dl with 3.8 for 4 months without issue.

On Apr 10, 2020, 6:14 AM -0400, titirino159 notifications@github.com, wrote:

Same problem and yet your topic has also been closed lol Is it random? If you retry the same download a few seconds later, does it work? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

MSauce commented 4 years ago

Seems like they are also working on this issue here: https://github.com/Tyrrrz/YoutubeExplode/issues/349 (cc: @dstftw)

I’m finding some tickets on every YouTube downloading project.

At first they thought it was just an age-gate issue before realizing it’s happening on non age-gated videos. On Apr 10, 2020, 8:08 AM -0400, Mazin Khoury cm@monstaboyent.com, wrote:

Sergey - are you trying to say this is somehow python 3.8 related? Is that why your responses specifically use 3.7? Did you try each video 10+ times to see if you can reproduce the random errors?

I’ve been using YouTube-dl with 3.8 for 4 months without issue.

On Apr 10, 2020, 6:14 AM -0400, titirino159 notifications@github.com, wrote:

Same problem and yet your topic has also been closed lol Is it random? If you retry the same download a few seconds later, does it work? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

Hrxn commented 4 years ago

Can you rule out something interfering on your local side? Because the way youtube-dl downloads from YT (unsteady, in bursts etc.) might trigger some application firewall, gateway, or router.

MSauce commented 4 years ago

I've been able to reproduce it on my MBP locally as well as in 2 different data centers on Ubuntu.

Hrxn commented 4 years ago

Yeah, data centers might cause issues, not because of a blanket IP address ban, but they can be identified (depending on their size, and peering etc.) by their ASN, and Google/YT definitely handles incoming connections differently depending on ASN.

MSauce commented 4 years ago

Right, I understand. But why would I be able to reproduce it locally on my home ISP? Also, it's only happening on signature videos and is not consistent (sometimes it works, sometimes it doesn't).

Hrxn commented 4 years ago

Yeah residential connections ("normal" ISPs) should definitely work..

Not sure what you mean with signature videos, but if you have a link to a video right now that is not working for you, I can test that quickly here on my end.

MSauce commented 4 years ago

Here is a better illustration of the randomness:

youtube-dl --verbose https://www.youtube.com/watch\?v\=EwM8Y7h2TcA
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['--verbose', 'https://www.youtube.com/watch?v=EwM8Y7h2TcA']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2020.03.24
[debug] Python version 3.8.0 (CPython) - macOS-10.15.4-x86_64-i386-64bit
[debug] exe versions: ffmpeg 4.2.2, ffprobe 4.2.2, rtmpdump 2.4
[debug] Proxy map: {}
[youtube] EwM8Y7h2TcA: Downloading webpage
[youtube] {18} signature length 112, html5 player vflset
[youtube] {137} signature length 112, html5 player vflset
[youtube] {248} signature length 112, html5 player vflset
[youtube] {136} signature length 108, html5 player vflset
[youtube] {247} signature length 108, html5 player vflset
[youtube] {135} signature length 112, html5 player vflset
[youtube] {244} signature length 112, html5 player vflset
[youtube] {134} signature length 112, html5 player vflset
[youtube] {243} signature length 112, html5 player vflset
[youtube] {133} signature length 112, html5 player vflset
[youtube] {242} signature length 108, html5 player vflset
[youtube] {160} signature length 112, html5 player vflset
[youtube] {278} signature length 108, html5 player vflset
[youtube] {140} signature length 112, html5 player vflset
[youtube] {249} signature length 108, html5 player vflset
[youtube] {250} signature length 108, html5 player vflset
[youtube] {251} signature length 112, html5 player vflset
[debug] Default format spec: bestvideo+bestaudio/best
https
[debug] Invoking downloader on 'https://r3---sn-5ualdn7y.googlevideo.com/videoplayback?expire=1586544759&ei=F2yQXuuCDZOikAP4oLW4Bg&ip=XXXXXXX&id=o-AJYbu_7ZzLhrkVo_x7C0tKx-PiS2Zze5XmF2U5t19WAf&itag=248&aitags=133%2C134%2C135%2C136%2C137%2C160%2C242%2C243%2C244%2C247%2C248%2C278&source=youtube&requiressl=yes&mh=7W&mm=31%2C29&mn=sn-5ualdn7y%2Csn-5uaeznyz&ms=au%2Crdu&mv=m&mvi=2&pl=21&initcwndbps=1048750&vprv=1&mime=video%2Fwebm&gir=yes&clen=9678116&dur=240.606&lmt=1540457854501624&mt=1586522978&fvip=3&keepalive=yes&c=WEB&txp=5533432&sparams=expire%2Cei%2Cip%2Cid%2Caitags%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRQIhAOckW-vkeMGiMdEJKDd8AaL6yoN_BYX8KE9XxZLFqhQBAiAQL948pZwxyzgsv8D5uv7L3Up673swklEOZqJdl7SOUg%3D%3D&sig=AJpPlLswRgIhAOappJg3JD-D-9yeQK8Es7QZhX4xeZCT35_EDHAqJPedAiEAgBOWVsVdzZTKwfVPny6lZN1lFYVzrmlH9xQzxCMIqwI=&ratebypass=yes'
[download] Destination: Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f248.webm
[download] 100% of 9.23MiB in 00:00
https
[debug] Invoking downloader on 'https://r3---sn-5ualdn7y.googlevideo.com/videoplayback?expire=1586544759&ei=F2yQXuuCDZOikAP4oLW4Bg&ip=XXXXXXXX&id=o-AJYbu_7ZzLhrkVo_x7C0tKx-PiS2Zze5XmF2U5t19WAf&itag=251&source=youtube&requiressl=yes&mh=7W&mm=31%2C29&mn=sn-5ualdn7y%2Csn-5uaeznyz&ms=au%2Crdu&mv=m&mvi=2&pl=21&initcwndbps=1048750&vprv=1&mime=audio%2Fwebm&gir=yes&clen=4012753&dur=240.661&lmt=1540458115889653&mt=1586522978&fvip=3&keepalive=yes&c=WEB&txp=5511222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRQIhAOckW-vkeMGiMdEJKDd8AaL6yoN_BYX8KE9XxZLFqhQBAiAQL948pZwxyzgsv8D5uv7L3Up673swklEOZqJdl7SOUg%3D%3D&sig=AJpPlLswRQIhAKGAHMBfQbJ5HxB0OufRzZfSpcNKQJiVGmbjrcRU4N1pAiBEVF0JJ_DYxwKTIx5KtitfCk9QFCv93JVBits7_YG6Sg==&ratebypass=yes'
[download] Destination: Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f251.webm
[download] 100% of 3.83MiB in 00:00
[ffmpeg] Merging formats into "Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.webm"
[debug] ffmpeg command line: ffmpeg -y -loglevel repeat+info -i 'file:Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f248.webm' -i 'file:Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f251.webm' -c copy -map 0:v:0 -map 1:a:0 'file:Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.temp.webm'
Deleting original file Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f248.webm (pass -k to keep)
Deleting original file Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f251.webm (pass -k to keep)
youtube-dl --verbose https://www.youtube.com/watch\?v\=EwM8Y7h2TcA
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['--verbose', 'https://www.youtube.com/watch?v=EwM8Y7h2TcA']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2020.03.24
[debug] Python version 3.8.0 (CPython) - macOS-10.15.4-x86_64-i386-64bit
[debug] exe versions: ffmpeg 4.2.2, ffprobe 4.2.2, rtmpdump 2.4
[debug] Proxy map: {}
[youtube] EwM8Y7h2TcA: Downloading webpage
[youtube] {18} signature length 112, html5 player vflset
[youtube] {137} signature length 108, html5 player vflset
[youtube] {248} signature length 112, html5 player vflset
[youtube] {136} signature length 108, html5 player vflset
[youtube] {247} signature length 112, html5 player vflset
[youtube] {135} signature length 108, html5 player vflset
[youtube] {244} signature length 108, html5 player vflset
[youtube] {134} signature length 108, html5 player vflset
[youtube] {243} signature length 108, html5 player vflset
[youtube] {133} signature length 112, html5 player vflset
[youtube] {242} signature length 112, html5 player vflset
[youtube] {160} signature length 112, html5 player vflset
[youtube] {278} signature length 112, html5 player vflset
[youtube] {140} signature length 112, html5 player vflset
[youtube] {249} signature length 112, html5 player vflset
[youtube] {250} signature length 112, html5 player vflset
[youtube] {251} signature length 112, html5 player vflset
[debug] Default format spec: bestvideo+bestaudio/best
https
[debug] Invoking downloader on 'https://r3---sn-5ualdn7y.googlevideo.com/videoplayback?expire=1586544779&ei=K2yQXqbKBc7r4QSQ3bOYDA&ip=XXXXXXX&id=o-AFv1XR7YfGxFD_wzsZHHvVVskL8VXUbEPDyDnHGfd2Kh&itag=248&aitags=133%2C134%2C135%2C136%2C137%2C160%2C242%2C243%2C244%2C247%2C248%2C278&source=youtube&requiressl=yes&mh=7W&mm=31%2C26&mn=sn-5ualdn7y%2Csn-q4flrn7y&ms=au%2Conr&mv=m&mvi=2&pl=21&initcwndbps=1057500&vprv=1&mime=video%2Fwebm&gir=yes&clen=9678116&dur=240.606&lmt=1540457854501624&mt=1586523103&fvip=3&keepalive=yes&c=WEB&txp=5533432&sparams=expire%2Cei%2Cip%2Cid%2Caitags%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRAIgVE4qoMZGV1SshZml090I2_yKI35uLxJ1fsxJIDtCbjsCIBQ7HmboOb3S37DF5SnzkbYnm08NxQFLAXH_UIf415qD&sig=AJpPlLswRQIhANZ0yxk7VH4Q7vNd99LSX_YAVQTn9nGNT3fFAjB2UmXFAiAFIWsuKufr7S8sRV2zdkyZpCrhb5ip3mu8-_jLPoReIg==&ratebypass=yes'
[download] Destination: Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f248.webm
[download] 100% of 9.23MiB in 00:00
https
[debug] Invoking downloader on 'https://r3---sn-5ualdn7y.googlevideo.com/videoplayback?expire=1586544779&ei=K2yQXqbKBc7r4QSQ3bOYDA&ip=XXXXXX&id=o-AFv1XR7YfGxFD_wzsZHHvVVskL8VXUbEPDyDnHGfd2Kh&itag=251&source=youtube&requiressl=yes&mh=7W&mm=31%2C26&mn=sn-5ualdn7y%2Csn-q4flrn7y&ms=au%2Conr&mv=m&mvi=2&pl=21&initcwndbps=1057500&vprv=1&mime=audio%2Fwebm&gir=yes&clen=4012753&dur=240.661&lmt=1540458115889653&mt=1586523103&fvip=3&keepalive=yes&c=WEB&txp=5511222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRAIgVE4qoMZGV1SshZml090I2_yKI35uLxJ1fsxJIDtCbjsCIBQ7HmboOb3S37DF5SnzkbYnm08NxQFLAXH_UIf415qD&sig=AJpPlLswRQIgcl9tFnuWIZ_xoG48jZ7rMkLwqFFjbvoAwEHaZ6rrvlQCIQC64Echp8QSY5_655c37Vno8WcbBI9os2rm8SHz2zTz5w==&ratebypass=yes'
[download] Destination: Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f251.webm
[download] 100% of 3.83MiB in 00:00
[ffmpeg] Merging formats into "Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.webm"
[debug] ffmpeg command line: ffmpeg -y -loglevel repeat+info -i 'file:Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f248.webm' -i 'file:Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f251.webm' -c copy -map 0:v:0 -map 1:a:0 'file:Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.temp.webm'
Deleting original file Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f248.webm (pass -k to keep)
Deleting original file Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f251.webm (pass -k to keep)
youtube-dl --verbose https://www.youtube.com/watch\?v\=EwM8Y7h2TcA
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['--verbose', 'https://www.youtube.com/watch?v=EwM8Y7h2TcA']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2020.03.24
[debug] Python version 3.8.0 (CPython) - macOS-10.15.4-x86_64-i386-64bit
[debug] exe versions: ffmpeg 4.2.2, ffprobe 4.2.2, rtmpdump 2.4
[debug] Proxy map: {}
[youtube] EwM8Y7h2TcA: Downloading webpage
[youtube] {18} signature length 112, html5 player vflset
[youtube] {137} signature length 108, html5 player vflset
[youtube] {248} signature length 112, html5 player vflset
[youtube] {136} signature length 112, html5 player vflset
[youtube] {247} signature length 112, html5 player vflset
[youtube] {135} signature length 108, html5 player vflset
[youtube] {244} signature length 108, html5 player vflset
[youtube] {134} signature length 112, html5 player vflset
[youtube] {243} signature length 112, html5 player vflset
[youtube] {133} signature length 112, html5 player vflset
[youtube] {242} signature length 112, html5 player vflset
[youtube] {160} signature length 112, html5 player vflset
[youtube] {278} signature length 112, html5 player vflset
[youtube] {140} signature length 112, html5 player vflset
[youtube] {249} signature length 112, html5 player vflset
[youtube] {250} signature length 112, html5 player vflset
[youtube] {251} signature length 108, html5 player vflset
[debug] Default format spec: bestvideo+bestaudio/best
https
[debug] Invoking downloader on 'https://r3---sn-5ualdn7y.googlevideo.com/videoplayback?expire=1586544789&ei=NWyQXrOlIPTcj-8PgJWsyAQ&ip=XXXXXX&id=o-ANmQVJiABRl04ovmYqZr20FGqkcYsLeQoY5jX8t_NmJj&itag=248&aitags=133%2C134%2C135%2C136%2C137%2C160%2C242%2C243%2C244%2C247%2C248%2C278&source=youtube&requiressl=yes&mh=7W&mm=31%2C29&mn=sn-5ualdn7y%2Csn-5uaeznyz&ms=au%2Crdu&mv=m&mvi=2&pl=21&initcwndbps=1057500&vprv=1&mime=video%2Fwebm&gir=yes&clen=9678116&dur=240.606&lmt=1540457854501624&mt=1586523103&fvip=3&keepalive=yes&c=WEB&txp=5533432&sparams=expire%2Cei%2Cip%2Cid%2Caitags%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRQIhAMVf6Lg_pm0-Z0rXElB9LJhKOmVFhAChMsB17EmAADmvAiA6396Lymo2hrnCS0mx2Lq_0TUn9ch90eEUykU8dbkW-w%3D%3D&sig=AJpPlLswRgIhAOEt1FeVkC8PSxEq9eqtXebvJnrjuvA71JIFZxGFS06YAiEAltFniB6qShf6dIUPmzC1WPz7ZwJF3OIfvK2jNBGA1IM=&ratebypass=yes'
[download] Destination: Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f248.webm
[download] 100% of 9.23MiB in 00:00
https
[debug] Invoking downloader on 'https://r3---sn-5ualdn7y.googlevideo.com/videoplayback?expire=1586544789&ei=NWyQXrOlIPTcj-8PgJWsyAQ&ip=XXXXXX&id=o-ANmQVJiABRl04ovmYqZr20FGqkcYsLeQoY5jX8t_NmJj&itag=251&source=youtube&requiressl=yes&mh=7W&mm=31%2C29&mn=sn-5ualdn7y%2Csn-5uaeznyz&ms=au%2Crdu&mv=m&mvi=2&pl=21&initcwndbps=1057500&vprv=1&mime=audio%2Fwebm&gir=yes&clen=4012753&dur=240.661&lmt=1540458115889653&mt=1586523103&fvip=3&keepalive=yes&c=WEB&txp=5511222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRQIhAMVf6Lg_pm0-Z0rXElB9LJhKOmVFhAChMsB17EmAADmvAiA6396Lymo2hrnCS0mx2Lq_0TUn9ch90eEUykU8dbkW-w%3D%3D&sig=PEAAAu4ubN7WXkh7BR57kIM8FKRR0WFcTKeEjdO2AEnjZAcDHICIIEA4jAhbMIgKJSbPV219FoXovZuuB8lgLx5OWqfRGZgIARwsLlPpJ4&ratebypass=yes'
ERROR: unable to download video data: HTTP Error 403: Forbidden
Traceback (most recent call last):
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 1921, in process_info
    partial_success = dl(fname, new_info)
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 1866, in dl
    return fd.download(name, info)
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/common.py", line 366, in download
    return self.real_download(filename, info_dict)
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/http.py", line 341, in real_download
    establish_connection()
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/http.py", line 109, in establish_connection
    ctx.data = self.ydl.urlopen(request)
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 2239, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 531, in open
    response = meth(req, response)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 640, in http_response
    response = self.parent.error(
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 569, in error
    return self._call_chain(*args)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 502, in _call_chain
    result = func(*args)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 649, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden

All 3 are from the same location and virtualenv. Just running the command 3 times. By videos with a signature, I mean videos that have encrypted signatures that are decrypted by youtube-dl and then added to the "invoking download" link. There is clearly something inconsistent with the signatures (recently changed on youtubes side) which is causing inconsistencies in the creation of the download link.

@dstftw explanation for this?

MSauce commented 4 years ago

I think I'm on to something...

In these above downloads, we are trying to grab f248 + f251 and then merge. When we are assessing the signature length, if the length of f248 and f251 are both 112, the download completes normally.

In the instance where it fails, it fails on f251 which has a signature length of '108' instead of '112'. Anytime it attempts to download a format with a 108 signature length, the download fails. Whether the signature length of any given format is '112' or '108' seems to be random and changes each time I attempt to download the file. It is only successful when ALL the formats you are requesting have a signature length of 112 and fail anytime any has a length of 108.

Please re-open this issue @dstftw. I have now reproduced it on several videos.

MSauce commented 4 years ago

Reproducing on 2nd video with different formats:

youtube-dl --verbose https://www.youtube.com/watch\?v\=2t22OYi1F7E
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['--verbose', 'https://www.youtube.com/watch?v=2t22OYi1F7E']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2020.03.24
[debug] Python version 3.8.0 (CPython) - macOS-10.15.4-x86_64-i386-64bit
[debug] exe versions: ffmpeg 4.2.2, ffprobe 4.2.2, rtmpdump 2.4
[debug] Proxy map: {}
[youtube] 2t22OYi1F7E: Downloading webpage
[youtube] {18} signature length 112, html5 player vflset
[youtube] {137} signature length 112, html5 player vflset
[youtube] {248} signature length 112, html5 player vflset
[youtube] {136} signature length 112, html5 player vflset
[youtube] {247} signature length 112, html5 player vflset
[youtube] {135} signature length 112, html5 player vflset
[youtube] {244} signature length 108, html5 player vflset
[youtube] {134} signature length 112, html5 player vflset
[youtube] {243} signature length 112, html5 player vflset
[youtube] {133} signature length 112, html5 player vflset
[youtube] {242} signature length 112, html5 player vflset
[youtube] {160} signature length 112, html5 player vflset
[youtube] {278} signature length 112, html5 player vflset
[youtube] {140} signature length 112, html5 player vflset
[youtube] {249} signature length 112, html5 player vflset
[youtube] {250} signature length 112, html5 player vflset
[youtube] {251} signature length 112, html5 player vflset
[debug] Default format spec: bestvideo+bestaudio/best
WARNING: Requested formats are incompatible for merge and will be merged into mkv.
https
[debug] Invoking downloader on 'https://r3---sn-5uaeznys.googlevideo.com/videoplayback?expire=1586546879&ei=X3SQXt_1LvaCzLUPp6KOmAg&ip=XXX.XXX.XXX.XXX&id=o-ANuKU7RSvkIpzDXD3VnSHx6G4EK8e4xnJQes0baKfxKR&itag=137&aitags=133%2C134%2C135%2C136%2C137%2C160%2C242%2C243%2C244%2C247%2C248%2C278&source=youtube&requiressl=yes&mh=aF&mm=31%2C29&mn=sn-5uaeznys%2Csn-5ualdne7&ms=au%2Crdu&mv=m&mvi=2&pl=21&gcr=us&initcwndbps=1068750&vprv=1&mime=video%2Fmp4&gir=yes&clen=5242075&dur=203.040&lmt=1584633423645172&mt=1586525140&fvip=3&keepalive=yes&fexp=23882513&c=WEB&txp=2316222&sparams=expire%2Cei%2Cip%2Cid%2Caitags%2Csource%2Crequiressl%2Cgcr%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRAIgQp0TeX-taxBOGD5beKCnMvknXhO5e66870Oq0mL11rcCIDlGq1ay3zOtKeGyD1eIvZLPwCcB1ya5bGbtmKh_EZWw&sig=AJpPlLswRgIhAPhaMw5jgERBLQOYUo7fbX5wA2QQX73OZIoi6wQqJVR8AiEA2LaOzgaJPhrBxoixq9lt53KMElEz3ahvbEX6t0x1tmI=&ratebypass=yes'
[download] Destination: These Days-2t22OYi1F7E.f137.mp4
[download] 100% of 5.00MiB in 00:00
https
[debug] Invoking downloader on 'https://r3---sn-5uaeznys.googlevideo.com/videoplayback?expire=1586546879&ei=X3SQXt_1LvaCzLUPp6KOmAg&ip=XXX.XXX.XXX.XXX&id=o-ANuKU7RSvkIpzDXD3VnSHx6G4EK8e4xnJQes0baKfxKR&itag=251&source=youtube&requiressl=yes&mh=aF&mm=31%2C29&mn=sn-5uaeznys%2Csn-5ualdne7&ms=au%2Crdu&mv=m&mvi=2&pl=21&gcr=us&initcwndbps=1068750&vprv=1&mime=audio%2Fwebm&gir=yes&clen=3342703&dur=203.101&lmt=1584633419838021&mt=1586525140&fvip=3&keepalive=yes&fexp=23882513&c=WEB&txp=2311222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cgcr%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRAIgQp0TeX-taxBOGD5beKCnMvknXhO5e66870Oq0mL11rcCIDlGq1ay3zOtKeGyD1eIvZLPwCcB1ya5bGbtmKh_EZWw&sig=AJpPlLswRgIhAObqLDU5buQ60iOLAcuyqSVUzXABvSK7sPNMT47culmmAiEAsLlpznU5K8FY8IXFPKiJ1APPs2bDIYRj_KRQpvD-aq8=&ratebypass=yes'
[download] Destination: These Days-2t22OYi1F7E.f251.webm
[download] 100% of 3.19MiB in 00:00
[ffmpeg] Merging formats into "These Days-2t22OYi1F7E.mkv"
[debug] ffmpeg command line: ffmpeg -y -loglevel repeat+info -i 'file:These Days-2t22OYi1F7E.f137.mp4' -i 'file:These Days-2t22OYi1F7E.f251.webm' -c copy -map 0:v:0 -map 1:a:0 'file:These Days-2t22OYi1F7E.temp.mkv'
Deleting original file These Days-2t22OYi1F7E.f137.mp4 (pass -k to keep)
Deleting original file These Days-2t22OYi1F7E.f251.webm (pass -k to keep)

First run successful, both requested formats (f137 and f251) have signature length 112.

youtube-dl --verbose https://www.youtube.com/watch\?v\=2t22OYi1F7E
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['--verbose', 'https://www.youtube.com/watch?v=2t22OYi1F7E']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2020.03.24
[debug] Python version 3.8.0 (CPython) - macOS-10.15.4-x86_64-i386-64bit
[debug] exe versions: ffmpeg 4.2.2, ffprobe 4.2.2, rtmpdump 2.4
[debug] Proxy map: {}
[youtube] 2t22OYi1F7E: Downloading webpage
[youtube] {18} signature length 108, html5 player vflset
[youtube] {137} signature length 108, html5 player vflset
[youtube] {248} signature length 112, html5 player vflset
[youtube] {136} signature length 112, html5 player vflset
[youtube] {247} signature length 112, html5 player vflset
[youtube] {135} signature length 108, html5 player vflset
[youtube] {244} signature length 112, html5 player vflset
[youtube] {134} signature length 112, html5 player vflset
[youtube] {243} signature length 108, html5 player vflset
[youtube] {133} signature length 112, html5 player vflset
[youtube] {242} signature length 112, html5 player vflset
[youtube] {160} signature length 112, html5 player vflset
[youtube] {278} signature length 112, html5 player vflset
[youtube] {140} signature length 112, html5 player vflset
[youtube] {249} signature length 112, html5 player vflset
[youtube] {250} signature length 108, html5 player vflset
[youtube] {251} signature length 108, html5 player vflset
[debug] Default format spec: bestvideo+bestaudio/best
WARNING: Requested formats are incompatible for merge and will be merged into mkv.
https
[debug] Invoking downloader on 'https://r3---sn-5uaeznys.googlevideo.com/videoplayback?expire=1586546864&ei=UHSQXuuBF8W64QSDtbaIBw&ip=XXX.XXX.XXX.XXX&id=o-AJt_oSr6zygv1pT3kCGM_zCOEXPcsP5-oTh3KeqPekGx&itag=137&aitags=133%2C134%2C135%2C136%2C137%2C160%2C242%2C243%2C244%2C247%2C248%2C278&source=youtube&requiressl=yes&mh=aF&mm=31%2C29&mn=sn-5uaeznys%2Csn-5ualdne7&ms=au%2Crdu&mv=m&mvi=2&pl=21&gcr=us&initcwndbps=1068750&vprv=1&mime=video%2Fmp4&gir=yes&clen=5242075&dur=203.040&lmt=1584633423645172&mt=1586525140&fvip=3&keepalive=yes&c=WEB&txp=2316222&sparams=expire%2Cei%2Cip%2Cid%2Caitags%2Csource%2Crequiressl%2Cgcr%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ALrAebAwRgIhAMuseFstIJH0qCwDcdOyxOmhYMFWk2rnn4tJxe3Agz-lAiEA9SHh7A8O98otctdAv82E6mdp62R2o-2weEizaOHHlds%3D&sig=XnYYYQqQKKmDDvQihzMtcluDVsJV0l3oZmFpAc0yYl7emFHwGICcsnAq-YlDs6mp3HuoBv43MpPTFp_X17TTozSHKkyUjBgIARwsLlPpJY&ratebypass=yes'
ERROR: unable to download video data: HTTP Error 403: Forbidden
Traceback (most recent call last):
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 1921, in process_info
    partial_success = dl(fname, new_info)
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 1866, in dl
    return fd.download(name, info)
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/common.py", line 366, in download
    return self.real_download(filename, info_dict)
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/http.py", line 341, in real_download
    establish_connection()
  File "/venv/lib/python3.8/site-packages/youtube_dl/downloader/http.py", line 109, in establish_connection
    ctx.data = self.ydl.urlopen(request)
  File "/venv/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 2239, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 531, in open
    response = meth(req, response)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 640, in http_response
    response = self.parent.error(
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 569, in error
    return self._call_chain(*args)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 502, in _call_chain
    result = func(*args)
  File "/.pyenv/versions/3.8.0/lib/python3.8/urllib/request.py", line 649, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden

On the 2nd attempt, it fails because the first requested format (f137) has a signature length of 108.

Hrxn commented 4 years ago

Okay, quick attempt for those IDs:

2t22OYi1F7E
EwM8Y7h2TcA
PS C:\Move> youtube-dl --ignore-config 2t22OYi1F7E
[youtube] 2t22OYi1F7E: Downloading webpage
WARNING: Requested formats are incompatible for merge and will be merged into mkv.
[download] Destination: These Days-2t22OYi1F7E.f137.mp4
[download] 100% of 5.00MiB in 00:00
[download] Destination: These Days-2t22OYi1F7E.f251.webm
[download] 100% of 3.19MiB in 00:00
[ffmpeg] Merging formats into "These Days-2t22OYi1F7E.mkv"
Deleting original file These Days-2t22OYi1F7E.f137.mp4 (pass -k to keep)
Deleting original file These Days-2t22OYi1F7E.f251.webm (pass -k to keep)
PS C:\Move> youtube-dl --ignore-config EwM8Y7h2TcA
[youtube] EwM8Y7h2TcA: Downloading webpage
[download] Destination: Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f248.webm
[download] 100% of 9.23MiB in 00:01
[download] Destination: Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f251.webm
[download] 100% of 3.83MiB in 00:00
[ffmpeg] Merging formats into "Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.webm"
Deleting original file Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f248.webm (pass -k to keep)
Deleting original file Reset - Tiger J.K (ft. Jinshil of mad soul child) Han_Rom_Eng Lyrics [Who Are You School 2015 OST]-EwM8Y7h2TcA.f251.webm (pass -k to keep)
PS C:\Move>

Seems to work..

youtube-dl stores extraction signature stuff into a cache directory (usually inside .cache in your user's home dir), you could try to delete this, maybe it helps.

MSauce commented 4 years ago

Interesting - I had a different cache_spec for 108 for that player. After deleting the /.cache/youtube-dl directory, and re-downloading 2 players, it seems to have fixed the issue.

heshang233 commented 4 years ago

https://github.com/ytdl-org/youtube-dl/issues/23638 This method solved my problem root@1e88d34a07f0:/home# ./youtube-dl --rm-cache-dir Removing cache dir /root/.cache/youtube-dl ...

diamondsw commented 4 years ago

This issue is still being reported constantly (there are dozens of bug reports on it closed and open). It's being reported on Reddit (e.g. here) and I'm seeing it myself. Clearing the cache does indeed fix it (but for how long?), but there is no reason for an end-user to know that, and it also certainly shows that youtube-dl is handling something in that cache directory incorrectly, or should be able to detect whatever data is in there that is "bad".

This should be reopened because the underlying bug is not fixed, it's just individual users who stumble in here are fixing it themselves.

MSauce commented 4 years ago

Just wanted to follow up - this issue recurred again today roughly 1 week after clearing the cached sigfuncs folder. Same fix resolved the issue. Since dstftw refuses to consider this an issue, a temporary solution is to set a cron deleting /.cache/youtube-dl/youtube-sigfuncs/* or running youtube-dl --rm-cache-dir.