Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No error code but download just not starts #345

Closed
AleMk8 opened this issue Nov 21, 2024 · 1 comment
Closed

No error code but download just not starts #345

AleMk8 opened this issue Nov 21, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@AleMk8
Copy link

AleMk8 commented Nov 21, 2024

❗ DO NOT REMOVE OR SKIP THE ISSUE TEMPLATE ❗

lack of information will lead to closure of the issue


Describe the bug

I'm having some problems trying to download videos and audio. The script hangs without throwing any error code, it just seems like the download never starts for very long time than it will works.
I have tried different versions of Python (3.12 and 3.13), different versions of pytubefix and different computers without encountering any kind of problem like bot detection and so on.
My script works fine with a virtual machine running on Kali Linux 2024.3 but doesn't work on different machines running W11 and MacOS.
I figured out how to run the script on all machines, I have to use my cell phone hotspot except for the virtual machine which works fine on the default LAN.
To recapt. On W11 and MacOS using LAN the download starts after about 4/5 minutes, on my virtual machine it's instant.
Using hotspot from other source is istant on evey platform.
Anyone have any ideas?


code that was used that resulted in the bug

from pytubefix import YouTube
from pytubefix.exceptions import PytubeFixError


if __name__ == '__main__':
    try:
        print('start')
        music = (YouTube('https://www.youtube.com/watch?v=sa6u_Pnj_JU').streams.get_audio_only()
                 .download(output_path="/path/to/dir"))
    except PytubeFixError as e:
        print(e)

Expected behavior
PyTubeFixError or a download


Screenshots
If applicable, add screenshots to help explain your problem.


Desktop (please complete the following information):

  • OS: Windows 11/MacOS
  • Python Version [3.12/3.13]
  • Pytubefix Version [last]

Additional context
Add any other context about the problem here.

@AleMk8 AleMk8 added the bug Something isn't working label Nov 21, 2024
@AleMk8
Copy link
Author

AleMk8 commented Nov 21, 2024

Update... now is incredibly slow to start the download even on the virtual machine.
And i got the followig error:
ConnectionResetError: [WinError 10054] An existing connection was forcibly closed by the remote host.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Development

No branches or pull requests

2 participants