【问题标题】:YouTube Video Downloader with URL带有 URL 的 YouTube 视频下载器
【发布时间】:2021-06-19 01:26:51
【问题描述】:

我在 2 周前使用此代码下载了一个 Youtube 视频,它可以工作,但现在当我尝试运行它时,我得到了这个:

引发 HTTPError(req.full_url, code, msg, hdrs, fp) urllib.error.HTTPError:HTTP 错误 404:未找到

如何解决?

from pytube import YouTube
link=input("Enter the URL link : ")
video=YouTube(link)

video.streams.get_highest_resolution().download(output_path=r'D:\YouTubevideos')

print("Download done")
from pytube import Playlist
playlist_link=input("Enter the play list link : ")
playlist=Playlist(playlist_link)
for videos in playlist.videos:
    videos.streams.get_highest_resolution().download(output_path='D:\YouTubevideos')

【问题讨论】:

    标签: python youtube pytube


    【解决方案1】:

    升级你的 pytube 包,它应该是固定的。当前版本是10.8.5

    pip install pytube --upgrade
    

    【讨论】:

      【解决方案2】:

      没有解决办法,这是包本身的问题。请等待更新或使用其他 youtube 包,例如 pypi 或 youtube_dl

      【讨论】:

        猜你喜欢
        • 2020-06-21
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2021-06-26
        • 2016-03-19
        • 2021-07-09
        • 1970-01-01
        • 2010-11-08
        相关资源
        最近更新 更多