From c5f4c15a55650d1f072f4e46974461d5a647b4c2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 5 Dec 2024 07:32:14 +0000 Subject: [PATCH 1/2] chore(deps-dev): bump httpx[http2] from 0.27.2 to 0.28.0 Bumps [httpx[http2]](https://github.com/encode/httpx) from 0.27.2 to 0.28.0. - [Release notes](https://github.com/encode/httpx/releases) - [Changelog](https://github.com/encode/httpx/blob/master/CHANGELOG.md) - [Commits](https://github.com/encode/httpx/compare/0.27.2...0.28.0) --- updated-dependencies: - dependency-name: httpx[http2] dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- requirements-dev.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements-dev.txt b/requirements-dev.txt index b2a36741..bf3063e8 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -139,7 +139,7 @@ hpack==4.0.0 ; python_full_version >= '3.6.1' httpcore==1.0.7 ; python_version >= '3.7' -httpx[http2]==0.27.2 +httpx[http2]==0.28.0 hyperframe==6.0.1 ; python_full_version >= '3.6.1' From f7de8527ad18badc91ffdb5b9888eef9fb0e3882 Mon Sep 17 00:00:00 2001 From: Andrew Omondi Date: Thu, 5 Dec 2024 11:01:42 +0300 Subject: [PATCH 2/2] chore: fix failing tests --- tests/test_graph_client_factory.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/test_graph_client_factory.py b/tests/test_graph_client_factory.py index 36138555..9055b1a1 100644 --- a/tests/test_graph_client_factory.py +++ b/tests/test_graph_client_factory.py @@ -41,11 +41,11 @@ def test_create_with_default_middleware_custom_client(): def test_create_with_default_middleware_custom_client_with_proxy(): """Test creation of GraphClient using default middleware""" proxies = { - "http://": "http://localhost:8030", - "https://": "http://localhost:8031", + "http://": httpx.HTTPTransport(proxy="http://localhost:8030"), + "https://": httpx.HTTPTransport(proxy="http://localhost:8031"), } timeout = httpx.Timeout(20, connect=10) - custom_client = httpx.AsyncClient(timeout=timeout, http2=True, proxies=proxies) + custom_client = httpx.AsyncClient(timeout=timeout, http2=True, mounts=proxies) client = GraphClientFactory.create_with_default_middleware(client=custom_client) assert isinstance(client, httpx.AsyncClient) @@ -98,11 +98,11 @@ def test_create_with_custom_middleware_custom_client(): def test_create_with_custom_middleware_custom_client_with_proxy(): """Test creation of HTTP Clients with custom middleware""" proxies = { - "http://": "http://localhost:8030", - "https://": "http://localhost:8031", + "http://": httpx.HTTPTransport(proxy="http://localhost:8030"), + "https://": httpx.HTTPTransport(proxy="http://localhost:8031"), } timeout = httpx.Timeout(20, connect=10) - custom_client = httpx.AsyncClient(timeout=timeout, http2=True, proxies=proxies) + custom_client = httpx.AsyncClient(timeout=timeout, http2=True, mounts=proxies) middleware = [ GraphTelemetryHandler(), ]