markdown
```text
#安装
sudo pip3 install --upgrade youtube-dl
```
```text
#简易使用
youtube-dl -f best URL
```
使用youtube-dl下载youtube视频时,出现如下错误:
```text
ERROR: Unable to extract uploader id; 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.
报错信息如下:
File "/usr/local/lib/python3.11/dist-packages/youtube_dl/extractor/youtube.py", line 1794, in _real_extract
```
解决方法:
```text
把'uploader_id': self._search_regex(r'/(?:channel|user)/([^/?]+)', owner_profile_url, 'uploader id') if owner_profile_url else None,
```
替换为:
'uploader_id': self._search_regex(r'/(?:channel/|user/|@)/([^/?]+)', owner_profile_url, 'uploader id'),
评论