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

YouTube blocking: 加上--proxy "socks5://127.0.0.1:11223"依旧出现 由于目标计算机积极拒绝,无法连接 #31438

Closed
5 of 6 tasks
9leaa opened this issue Dec 25, 2022 · 5 comments

Comments

@9leaa
Copy link

9leaa commented Dec 25, 2022

Checklist

  • I'm reporting a broken site support issue
  • I've verified that I'm running youtube-dl version 2021.12.17
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that all URLs and arguments with special characters are properly quoted or escaped
  • I've searched the bugtracker for similar bug reports including closed ones
  • I've read bugs section in FAQ

Verbose log

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-v', 'https://www.youtube.com/watch?v=htw7OpKrxRE', '--proxy', 'socks5://127.0.0.1:11223']
[debug] Encodings: locale cp936, fs utf-8, out utf-8, pref cp936
[debug] youtube-dl version 2021.12.17
[debug] Python version 3.9.7 (CPython) - Windows-10-10.0.19044-SP0
[debug] exe versions: none
[debug] Proxy map: {'http': 'socks5://127.0.0.1:11223', 'https': 'socks5://127.0.0.1:11223'}
[youtube] htw7OpKrxRE: Downloading webpage
WARNING: Unable to download webpage: <urlopen error [WinError 10061] 由于目标计算机积极拒绝,无法连接。>
[youtube] htw7OpKrxRE: Downloading API JSON
ERROR: Unable to download API page: <urlopen error [WinError 10061] 由于目标计算机积极拒绝,无法连接。> (caused by URLError(ConnectionRefusedError(10061, '由于目标计算机积极拒绝,无法连接。', None, 10061, None)))
  File "E:\anaconda\lib\site-packages\youtube_dl\extractor\common.py", line 634, in _request_webpage
    return self._downloader.urlopen(url_or_request)
  File "E:\anaconda\lib\site-packages\youtube_dl\YoutubeDL.py", line 2288, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "E:\anaconda\lib\urllib\request.py", line 517, in open
    response = self._open(req, data)
  File "E:\anaconda\lib\urllib\request.py", line 534, in _open
    result = self._call_chain(self.handle_open, protocol, protocol +
  File "E:\anaconda\lib\urllib\request.py", line 494, in _call_chain
    result = func(*args)
  File "E:\anaconda\lib\site-packages\youtube_dl\utils.py", line 2735, in https_open
    return self.do_open(functools.partial(
  File "E:\anaconda\lib\urllib\request.py", line 1349, in do_open
    raise URLError(err)

Description

WRITE DESCRIPTION HERE
我加上了 --proxy "socks5://127.0.0.1:11223"依旧出现 由于目标计算机积极拒绝,无法连接

@9leaa
Copy link
Author

9leaa commented Dec 25, 2022

我开启了v2rayN,能够正常访问并播放youtube的视频

@dirkf
Copy link
Contributor

dirkf commented Dec 25, 2022

G translate says for OP

I added --proxy "socks5://127.0.0.1:11223" and it still appears Cannot connect because the target computer actively refuses

And for #31438 (comment):

I turned on v2rayN, and I was able to access and play youtube videos normally

  1. Because it's Christmas (Merry Winterval to all readers) I made the effort to translate your posts for the ~7 billion non-Chinese readers. Issues should be posted in English please; if you use some translation engine, post your original text too to help people who can read it in case the translation is screwy.
  2. Your access to YT is being blocked by some intermediate system, a Great Firewall or whatever.
  3. Your socks proxy isn't working.
  4. Your VPN is working.

@dirkf dirkf changed the title 加上--proxy "socks5://127.0.0.1:11223"依旧出现 由于目标计算机积极拒绝,无法连接 YouTube blocking: 加上--proxy "socks5://127.0.0.1:11223"依旧出现 由于目标计算机积极拒绝,无法连接 Dec 25, 2022
@dirkf
Copy link
Contributor

dirkf commented Jan 9, 2023

Closing for lack of response.

@HGGshiwo
Copy link

HGGshiwo commented Dec 5, 2024

same error, could you please take a look? the log is :

youtube-dl -o ./videos/aaa.mp4 -f best --proxy "https://127.0.0.1:7890" -v  https://www.youtube.com/watch?v=q2zj74iK1MI
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-o', './videos/aaa.mp4', '-f', 'best', '--proxy', 'https://127.0.0.1:7890', '-v', 'https://www.youtube.com/watch?v=q2zj74iK1MI']
[debug] Encodings: locale cp936, fs mbcs, out cp936, pref cp936
[debug] youtube-dl version 2021.12.17
[debug] Python version 3.4.4 (CPython) - Windows-10-10.0.22621
[debug] exe versions: none
[debug] Proxy map: {'http': 'https://127.0.0.1:7890', 'https': 'https://127.0.0.1:7890'}
[youtube] q2zj74iK1MI: Downloading webpage
WARNING: Unable to download webpage: <urlopen error [WinError 10061] 由于目标计算机积极拒绝,无法连接。>
[youtube] q2zj74iK1MI: Downloading API JSON
ERROR: Unable to download API page: <urlopen error [WinError 10061] 由于目标计算机积极拒绝,无法连接。> (caused by URLError(ConnectionRefusedError(10061, '由于目标计算机积极拒绝,无法连接。', None, 10061, None),))
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmpupik7c6w\build\youtube_dl\extractor\common.py", line 634, in _request_webpage
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmpupik7c6w\build\youtube_dl\YoutubeDL.py", line 2288, in urlopen
  File "C:\Python\Python34\lib\urllib\request.py", line 464, in open
  File "C:\Python\Python34\lib\urllib\request.py", line 482, in _open
  File "C:\Python\Python34\lib\urllib\request.py", line 442, in _call_chain
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmpupik7c6w\build\youtube_dl\utils.py", line 2737, in https_open
  File "C:\Python\Python34\lib\urllib\request.py", line 1185, in do_open

By the way, I use the latest version, 2021.12.17

@dirkf
Copy link
Contributor

dirkf commented Dec 5, 2024

This is not the same error, but rather #32549 (https: proxy vs sock5:).

If you managed to get whatever the proxy is supposed to be doing to work, perhaps by following one of the suggestions in that issue, you would need the nightly build (read #30839) and (currently) a work-around per #32905 for the program to work with YouTube.

At that point, if you have an error that is not #32549 or #32905, you could consider opening a new issue according to #30839.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants