LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 12-11-2022, 03:39 PM   #1
newbiesforever
Senior Member
 
Registered: Apr 2006
Location: Iowa
Distribution: Debian distro family
Posts: 2,378

Rep: Reputation: Disabled
any workaround for this youtube-dl bug?


I have tried to use youtube-dl -x to download the audio from some videos. It is giving the following error message:

Code:
[youtube] xfYS9ZE7-uo: Downloading webpage
[youtube] xfYS9ZE7-uo: Downloading player 72d3c60a
ERROR: Signature extraction failed: Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/youtube_dl/extractor/youtube.py", line 1348, in _decrypt_signature
    func = self._extract_signature_function(
  File "/usr/lib/python3/dist-packages/youtube_dl/extractor/youtube.py", line 1265, in _extract_signature_function
    cache_res = res(test_string)
  File "/usr/lib/python3/dist-packages/youtube_dl/extractor/youtube.py", line 1332, in <lambda>
    return lambda s: initial_function([s])
  File "/usr/lib/python3/dist-packages/youtube_dl/jsinterp.py", line 258, in resf
    res, abort = self.interpret_statement(stmt, local_vars)
  File "/usr/lib/python3/dist-packages/youtube_dl/jsinterp.py", line 56, in interpret_statement
    v = self.interpret_expression(expr, local_vars, allow_recursion)
  File "/usr/lib/python3/dist-packages/youtube_dl/jsinterp.py", line 211, in interpret_expression
    raise ExtractorError('Unsupported JS expression %r' % expr)
youtube_dl.utils.ExtractorError: Unsupported JS expression 'try{var e=b.call(a.j.C,c)'; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
 (caused by ExtractorError("Unsupported JS expression 'try{var e=b.call(a.j.C,c)'; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.")); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
This makes youtube-dl useless for the moment to me. Any ideas?
 
Old 12-11-2022, 04:07 PM   #2
rokytnji
LQ Veteran
 
Registered: Mar 2008
Location: Waaaaay out West Texas
Distribution: antiX 23, MX 23
Posts: 7,144
Blog Entries: 21

Rep: Reputation: 3482Reputation: 3482Reputation: 3482Reputation: 3482Reputation: 3482Reputation: 3482Reputation: 3482Reputation: 3482Reputation: 3482Reputation: 3482Reputation: 3482
https://github.com/yt-dlp/yt-dlp

https://linuxconfig.org/yt-dlp-vs-youtube-dl

Good luck.
 
3 members found this post helpful.
Old 12-13-2022, 05:46 PM   #3
jefro
Moderator
 
Registered: Mar 2008
Posts: 22,008

Rep: Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629
Might be an old version of Yt.
 
Old 12-13-2022, 07:28 PM   #4
aus9
LQ 5k Club
 
Registered: Oct 2003
Location: Western Australia
Distribution: Icewm
Posts: 5,842

Rep: Reputation: Disabled
in addition to above your code box shows you can run that command with verbose to get more info

Quote:
Be sure to call youtube-dl with the --verbose flag
example of verbose
Code:
youtube-dl --verbose https://youtu.be/5uzf6X67upQ
[debug] Command-line config: ['--verbose', 'https://youtu.be/5uzf6X67upQ']
[debug] Encodings: locale UTF-8, fs utf-8, pref UTF-8, out utf-8, error utf-8, screen utf-8
[debug] yt-dlp version 2022.06.29 [9d339c41e]
[debug] Python 3.9.2 (CPython 64bit) - Linux-5.19.0-14.1-liquorix-amd64-x86_64-with-glibc2.31 (glibc 2.31)
[debug] Checking exe version: ffmpeg -bsfs
[debug] Checking exe version: ffprobe -bsfs
[debug] exe versions: ffmpeg 4.3.5-0.1, ffprobe 4.3.5-0.1, rtmpdump 2.4
[debug] Optional libraries: Cryptodome-3.9.7, brotli-1.0.9, certifi-2020.06.20, mutagen-1.45.1, pyxattr-0.7.2, sqlite3-2.6.0, websockets-8.1
[debug] Proxy map: {}
[debug] [youtube] Extracting URL: https://youtu.be/5uzf6X67upQ
[youtube] 5uzf6X67upQ: Downloading webpage
[youtube] 5uzf6X67upQ: Downloading android player API JSON
[debug] Sort order given by extractor: quality, res, fps, hdr:12, source, codec:vp9.2, lang, proto
[debug] Formats sorted by: hasvid, ie_pref, quality, res, fps, hdr:12(7), source, vcodec:vp9.2(10), acodec, lang, proto, filesize, fs_approx, tbr, vbr, abr, asr, vext, aext, hasaud, id
[debug] Default format spec: bestvideo*+bestaudio/best
[info] 5uzf6X67upQ: Downloading 1 format(s): 248+251
[debug] Invoking http downloader on "https://rr3---sn-fpqxc5oq-2xge.googlevideo.com/videoplayback?expire=1671002836&ei=dCaZY7S6BJTK9QPyxZyQAQ&ip=159.196.135.119&id=o-AIKrcTKC-Pja6fFgZQ6SaouJxxGmktyVxlW3Y8Mj0uMl&itag=248&source=youtube&requiressl=yes&mh=Ik&mm=31%2C29&mn=sn-fpqxc5oq-2xge%2Csn-hxa7zn7s&ms=au%2Crdu&mv=m&mvi=3&pl=22&initcwndbps=1931250&vprv=1&mime=video%2Fwebm&gir=yes&clen=10241346&dur=75.299&lmt=1648896712508504&mt=1670980901&fvip=1&keepalive=yes&fexp=24001373%2C24007246&c=ANDROID&txp=5437434&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&sig=AOq0QJ8wRAIgcbvGkDkJdgcg6KVRLrU_TWXFn9_6gwiX0BE0KkHfKy8CIDH9OmlNk0w-kL3WF1ZnaaPxNvX0DMfNi7KXq7MBgVs2&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=AG3C_xAwRgIhALik2UDM7tXJFrE53QAno9Nn_m5jDJEdlTat0U5zytLQAiEAk6F_ttrj_cWdAEpBNwIdAD-h1QVAEiXl-jF8CkLQ5SQ%3D"
[download] Destination: another Skull classic!!������������ [5uzf6X67upQ].f248.webm
[download] 100% of 9.77MiB in 00:03
[debug] Invoking http downloader on "https://rr3---sn-fpqxc5oq-2xge.googlevideo.com/videoplayback?expire=1671002836&ei=dCaZY7S6BJTK9QPyxZyQAQ&ip=159.196.135.119&id=o-AIKrcTKC-Pja6fFgZQ6SaouJxxGmktyVxlW3Y8Mj0uMl&itag=251&source=youtube&requiressl=yes&mh=Ik&mm=31%2C29&mn=sn-fpqxc5oq-2xge%2Csn-hxa7zn7s&ms=au%2Crdu&mv=m&mvi=3&pl=22&initcwndbps=1931250&vprv=1&mime=audio%2Fwebm&gir=yes&clen=1021019&dur=75.381&lmt=1648893446971695&mt=1670980901&fvip=1&keepalive=yes&fexp=24001373%2C24007246&c=ANDROID&txp=5432434&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&sig=AOq0QJ8wRgIhAOMAgTDTMT2t0VlacEdrfTWfrmM9nZG-KjzM4ZyB_FXnAiEAhHgldAD3amz_pFUwUDsujE3y_HXTtGbFw6yoqvkFZZM%3D&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=AG3C_xAwRgIhALik2UDM7tXJFrE53QAno9Nn_m5jDJEdlTat0U5zytLQAiEAk6F_ttrj_cWdAEpBNwIdAD-h1QVAEiXl-jF8CkLQ5SQ%3D"
[download] Destination: another Skull classic!!������������ [5uzf6X67upQ].f251.webm
[download] 100% of 997.09KiB in 00:00
[Merger] Merging formats into "another Skull classic!!������������ [5uzf6X67upQ].webm"
[debug] ffmpeg command line: ffmpeg -y -loglevel repeat+info -i 'file:another Skull classic!!������������ [5uzf6X67upQ].f248.webm' -i 'file:another Skull classic!!������������ [5uzf6X67upQ].f251.webm' -c copy -map 0:v:0 -map 1:a:0 -movflags +faststart 'file:another Skull classic!!������������ [5uzf6X67upQ].temp.webm'
Deleting original file another Skull classic!!������������ [5uzf6X67upQ].f251.webm (pass -k to keep)
Deleting original file another Skull classic!!������������ [5uzf6X67upQ].f248.webm (pass -k to keep)
 
Old 12-13-2022, 10:59 PM   #5
jefro
Moderator
 
Registered: Mar 2008
Posts: 22,008

Rep: Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629
yt-dlp version 2022.06.29

Didn't know that.
 
Old 12-14-2022, 12:53 AM   #6
aus9
LQ 5k Club
 
Registered: Oct 2003
Location: Western Australia
Distribution: Icewm
Posts: 5,842

Rep: Reputation: Disabled
debian is https://packages.debian.org/bullseye/youtube-dl v 2021.06.06-1

mine comes from MX distro and may be out of date

upstream https://youtube-dl.org/
v2021.12.17

Last edited by aus9; 12-14-2022 at 12:58 AM.
 
Old 12-14-2022, 01:14 AM   #7
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,981

Rep: Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337
just some background information: youtube modifies their services continuously (you can say improve them if you wish). Therefore, the downloader must somehow track these undocumented changes. Youtube doesn't really care that the downloader works (or is compatible) either. So better to use an uptodate version, as it was suggested (Make sure you are using the latest version) or use a better alternative (see post #2)
 
Old 12-14-2022, 04:02 AM   #8
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,404

Rep: Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338
This usually does it
Code:
sudo youtube-dl -U
I prefer yt-dlp because it doesn't succumb to youtube's bandwidth-limiting tricks nearly as much.
 
1 members found this post helpful.
Old 12-14-2022, 08:15 AM   #9
teckk
LQ Guru
 
Registered: Oct 2004
Distribution: Arch
Posts: 5,146
Blog Entries: 6

Rep: Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834
+ one for yt-dlp
https://github.com/yt-dlp/yt-dlp
 
Old 12-14-2022, 08:34 AM   #10
teckk
LQ Guru
 
Registered: Oct 2004
Distribution: Arch
Posts: 5,146
Blog Entries: 6

Rep: Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834Reputation: 1834
Quote:
This makes youtube-dl useless for the moment to me. Any ideas?
You can always scrape the virtual url for the video that you wish, and manually dump the audio from it. Use your web inspector or python script etc.

I just looked at the video you are trying to get.

https://m.youtube.com/watch?v=xfYS9ZE7-uo

Format 140(m4a)

Code:
url="https://rr4---sn-vgqsrnes.googlevideo.com/videoplayback?expire=1671049780&ei=1N2ZY9__Ovew2_gPtIutqAI&ip=108.188.145.145&id=o-AI08cDxwhq9YikeO9csoWPxZZ60itX-1XS5ftuvhIMuc&itag=140&source=youtube&requiressl=yes&mh=PV&mm=31%2C29&mn=sn-vgqsrnes%2Csn-vgqskn6z&ms=au%2Crdu&mv=m&mvi=4&pl=21&initcwndbps=1205000&spc=SFxXNnT25xTfHI07QonbbpwZ6_oXtWs&vprv=1&svpuc=1&mime=audio%2Fmp4&gir=yes&clen=33088035&otfp=1&dur=2044.447&lmt=1625421874993145&mt=1671027694&fvip=3&keepalive=yes&fexp=24001373%2C24007246&c=ANDROID&txp=7211222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cspc%2Cvprv%2Csvpuc%2Cmime%2Cgir%2Cclen%2Cotfp%2Cdur%2Clmt&sig=AOq0QJ8wRQIhAOwNAR2XJtJzwqjcXDHFXmU6zf4_Ydgf5IzhwIm1k7Y5AiAxEUEiwTFnMTFsymw9HeF73TBi9drAtO9ZJyUkTILZ_w%3D%3D&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=AG3C_xAwRAIgV1ZqtWJX-864BPBnZwjXYVL8-Q53lUpuFaubmRiKENYCIDiRPmYSas8ALDOKwuLBRy8a1qZdThlkuLsNWraZzJii"

ffmpeg -i "$url" -vn -c:a copy myaud.m4a
That virtual url is probably only good for a bit. But, I was able to download it.
 
Old 12-19-2022, 02:02 PM   #11
newbiesforever
Senior Member
 
Registered: Apr 2006
Location: Iowa
Distribution: Debian distro family
Posts: 2,378

Original Poster
Rep: Reputation: Disabled
I find this to be more evidence that Youtube is at fault: on further attempts, I find that sometimes the audio downloads normally; and sometimes it fails with that error message . It's unpredictable.
 
Old 12-20-2022, 01:23 AM   #12
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,981

Rep: Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337
Quote:
Originally Posted by business_kid View Post
This usually does it
Code:
sudo youtube-dl -U
I prefer yt-dlp because it doesn't succumb to youtube's bandwidth-limiting tricks nearly as much.
you must not use sudo with that downloader, that is pointless
 
Old 12-20-2022, 03:45 AM   #13
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,404

Rep: Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338Reputation: 2338
Not on my box. Youtube-dl is in /usr/local/bin.
 
Old 12-20-2022, 09:30 AM   #14
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,981

Rep: Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337
Quote:
Originally Posted by business_kid View Post
Not on my box. Youtube-dl is in /usr/local/bin.
And? why did you post that?
 
Old 12-20-2022, 09:41 AM   #15
hish2021
Member
 
Registered: Jan 2021
Posts: 117

Rep: Reputation: Disabled
Code:
-U, --update                         Update this program to latest version.
                                     Make sure that you have sufficient
                                     permissions (run with sudo if needed)
^ from the GitHub page.
I download the binary to ~/bin and run it from there. Then, youtube-dl -U is enough; no sudo.

I now use yt-dlp. Same there.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: How To Cast YouTube Videos From Your Phone To Raspberry Pi Using YouTube On TV (youtube.com/tv) LXer Syndicated Linux News 0 04-16-2021 01:30 AM
LXer: Microsoft admits critical .NET Framework 4.6 bug, issues workaround LXer Syndicated Linux News 0 07-30-2015 02:05 AM
Torbutton and Firefox security bug workaround ananai Linux - Security 5 11-13-2008 12:10 AM
SuSE sound bug workaround? Beberik SUSE / openSUSE 1 12-09-2005 09:07 AM
workaround for parted bug using fdisk and resize2fs carneros Linux - Newbie 2 10-05-2004 12:52 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 07:23 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration