diff options
| author | Philipp Hagemeister <phihag@phihag.de> | 2015-03-03 00:03:06 +0100 | 
|---|---|---|
| committer | Philipp Hagemeister <phihag@phihag.de> | 2015-03-03 00:03:06 +0100 | 
| commit | 91410c9bfa9fd8f01fb817474bcc7b0db5cabf95 (patch) | |
| tree | f945f83ed897b9546e3a82dca31195684781b03d /youtube_dl/YoutubeDL.py | |
| parent | a7440261c52d6518a429210aaae598095112c61b (diff) | |
[letv] Add --cn-verification-proxy (Closes #5077)
Diffstat (limited to 'youtube_dl/YoutubeDL.py')
| -rwxr-xr-x | youtube_dl/YoutubeDL.py | 5 | 
1 files changed, 4 insertions, 1 deletions
diff --git a/youtube_dl/YoutubeDL.py b/youtube_dl/YoutubeDL.py index e0baa9872..915963d96 100755 --- a/youtube_dl/YoutubeDL.py +++ b/youtube_dl/YoutubeDL.py @@ -54,6 +54,7 @@ from .utils import (      MaxDownloadsReached,      PagedList,      parse_filesize, +    PerRequestProxyHandler,      PostProcessingError,      platform_name,      preferredencoding, @@ -183,6 +184,8 @@ class YoutubeDL(object):      prefer_insecure:   Use HTTP instead of HTTPS to retrieve information.                         At the moment, this is only supported by YouTube.      proxy:             URL of the proxy server to use +    cn_verification_proxy:  URL of the proxy to use for IP address verification +                       on Chinese sites. (Experimental)      socket_timeout:    Time to wait for unresponsive hosts, in seconds      bidi_workaround:   Work around buggy terminals without bidirectional text                         support, using fridibi @@ -1762,7 +1765,7 @@ class YoutubeDL(object):              # Set HTTPS proxy to HTTP one if given (https://github.com/rg3/youtube-dl/issues/805)              if 'http' in proxies and 'https' not in proxies:                  proxies['https'] = proxies['http'] -        proxy_handler = compat_urllib_request.ProxyHandler(proxies) +        proxy_handler = PerRequestProxyHandler(proxies)          debuglevel = 1 if self.params.get('debug_printtraffic') else 0          https_handler = make_HTTPS_handler(self.params, debuglevel=debuglevel)  | 
