[Python] PytubeFix and others libraries doesnt work very well

Discussão em 'Python' iniciado por Stack, Março 23, 2025.

  1. Stack

    Stack Membro Participativo

    When I download in 'highest resolution', the video always downloads in 640x360, no matter how I "reformulate" it.

    I think maybe it is downloading this preview: previewing a video on the youtube homepage

    from pytubefix import YouTube

    video = "https://youtu.be/NI9LXzo0UY0?si=_Jy_CzN-QwI4SOkC"

    def Download(link):
    youtube_object = YouTube(link)
    youtube_object = youtube_object.streams.get_highest_resolution()
    try:
    youtube_object.download()
    except:
    print("An error has occurred")
    print("Download is completed successfully")


    Download(video)


    I try using three libraries:

    1. pytube (discontinued)
    2. pytubefix
    3. yt_dlp

    All downloads in 360p and I expect the highest possible quality, normally 1080p

    Continue reading...

Compartilhe esta Página