diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 857ce3a..fb8d96b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -11,7 +11,7 @@ repos: hooks: - id: isort - repo: https://github.com/psf/black - rev: 23.7.0 + rev: 24.3.0 hooks: - id: black language_version: python3 diff --git a/flagsmith/flagsmith.py b/flagsmith/flagsmith.py index bbfd227..83c2ae4 100644 --- a/flagsmith/flagsmith.py +++ b/flagsmith/flagsmith.py @@ -324,9 +324,9 @@ def _get_identity_flags_from_document( def _get_environment_flags_from_api(self) -> Flags: try: - json_response: typing.List[ - typing.Mapping[str, JsonType] - ] = self._get_json_response(url=self.environment_flags_url, method="GET") + json_response: typing.List[typing.Mapping[str, JsonType]] = ( + self._get_json_response(url=self.environment_flags_url, method="GET") + ) return Flags.from_api_flags( api_flags=json_response, analytics_processor=self._analytics_processor, @@ -344,10 +344,10 @@ def _get_identity_flags_from_api( ) -> Flags: try: data = generate_identities_data(identifier, traits) - json_response: typing.Dict[ - str, typing.List[typing.Dict[str, JsonType]] - ] = self._get_json_response( - url=self.identities_url, method="POST", body=data + json_response: typing.Dict[str, typing.List[typing.Dict[str, JsonType]]] = ( + self._get_json_response( + url=self.identities_url, method="POST", body=data + ) ) return Flags.from_api_flags( api_flags=json_response["flags"],