From 6416aca1618a9afa761db632847923310a6f31be Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 7 Jan 2025 09:43:56 +0000 Subject: [PATCH] chore(internal): bump httpx dependency (#557) --- pyproject.toml | 2 +- requirements-dev.lock | 5 ++--- requirements.lock | 3 +-- tests/test_client.py | 25 +++++++++++++++++++++++++ 4 files changed, 29 insertions(+), 6 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 6a53396d..e97d0f6f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ dev-dependencies = [ "dirty-equals>=0.6.0", "importlib-metadata>=6.7.0", "rich>=13.7.1", - "nest_asyncio==1.6.0" + "nest_asyncio==1.6.0", ] [tool.rye.scripts] diff --git a/requirements-dev.lock b/requirements-dev.lock index 545f94f7..e07de0a7 100644 --- a/requirements-dev.lock +++ b/requirements-dev.lock @@ -35,7 +35,7 @@ h11==0.14.0 # via httpcore httpcore==1.0.2 # via httpx -httpx==0.25.2 +httpx==0.28.1 # via finch-api # via respx idna==3.4 @@ -76,7 +76,7 @@ python-dateutil==2.8.2 # via time-machine pytz==2023.3.post1 # via dirty-equals -respx==0.20.2 +respx==0.22.0 rich==13.7.1 ruff==0.6.9 setuptools==68.2.2 @@ -86,7 +86,6 @@ six==1.16.0 sniffio==1.3.0 # via anyio # via finch-api - # via httpx time-machine==2.9.0 tomli==2.0.2 # via mypy diff --git a/requirements.lock b/requirements.lock index ab955494..7d43b8d3 100644 --- a/requirements.lock +++ b/requirements.lock @@ -25,7 +25,7 @@ h11==0.14.0 # via httpcore httpcore==1.0.2 # via httpx -httpx==0.25.2 +httpx==0.28.1 # via finch-api idna==3.4 # via anyio @@ -37,7 +37,6 @@ pydantic-core==2.27.1 sniffio==1.3.0 # via anyio # via finch-api - # via httpx typing-extensions==4.12.2 # via anyio # via finch-api diff --git a/tests/test_client.py b/tests/test_client.py index b43a181c..8ff4db44 100644 --- a/tests/test_client.py +++ b/tests/test_client.py @@ -17,6 +17,7 @@ import httpx import pytest +import packaging.version as version from respx import MockRouter from pydantic import ValidationError @@ -643,6 +644,10 @@ def test_absolute_request_url(self, client: Finch) -> None: ) assert request.url == "https://myapi.com/foo" + @pytest.mark.skipif( + version.parse(httpx.__version__) >= version.parse("0.28.0"), + reason="Test is only relevant for httpx versions < 0.28.0", + ) def test_transport_option_is_deprecated(self) -> None: with pytest.warns( DeprecationWarning, @@ -672,6 +677,10 @@ def test_transport_option_mutually_exclusive_with_http_client(self) -> None: http_client=http_client, ) + @pytest.mark.skipif( + version.parse(httpx.__version__) >= version.parse("0.28.0"), + reason="Test is only relevant for httpx versions < 0.28.0", + ) def test_connection_pool_limits_option_is_deprecated(self) -> None: with pytest.warns( DeprecationWarning, @@ -709,6 +718,10 @@ def test_connection_pool_limits_option_mutually_exclusive_with_http_client(self) http_client=http_client, ) + @pytest.mark.skipif( + version.parse(httpx.__version__) >= version.parse("0.28.0"), + reason="Test is only relevant for httpx versions < 0.28.0", + ) def test_proxies_option_is_deprecated(self) -> None: with pytest.warns( DeprecationWarning, @@ -1527,6 +1540,10 @@ def test_absolute_request_url(self, client: AsyncFinch) -> None: ) assert request.url == "https://myapi.com/foo" + @pytest.mark.skipif( + version.parse(httpx.__version__) >= version.parse("0.28.0"), + reason="Test is only relevant for httpx versions < 0.28.0", + ) def test_transport_option_is_deprecated(self) -> None: with pytest.warns( DeprecationWarning, @@ -1556,6 +1573,10 @@ async def test_transport_option_mutually_exclusive_with_http_client(self) -> Non http_client=http_client, ) + @pytest.mark.skipif( + version.parse(httpx.__version__) >= version.parse("0.28.0"), + reason="Test is only relevant for httpx versions < 0.28.0", + ) def test_connection_pool_limits_option_is_deprecated(self) -> None: with pytest.warns( DeprecationWarning, @@ -1593,6 +1614,10 @@ async def test_connection_pool_limits_option_mutually_exclusive_with_http_client http_client=http_client, ) + @pytest.mark.skipif( + version.parse(httpx.__version__) >= version.parse("0.28.0"), + reason="Test is only relevant for httpx versions < 0.28.0", + ) def test_proxies_option_is_deprecated(self) -> None: with pytest.warns( DeprecationWarning,