psf / requests

A simple, yet elegant, HTTP library.
https://requests.readthedocs.io/en/latest/
Apache License 2.0
52.06k stars 9.31k forks source link

Failed to establish a new connection: [Errno 10060] #4292

Closed sus099 closed 6 years ago

sus099 commented 7 years ago

Summary.

Expected Result

What you expected.

Actual Result

What happened instead.

Reproduction Steps

import requests

System Information

$ python -m requests.help

 Downloading to: e:\Learning\Powershell\C#vs.Net\udemy-dl-windows-2.1.3\udemy-dl-windows\csharp-tutorial-for-beginners

 Trying to log in ...
 Exception
Traceback (most recent call last):
  File "udemy_dl.py", line 976, in <module>
  File "udemy_dl.py", line 971, in main
  File "udemy_dl.py", line 766, in udemy_dl
  File "udemy_dl.py", line 156, in login
  File "udemy_dl.py", line 143, in get_csrf_token
  File "udemy_dl.py", line 113, in get
  File "site-packages\requests\sessions.py", line 515, in get
  File "site-packages\requests\sessions.py", line 502, in request
  File "site-packages\requests\sessions.py", line 612, in send
  File "site-packages\requests\adapters.py", line 502, in send
ProxyError: HTTPSConnectionPool(host='www.udemy.com', port=443): Max retries exceeded with url: /join/login-popup (Caused by ProxyError('Cannot connect to proxy.', NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x03571850>: Failed to establish a new connection: [Errno 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond',)))
Failed to execute script udemy_dl
Lukasa commented 7 years ago

Seems like you're having trouble connecting to your proxy. Without a better idea of what's going on, we can't really help you I'm afraid. ☹️

nateprewitt commented 6 years ago

I'm going to close this out due to lack of information and this appearing to be a usability question. If you have more information and feel this is a defect with Requests rather than your environment, we can look at reopening. Thanks!

nyoman commented 6 years ago

I have similar issue, F:\udemy-dl\udemy-dl-windows>udemy-dl.exe https://www.udemy.com/vue-2-crash-course/learn/v4/overview Username / Email : email@example.com Password : Downloading to: F:\udemy-dl\udemy-dl-windows\vue-2-crash-course

Trying to log in ... Exception Traceback (most recent call last): File "udemy_dl.py", line 976, in File "udemy_dl.py", line 971, in main File "udemy_dl.py", line 766, in udemy_dl File "udemy_dl.py", line 156, in login File "udemy_dl.py", line 150, in get_csrf_token AttributeError: 'NoneType' object has no attribute 'group' Failed to execute script udemy_dl

Please help. Thanks.

nateprewitt commented 6 years ago

Hi @nyoman, the stacktrace you provided is unrelated to Requests or this issue. I would suggest asking for assistance from the udemy-dl maintainers or posting a question on StackOverflow. Thanks!

JasonHuangjia commented 5 years ago

I meet the same question, I don't know where the trouble is. Please help me!