Skip to content

Commit 9f0452a

Browse files
committed
Drop support for urllib3 1.x
It isn't supported upstream anymore.
1 parent bfe6acc commit 9f0452a

File tree

3 files changed

+3
-16
lines changed

3 files changed

+3
-16
lines changed

requirements-min.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
requests==2.26.0
2-
urllib3==1.26.2
1+
requests==2.30.0
2+
urllib3==2.0.3
33
aiohttp==3.8.0
44
httpx==0.27.0

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
package_data={"elastic_transport": ["py.typed"]},
5151
packages=packages,
5252
install_requires=[
53-
"urllib3>=1.26.2, <3",
53+
"urllib3>=2, <3",
5454
"certifi",
5555
"sniffio",
5656
],

tests/test_httpserver.py

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -18,27 +18,14 @@
1818
import warnings
1919

2020
import pytest
21-
import requests
22-
import urllib3
2321

2422
from elastic_transport import Transport
2523

2624

2725
@pytest.mark.parametrize("node_class", ["urllib3", "requests"])
2826
def test_simple_request(node_class, https_server_ip_node_config):
29-
# when testing minimum urllib3 and requests dependencies, we disable
30-
# the deprecation warning for ssl.match_hostname()
31-
silence_ssl_deprecation = (
32-
node_class == "urllib3" and urllib3.__version__ == "1.26.2"
33-
) or (node_class == "requests" and requests.__version__ == "2.26.0")
34-
3527
with warnings.catch_warnings():
3628
warnings.simplefilter("error")
37-
if silence_ssl_deprecation:
38-
warnings.filterwarnings(
39-
"ignore", ".*match_hostname.*deprecated", DeprecationWarning
40-
)
41-
4229
t = Transport([https_server_ip_node_config], node_class=node_class)
4330

4431
resp, data = t.perform_request("GET", "/foobar")

0 commit comments

Comments
 (0)