使用youtube-dl
软件下载 youtube被认为是非常有用的。
看到一条消息,它停止工作,下面是。
ERROR: Signature extraction failed: Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/youtube_dl/extractor/youtube.py", line 479, in _decrypt_signature
video_id, player_url, s
File "/usr/lib/python2.7/dist-packages/youtube_dl/extractor/youtube.py", line 383, in _extract_signature_function
res = self._parse_sig_js(code)
File "/usr/lib/python2.7/dist-packages/youtube_dl/extractor/youtube.py", line 454, in _parse_sig_js
u'Initial JS player signature function name')
File "/usr/lib/python2.7/dist-packages/youtube_dl/extractor/common.py", line 391, in _search_regex
raise RegexNotFoundError(u'Unable to extract %s' % _name)
RegexNotFoundError: Unable to extract Initial JS player signature function name; please report this issue on https://yt-dl.org/bug . Be sure to call youtube-dl with the --verbose flag and include its complete output. Make sure you are using the latest version; type youtube-dl -U to update.
; please report this issue on https://yt-dl.org/bug . Be sure to call youtube-dl with the --verbose flag and include its complete output. Make sure you are using the latest version; type youtube-dl -U to update.
Run Code Online (Sandbox Code Playgroud)
我应该怎么做才能继续?
kar*_*rel 70
您收到此错误:
Unable to extract Initial JS player signature function name
Run Code Online (Sandbox Code Playgroud)
...因为 youtube-dl 不是最新的。与几年前相比,谷歌现在更频繁地改变访问 YouTube 视频的方式,因此为了使 youtube-dl 保持最新,它也必须更频繁地更新。要安装最新版本的 youtube-dl,请打开终端并输入:
sudo snap install youtube-dl
Run Code Online (Sandbox Code Playgroud)
或者:
sudo apt remove youtube-dl
sudo apt install python3-pip
python3 -m pip install youtube-dl
Run Code Online (Sandbox Code Playgroud)
要将 youtube-dl 升级到最新版本:
sudo snap install youtube-dl # start with snap run youtube-dl
Run Code Online (Sandbox Code Playgroud)
或者
sudo python3 -m pip install --upgrade youtube-dl
Run Code Online (Sandbox Code Playgroud)
谷歌更改访问 YouTube 视频的代码的频率如此之高,真是太疯狂了。我似乎只记得几个月前更新了 youtube-dl,但在我更新之前它仍然无法下载所选视频。
youtube-dl 是一个 Python 程序,因此您也可以在 Python 虚拟环境中本地安装最新版本的 youtube-dl。有关如何设置和使用 Python 虚拟环境的信息,请参阅如何在 Ubuntu 中设置和使用虚拟 Python 环境?.
我让它工作的唯一方法是使用最新版本(对我来说在 debian 上)
sudo wget https://yt-dl.org/latest/youtube-dl -O /usr/local/bin/youtube-dl
sudo chmod a+x /usr/local/bin/youtube-dl
hash -r
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
72380 次 |
最近记录: |