File: 0001-Don-t-use-duplicated-modules.patch

package info (click to toggle)
python-botocore 1.37.9%2Brepack-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 121,768 kB
  • sloc: python: 73,696; xml: 14,880; javascript: 181; makefile: 155
file content (97 lines) | stat: -rw-r--r-- 3,866 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
From: TANIGUCHI Takaki <takaki@asis.media-as.org>
Date: Thu, 4 Oct 2018 16:22:43 +0900
Subject: Don't use duplicated modules

---
 botocore/compat.py                               | 4 ++--
 botocore/endpoint.py                             | 2 +-
 botocore/exceptions.py                           | 4 ++--
 botocore/httpsession.py                          | 4 ++--
 botocore/utils.py                                | 2 +-
 tests/functional/test_six_threading.py           | 4 ++--
 tests/integration/test_client_http.py            | 4 ++--
 tests/integration/test_glacier.py                | 2 +-
 tests/integration/test_s3.py                     | 2 +-
 tests/unit/test_endpoint.py                      | 2 +-
 tests/unit/test_http_client_exception_mapping.py | 4 ++--
 tests/unit/test_http_session.py                  | 2 +-
 12 files changed, 18 insertions(+), 18 deletions(-)

Index: python-botocore/botocore/compat.py
===================================================================
--- python-botocore.orig/botocore/compat.py
+++ python-botocore/botocore/compat.py
@@ -26,7 +26,7 @@ from collections import OrderedDict
 from collections.abc import MutableMapping
 from math import floor
 
-from botocore.vendored import six
+import six
 from botocore.exceptions import MD5UnavailableError
 from dateutil.tz import tzlocal
 from urllib3 import exceptions
Index: python-botocore/botocore/exceptions.py
===================================================================
--- python-botocore.orig/botocore/exceptions.py
+++ python-botocore/botocore/exceptions.py
@@ -12,8 +12,8 @@
 # ANY KIND, either express or implied. See the License for the specific
 # language governing permissions and limitations under the License.
 
-from botocore.vendored import requests
-from botocore.vendored.requests.packages import urllib3
+import requests
+from requests.packages import urllib3
 
 
 def _exception_from_packed_args(exception_cls, args=None, kwargs=None):
Index: python-botocore/tests/functional/test_six_threading.py
===================================================================
--- python-botocore.orig/tests/functional/test_six_threading.py
+++ python-botocore/tests/functional/test_six_threading.py
@@ -5,7 +5,7 @@ import sys
 import threading
 import time
 
-from botocore.vendored import six
+import six
 from tests import mock
 
 _original_setattr = six.moves.__class__.__setattr__
@@ -46,7 +46,7 @@ class _ExampleThread(threading.Thread):
 def test_six_thread_safety():
     _reload_six()
     with mock.patch(
-        'botocore.vendored.six.moves.__class__.__setattr__',
+        'six.moves.__class__.__setattr__',
         wraps=_wrapped_setattr,
     ):
         threads = []
Index: python-botocore/tests/integration/test_client_http.py
===================================================================
--- python-botocore.orig/tests/integration/test_client_http.py
+++ python-botocore/tests/integration/test_client_http.py
@@ -16,7 +16,7 @@ from botocore.exceptions import (
     ProxyConnectionError,
     ReadTimeoutError,
 )
-from botocore.vendored.requests import exceptions as requests_exceptions
+from requests import exceptions as requests_exceptions
 from tests import mock, unittest
 
 
Index: python-botocore/tests/unit/test_http_client_exception_mapping.py
===================================================================
--- python-botocore.orig/tests/unit/test_http_client_exception_mapping.py
+++ python-botocore/tests/unit/test_http_client_exception_mapping.py
@@ -1,8 +1,8 @@
 import pytest
 
 from botocore import exceptions as botocore_exceptions
-from botocore.vendored.requests import exceptions as requests_exceptions
-from botocore.vendored.requests.packages.urllib3 import (
+from requests import exceptions as requests_exceptions
+from requests.packages.urllib3 import (
     exceptions as urllib3_exceptions,
 )