From 3beee4cee36cab5ecf2610fdbe43b4dbe038d0a1 Mon Sep 17 00:00:00 2001 From: Paris Kasidiaris Date: Tue, 4 Jun 2024 12:05:59 +0300 Subject: [PATCH 1/2] CI: Move workflows to the correct path --- .github/{ => workflows}/ci.yml | 0 .github/{ => workflows}/publish.yml | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename .github/{ => workflows}/ci.yml (100%) rename .github/{ => workflows}/publish.yml (100%) diff --git a/.github/ci.yml b/.github/workflows/ci.yml similarity index 100% rename from .github/ci.yml rename to .github/workflows/ci.yml diff --git a/.github/publish.yml b/.github/workflows/publish.yml similarity index 100% rename from .github/publish.yml rename to .github/workflows/publish.yml From 2e0b3f9e064a2dab45f40a2c3011c504b55105ae Mon Sep 17 00:00:00 2001 From: Oluwafemi Adenuga Date: Tue, 4 Jun 2024 10:29:13 +0100 Subject: [PATCH 2/2] Fix mypy definations --- elorus/client.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/elorus/client.py b/elorus/client.py index ec5ff8d..3289647 100644 --- a/elorus/client.py +++ b/elorus/client.py @@ -49,7 +49,7 @@ def handle_file_download(self, response): filename = filename_kv[1] return filename, response.content - def _handle_response(self, response): + def _handle_response(self, response: httpx.Response): if response.headers.get("Content-Type", "").lower() == "application/pdf": return self.handle_file_download(response) @@ -108,7 +108,7 @@ def _handle_response(self, response): def _handle_request( self, method: str, path: str, payload: Optional[dict] = None, **kwargs - ): + ) -> httpx.Response: auth = self._get_auth() url = f"{self.base_url}/{self.api_version}/{path}" with httpx.Client(auth=auth) as client: @@ -116,8 +116,8 @@ def _handle_request( return self._handle_response(response) -class SubClient: - client = Client +class SubClient(Client): + client: Client def __init__(self, client: Client): self.client = client