]>
Commit | Line | Data |
---|---|---|
d49507cd AM |
1 | diff -urNp requests-2.5.3.org/requests/adapters.py requests-2.5.3/requests/adapters.py |
2 | --- requests-2.5.3.org/requests/adapters.py 2014-12-01 22:02:39.000000000 +0100 | |
3 | +++ requests-2.5.3/requests/adapters.py 2015-03-06 20:15:36.361707968 +0100 | |
4 | @@ -11,22 +11,22 @@ and maintain connections. | |
2d9e9bd0 ŁK |
5 | import socket |
6 | ||
7 | from .models import Response | |
9e57f9c2 | 8 | -from .packages.urllib3 import Retry |
23ad999c | 9 | -from .packages.urllib3.poolmanager import PoolManager, proxy_from_url |
2d9e9bd0 | 10 | -from .packages.urllib3.response import HTTPResponse |
23ad999c | 11 | -from .packages.urllib3.util import Timeout as TimeoutSauce |
9e57f9c2 | 12 | +from urllib3 import Retry |
23ad999c | 13 | +from urllib3.poolmanager import PoolManager, proxy_from_url |
2d9e9bd0 | 14 | +from urllib3.response import HTTPResponse |
23ad999c | 15 | +from urllib3.util import Timeout as TimeoutSauce |
6b8cdf9f | 16 | from .compat import urlparse, basestring |
2d9e9bd0 | 17 | from .utils import (DEFAULT_CA_BUNDLE_PATH, get_encoding_from_headers, |
6b8cdf9f | 18 | prepend_scheme_if_needed, get_auth_from_url, urldefragauth) |
2d9e9bd0 | 19 | from .structures import CaseInsensitiveDict |
9e57f9c2 | 20 | -from .packages.urllib3.exceptions import ConnectTimeoutError |
2d9e9bd0 | 21 | -from .packages.urllib3.exceptions import HTTPError as _HTTPError |
9e57f9c2 | 22 | -from .packages.urllib3.exceptions import MaxRetryError |
23ad999c | 23 | -from .packages.urllib3.exceptions import ProxyError as _ProxyError |
9e57f9c2 AM |
24 | -from .packages.urllib3.exceptions import ProtocolError |
25 | -from .packages.urllib3.exceptions import ReadTimeoutError | |
26 | -from .packages.urllib3.exceptions import SSLError as _SSLError | |
27c2bafe | 27 | -from .packages.urllib3.exceptions import ResponseError |
9e57f9c2 | 28 | +from urllib3.exceptions import ConnectTimeoutError |
2d9e9bd0 | 29 | +from urllib3.exceptions import HTTPError as _HTTPError |
9e57f9c2 | 30 | +from urllib3.exceptions import MaxRetryError |
23ad999c | 31 | +from urllib3.exceptions import ProxyError as _ProxyError |
9e57f9c2 AM |
32 | +from urllib3.exceptions import ProtocolError |
33 | +from urllib3.exceptions import ReadTimeoutError | |
34 | +from urllib3.exceptions import SSLError as _SSLError | |
27c2bafe | 35 | +from urllib3.exceptions import ResponseError |
2d9e9bd0 | 36 | from .cookies import extract_cookies_to_jar |
9e57f9c2 | 37 | from .exceptions import (ConnectionError, ConnectTimeout, ReadTimeout, SSLError, |
27c2bafe | 38 | ProxyError, RetryError) |
d49507cd AM |
39 | diff -urNp requests-2.5.3.org/requests/compat.py requests-2.5.3/requests/compat.py |
40 | --- requests-2.5.3.org/requests/compat.py 2015-02-24 17:27:00.000000000 +0100 | |
41 | +++ requests-2.5.3/requests/compat.py 2015-03-06 20:15:36.365041382 +0100 | |
2d9e9bd0 ŁK |
42 | @@ -4,7 +4,7 @@ |
43 | pythoncompat | |
44 | """ | |
45 | ||
b906e79c | 46 | -from .packages import chardet |
2d9e9bd0 ŁK |
47 | +import charade as chardet |
48 | ||
49 | import sys | |
50 | ||
d49507cd | 51 | @@ -39,7 +39,7 @@ if is_py2: |
2d9e9bd0 ŁK |
52 | import cookielib |
53 | from Cookie import Morsel | |
54 | from StringIO import StringIO | |
55 | - from .packages.urllib3.packages.ordered_dict import OrderedDict | |
56 | + from urllib3.packages.ordered_dict import OrderedDict | |
57 | ||
58 | builtin_str = str | |
9e57f9c2 | 59 | bytes = str |
d49507cd AM |
60 | diff -urNp requests-2.5.3.org/requests/exceptions.py requests-2.5.3/requests/exceptions.py |
61 | --- requests-2.5.3.org/requests/exceptions.py 2014-12-01 22:02:39.000000000 +0100 | |
62 | +++ requests-2.5.3/requests/exceptions.py 2015-03-06 20:15:36.368374796 +0100 | |
63 | @@ -7,7 +7,7 @@ requests.exceptions | |
b906e79c AM |
64 | This module contains the set of Requests' exceptions. |
65 | ||
66 | """ | |
67 | -from .packages.urllib3.exceptions import HTTPError as BaseHTTPError | |
68 | +from urllib3.exceptions import HTTPError as BaseHTTPError | |
69 | ||
70 | ||
71 | class RequestException(IOError): | |
d49507cd AM |
72 | diff -urNp requests-2.5.3.org/requests/__init__.py requests-2.5.3/requests/__init__.py |
73 | --- requests-2.5.3.org/requests/__init__.py 2015-02-24 17:33:01.000000000 +0100 | |
74 | +++ requests-2.5.3/requests/__init__.py 2015-03-06 20:15:36.358374555 +0100 | |
75 | @@ -50,7 +50,7 @@ __copyright__ = 'Copyright 2015 Kenneth | |
2d9e9bd0 ŁK |
76 | |
77 | # Attempt to enable urllib3's SNI support, if possible | |
78 | try: | |
23ad999c | 79 | - from .packages.urllib3.contrib import pyopenssl |
2d9e9bd0 ŁK |
80 | + from urllib3.contrib import pyopenssl |
81 | pyopenssl.inject_into_urllib3() | |
82 | except ImportError: | |
83 | pass | |
d49507cd AM |
84 | diff -urNp requests-2.5.3.org/requests/models.py requests-2.5.3/requests/models.py |
85 | --- requests-2.5.3.org/requests/models.py 2014-12-23 18:43:04.000000000 +0100 | |
86 | +++ requests-2.5.3/requests/models.py 2015-03-06 20:15:36.375041624 +0100 | |
87 | @@ -16,10 +16,10 @@ from .structures import CaseInsensitiveD | |
2d9e9bd0 ŁK |
88 | |
89 | from .auth import HTTPBasicAuth | |
90 | from .cookies import cookiejar_from_dict, get_cookie_header | |
23ad999c | 91 | -from .packages.urllib3.fields import RequestField |
2d9e9bd0 ŁK |
92 | -from .packages.urllib3.filepost import encode_multipart_formdata |
93 | -from .packages.urllib3.util import parse_url | |
9e57f9c2 | 94 | -from .packages.urllib3.exceptions import ( |
23ad999c | 95 | +from urllib3.fields import RequestField |
2d9e9bd0 ŁK |
96 | +from urllib3.filepost import encode_multipart_formdata |
97 | +from urllib3.util import parse_url | |
9e57f9c2 | 98 | +from urllib3.exceptions import ( |
d49507cd | 99 | DecodeError, ReadTimeoutError, ProtocolError, LocationParseError) |
23ad999c | 100 | from .exceptions import ( |
d49507cd AM |
101 | HTTPError, MissingSchema, InvalidURL, ChunkedEncodingError, |
102 | diff -urNp requests-2.5.3.org/requests/packages/__init__.py requests-2.5.3/requests/packages/__init__.py | |
103 | --- requests-2.5.3.org/requests/packages/__init__.py 2015-02-24 17:27:00.000000000 +0100 | |
104 | +++ requests-2.5.3/requests/packages/__init__.py 2015-03-06 20:15:36.375041624 +0100 | |
105 | @@ -65,7 +65,7 @@ class VendorAlias(object): | |
106 | finally: | |
107 | # Re-add any additions to sys.meta_path that were made while | |
108 | # during the import we just did, otherwise things like | |
109 | - # requests.packages.urllib3.poolmanager will fail. | |
110 | + # urllib3.poolmanager will fail. | |
111 | for m in sys.meta_path: | |
112 | if m not in real_meta_path: | |
113 | real_meta_path.append(m) | |
114 | diff -urNp requests-2.5.3.org/requests/sessions.py requests-2.5.3/requests/sessions.py | |
115 | --- requests-2.5.3.org/requests/sessions.py 2014-12-01 22:02:39.000000000 +0100 | |
116 | +++ requests-2.5.3/requests/sessions.py 2015-03-06 20:15:36.488377701 +0100 | |
117 | @@ -21,7 +21,7 @@ from .hooks import default_hooks, dispat | |
27c2bafe AM |
118 | from .utils import to_key_val_list, default_headers, to_native_string |
119 | from .exceptions import ( | |
120 | TooManyRedirects, InvalidSchema, ChunkedEncodingError, ContentDecodingError) | |
121 | -from .packages.urllib3._collections import RecentlyUsedContainer | |
122 | +from urllib3._collections import RecentlyUsedContainer | |
123 | from .structures import CaseInsensitiveDict | |
124 | ||
125 | from .adapters import HTTPAdapter | |
d49507cd AM |
126 | diff -urNp requests-2.5.3.org/setup.py requests-2.5.3/setup.py |
127 | --- requests-2.5.3.org/setup.py 2014-09-10 17:30:41.000000000 +0200 | |
128 | +++ requests-2.5.3/setup.py 2015-03-06 20:16:15.829329894 +0100 | |
129 | @@ -18,13 +18,6 @@ if sys.argv[-1] == 'publish': | |
23ad999c ŁK |
130 | |
131 | packages = [ | |
9e57f9c2 | 132 | 'requests', |
23ad999c | 133 | - 'requests.packages', |
b906e79c | 134 | - 'requests.packages.chardet', |
23ad999c ŁK |
135 | - 'requests.packages.urllib3', |
136 | - 'requests.packages.urllib3.packages', | |
137 | - 'requests.packages.urllib3.contrib', | |
b906e79c AM |
138 | - 'requests.packages.urllib3.util', |
139 | - 'requests.packages.urllib3.packages.ssl_match_hostname', | |
23ad999c ŁK |
140 | ] |
141 | ||
142 | requires = [] | |
d49507cd AM |
143 | diff -urNp requests-2.5.3.org/test_requests.py requests-2.5.3/test_requests.py |
144 | --- requests-2.5.3.org/test_requests.py 2015-02-24 17:27:00.000000000 +0100 | |
145 | +++ requests-2.5.3/test_requests.py 2015-03-06 20:15:36.498377943 +0100 | |
146 | @@ -1589,7 +1589,7 @@ def test_prepare_unicode_url(): | |
27c2bafe AM |
147 | |
148 | ||
149 | def test_urllib3_retries(): | |
150 | - from requests.packages.urllib3.util import Retry | |
151 | + from urllib3.util import Retry | |
152 | s = requests.Session() | |
d49507cd | 153 | s.mount('http://', HTTPAdapter(max_retries=Retry( |
27c2bafe | 154 | total=2, status_forcelist=[500] |