From 3b229abd8a13b77507f8cd2d0e3c6c4ce1d07720 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 5 Feb 2024 20:28:45 +0000 Subject: [PATCH 1/2] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/psf/black: 23.11.0 → 24.1.1](https://github.com/psf/black/compare/23.11.0...24.1.1) - [github.com/PyCQA/flake8: 6.1.0 → 7.0.0](https://github.com/PyCQA/flake8/compare/6.1.0...7.0.0) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ba7b2cc..829497e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -14,11 +14,11 @@ repos: args: ["--application-directories", "src:tests"] additional_dependencies: ["setuptools>60.9"] - repo: https://github.com/psf/black - rev: 23.11.0 + rev: 24.1.1 hooks: - id: black - repo: https://github.com/PyCQA/flake8 - rev: 6.1.0 + rev: 7.0.0 hooks: - id: flake8 additional_dependencies: [flake8-bugbear] From 48000ecd3fb21d6dc00394a9201f1ad83e2b8c54 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 5 Feb 2024 20:28:54 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/itsdangerous/timed.py | 6 ++---- tests/test_itsdangerous/test_serializer.py | 6 ++---- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/src/itsdangerous/timed.py b/src/itsdangerous/timed.py index cad8da3..e4d88cd 100644 --- a/src/itsdangerous/timed.py +++ b/src/itsdangerous/timed.py @@ -63,8 +63,7 @@ def unsign( # type: ignore signed_value: _t_str_bytes, max_age: _t_opt_int = None, return_timestamp: "_te.Literal[False]" = False, - ) -> bytes: - ... + ) -> bytes: ... @typing.overload def unsign( @@ -72,8 +71,7 @@ def unsign( signed_value: _t_str_bytes, max_age: _t_opt_int = None, return_timestamp: "_te.Literal[True]" = True, - ) -> _t.Tuple[bytes, datetime]: - ... + ) -> _t.Tuple[bytes, datetime]: ... def unsign( self, diff --git a/tests/test_itsdangerous/test_serializer.py b/tests/test_itsdangerous/test_serializer.py index cdc4191..2837121 100644 --- a/tests/test_itsdangerous/test_serializer.py +++ b/tests/test_itsdangerous/test_serializer.py @@ -18,13 +18,11 @@ @overload -def coerce_str(ref: str, s: str) -> str: - ... +def coerce_str(ref: str, s: str) -> str: ... @overload -def coerce_str(ref: bytes, s: str) -> bytes: - ... +def coerce_str(ref: bytes, s: str) -> bytes: ... def coerce_str(ref: Union[str, bytes], s: str) -> Union[str, bytes]: