mirror of
https://github.com/moparisthebest/SickRage
synced 2024-12-12 11:02:21 -05:00
use tor for generic providers:w
This commit is contained in:
parent
aae27f36f6
commit
65e0dd9ff7
@ -184,7 +184,13 @@ Returns a byte-string retrieved from the url provider.
|
||||
url = urlparse.urlunparse(parsed)
|
||||
|
||||
it = iter(req_headers)
|
||||
resp = requests.get(url, params=params, data=post_data, headers=dict(zip(it, it)))
|
||||
|
||||
proxies = {
|
||||
"http": "http://192.168.1.11:8118",
|
||||
"https": "http://192.168.1.11:8118",
|
||||
}
|
||||
|
||||
resp = requests.get(url, params=params, data=post_data, headers=dict(zip(it, it)), proxies=proxies)
|
||||
except requests.HTTPError, e:
|
||||
logger.log(u"HTTP error " + str(e.errno) + " while loading URL " + url, logger.WARNING)
|
||||
return None
|
||||
@ -981,4 +987,4 @@ def real_path(path):
|
||||
"""
|
||||
Returns: the canonicalized absolute pathname. The resulting path will have no symbolic link, '/./' or '/../' components.
|
||||
"""
|
||||
return ek.ek(os.path.normpath, ek.ek(os.path.normcase, ek.ek(os.path.realpath, path)))
|
||||
return ek.ek(os.path.normpath, ek.ek(os.path.normcase, ek.ek(os.path.realpath, path)))
|
||||
|
Loading…
Reference in New Issue
Block a user