From c2a81bebcd0297b9e2b211988f92b8345def0ebb Mon Sep 17 00:00:00 2001 From: David Montague <35119617+dmontagu@users.noreply.github.com> Date: Fri, 30 Aug 2024 09:48:42 -0700 Subject: [PATCH] Remove urllib3 thing from dev deps --- .hyperlint/style_guide_test.md | 11 ----------- logfire/experimental/query_client.py | 10 +++++----- pyproject.toml | 1 - 3 files changed, 5 insertions(+), 17 deletions(-) delete mode 100644 .hyperlint/style_guide_test.md diff --git a/.hyperlint/style_guide_test.md b/.hyperlint/style_guide_test.md deleted file mode 100644 index 4254ca122..000000000 --- a/.hyperlint/style_guide_test.md +++ /dev/null @@ -1,11 +0,0 @@ - - -# This ia a test file - -it will flag errors like on pydantic. - -It won't flag on validators. - -but it won't flag errors on SDK or SDKs or APIs anymore. - -This is is an issue. diff --git a/logfire/experimental/query_client.py b/logfire/experimental/query_client.py index bb84dc0b1..da2e2269e 100644 --- a/logfire/experimental/query_client.py +++ b/logfire/experimental/query_client.py @@ -7,7 +7,7 @@ try: from httpx import AsyncClient, Client, Response, Timeout from httpx._client import BaseClient -except ImportError as e: +except ImportError as e: # pragma: no cover raise ImportError('httpx is required to use the Logfire query clients') from e if TYPE_CHECKING: @@ -89,9 +89,9 @@ def build_query_params( return params def handle_response_errors(self, response: Response) -> None: - if response.status_code == 400: + if response.status_code == 400: # pragma: no cover raise QueryExecutionError(response.json()) - if response.status_code == 422: + if response.status_code == 422: # pragma: no cover raise QueryRequestError(response.json()) assert response.status_code == 200, response.content @@ -171,7 +171,7 @@ def query_arrow( # type: ignore """ try: import pyarrow - except ImportError as e: + except ImportError as e: # pragma: no cover raise ImportError('pyarrow is required to use the query_arrow method') from e response = self._query( @@ -295,7 +295,7 @@ async def query_arrow( # type: ignore """ try: import pyarrow - except ImportError as e: + except ImportError as e: # pragma: no cover raise ImportError('pyarrow is required to use the query_arrow method') from e response = await self._query( diff --git a/pyproject.toml b/pyproject.toml index 58c8e51bc..055a68ca2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -142,7 +142,6 @@ dev-dependencies = [ "griffe==0.48.0", "pyarrow>=17.0.0", "pytest-recording>=0.13.2", - 'urllib3<2; python_version < "3.10"' ] [tool.rye.scripts]