|
46 | 46 | # Python 3 |
47 | 47 | from urllib.parse import urlencode |
48 | 48 |
|
49 | | -from .vendor.requests import request, Session |
50 | | -from .vendor.requests.packages import urllib3 |
51 | | -from .vendor.requests.exceptions import RequestException |
52 | | - |
53 | | -# Disable pyopenssl. It breaks SSL connection pool when SSL connection is |
54 | | -# closed unexpectedly by the server. And we don't need SNI anyway. |
55 | | -try: |
56 | | - from .vendor.requests.packages.urllib3.contrib import pyopenssl |
57 | | - pyopenssl.extract_from_urllib3() |
58 | | -except ImportError: |
59 | | - pass |
60 | | - |
61 | | -# Disable SNI related Warning. The API does not rely on it |
62 | | -urllib3.disable_warnings(urllib3.exceptions.SNIMissingWarning) |
63 | | -urllib3.disable_warnings(urllib3.exceptions.SecurityWarning) |
| 49 | +from requests import request, Session |
| 50 | +from requests.packages import urllib3 |
| 51 | +from requests.exceptions import RequestException |
64 | 52 |
|
65 | 53 | from .config import config |
66 | 54 | from .consumer_key import ConsumerKeyRequest |
@@ -483,7 +471,7 @@ def raw_call(self, method, path, data=None, need_auth=True): |
483 | 471 | """ |
484 | 472 | Lowest level call helper. If ``consumer_key`` is not ``None``, inject |
485 | 473 | authentication headers and sign the request. |
486 | | - Will return a vendored ``requests.Response`` object or let any |
| 474 | + Will return ``requests.Response`` object or let any |
487 | 475 | ``requests`` exception pass through. |
488 | 476 |
|
489 | 477 | Request signature is a sha1 hash on following fields, joined by '+' |
|
0 commit comments