diff options
author | arcadia-devtools <arcadia-devtools@yandex-team.ru> | 2022-06-14 12:58:08 +0300 |
---|---|---|
committer | arcadia-devtools <arcadia-devtools@yandex-team.ru> | 2022-06-14 12:58:08 +0300 |
commit | 779122141c88885682c913bb05f9337579c2006c (patch) | |
tree | a1950bcd7a5d56f0a1d31142fae6a666178d8230 /contrib/python/requests/py3/patches/01-arcadia.patch | |
parent | 3472d1ac59ed9de4b1d8091b507660d3bdc55f9a (diff) | |
download | ydb-779122141c88885682c913bb05f9337579c2006c.tar.gz |
intermediate changes
ref:d537698eabf7776f0407a570f9e2d6517d0627b9
Diffstat (limited to 'contrib/python/requests/py3/patches/01-arcadia.patch')
-rw-r--r-- | contrib/python/requests/py3/patches/01-arcadia.patch | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/contrib/python/requests/py3/patches/01-arcadia.patch b/contrib/python/requests/py3/patches/01-arcadia.patch index 4fabe03bbc..30b2617ba9 100644 --- a/contrib/python/requests/py3/patches/01-arcadia.patch +++ b/contrib/python/requests/py3/patches/01-arcadia.patch @@ -1,15 +1,17 @@ --- contrib/python/requests/py3/requests/adapters.py (index) +++ contrib/python/requests/py3/requests/adapters.py (working tree) -@@ -224,13 +224,13 @@ class HTTPAdapter(BaseAdapter): +@@ -259,7 +259,7 @@ class HTTPAdapter(BaseAdapter): if not cert_loc: cert_loc = extract_zipped_paths(DEFAULT_CA_BUNDLE_PATH) - if not cert_loc or not os.path.exists(cert_loc): + if not cert_loc or isinstance(cert_loc, basestring) and not os.path.exists(cert_loc): - raise IOError("Could not find a suitable TLS CA certificate bundle, " - "invalid path: {}".format(cert_loc)) + raise OSError( + f"Could not find a suitable TLS CA certificate bundle, " + f"invalid path: {cert_loc}" +@@ -267,7 +267,7 @@ class HTTPAdapter(BaseAdapter): - conn.cert_reqs = 'CERT_REQUIRED' + conn.cert_reqs = "CERT_REQUIRED" - if not os.path.isdir(cert_loc): + if not isinstance(cert_loc, basestring) or not os.path.isdir(cert_loc): @@ -18,7 +20,7 @@ conn.ca_cert_dir = cert_loc --- contrib/python/requests/py3/requests/utils.py (index) +++ contrib/python/requests/py3/requests/utils.py (working tree) -@@ -246,7 +246,7 @@ def extract_zipped_paths(path): +@@ -260,7 +260,7 @@ def extract_zipped_paths(path): archive with the location of an extracted copy of the target, or else just return the provided path unchanged. """ |