From 71f0c74a50e8f730f4d929d7558c0ff760ac06a4 Mon Sep 17 00:00:00 2001 From: "deepsource-autofix[bot]" <62050782+deepsource-autofix[bot]@users.noreply.github.com> Date: Tue, 7 Oct 2025 13:28:27 +0000 Subject: [PATCH] style: format code with Autopep8, Black and isort This commit fixes the style issues introduced in e4286f4 according to the output from Autopep8, Black and isort. Details: None --- aduro/datetime_encoder.py | 1 + aduro/helpers.py | 1 + aduro/model.py | 1 + aduro/version.py | 1 + tests/model_fixtures.py | 1 + tests/test_helpers.py | 1 + tests/test_json_encoder.py | 1 + tests/test_session_unit.py | 26 ++++++++++++++++---------- 8 files changed, 23 insertions(+), 10 deletions(-) diff --git a/aduro/datetime_encoder.py b/aduro/datetime_encoder.py index 04b3d3b..c2daee6 100644 --- a/aduro/datetime_encoder.py +++ b/aduro/datetime_encoder.py @@ -1,4 +1,5 @@ """Encode datetime in json""" + import json from datetime import datetime diff --git a/aduro/helpers.py b/aduro/helpers.py index 866281b..2c0cac9 100644 --- a/aduro/helpers.py +++ b/aduro/helpers.py @@ -1,4 +1,5 @@ """Helper methods for the Seluxit API.""" + from typing import Any, Union diff --git a/aduro/model.py b/aduro/model.py index 90b84cd..09a007d 100644 --- a/aduro/model.py +++ b/aduro/model.py @@ -1,4 +1,5 @@ """Data classes for Aduro""" + from __future__ import annotations from datetime import datetime diff --git a/aduro/version.py b/aduro/version.py index 7982503..927598b 100644 --- a/aduro/version.py +++ b/aduro/version.py @@ -1,2 +1,3 @@ """Version information for Aduro.""" + __version__ = "0.1.0-beta-1" diff --git a/tests/model_fixtures.py b/tests/model_fixtures.py index bd6101d..4565349 100644 --- a/tests/model_fixtures.py +++ b/tests/model_fixtures.py @@ -1,4 +1,5 @@ """Test fixtures for the models tests.""" + import json import pytest # noqa E402 # pylint: disable=import-error diff --git a/tests/test_helpers.py b/tests/test_helpers.py index ef4dbdb..711366b 100644 --- a/tests/test_helpers.py +++ b/tests/test_helpers.py @@ -1,4 +1,5 @@ """Tests for helper methodes""" + from aduro.helpers import try_convert_object diff --git a/tests/test_json_encoder.py b/tests/test_json_encoder.py index 7f03c8c..51b85f9 100644 --- a/tests/test_json_encoder.py +++ b/tests/test_json_encoder.py @@ -1,4 +1,5 @@ """Test json encoding of datetime objects.""" + import datetime import json diff --git a/tests/test_session_unit.py b/tests/test_session_unit.py index ebb6993..12bbf63 100644 --- a/tests/test_session_unit.py +++ b/tests/test_session_unit.py @@ -65,11 +65,14 @@ async def test_successful_get(self): async def test_unsuccessful_get(self): """Test get with response code 400.""" aduro_session = AduroSession("session_id") - with patch.object( - aiohttp.ClientSession, - "get", - return_value=self.unsuccessful_response(), - ), pytest.raises(AduroResponseError): + with ( + patch.object( + aiohttp.ClientSession, + "get", + return_value=self.unsuccessful_response(), + ), + pytest.raises(AduroResponseError), + ): await aduro_session._get_url("test_url") # pylint: disable=protected-access @pytest.mark.asyncio @@ -93,11 +96,14 @@ async def test_unsuccessful_patch(self): """Test post with response code 400.""" aduro_session = AduroSession("session_id") data = {"test": "test"} - with patch.object( - aiohttp.ClientSession, - "patch", - return_value=self.unsuccessful_response(), - ), pytest.raises(AduroResponseError): + with ( + patch.object( + aiohttp.ClientSession, + "patch", + return_value=self.unsuccessful_response(), + ), + pytest.raises(AduroResponseError), + ): await aduro_session._patch_url( # pylint: disable=protected-access "test_url", data=data,