diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index e0284c1..033f259 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -18,12 +18,7 @@ repos: hooks: - id: ruff args: [--fix, --show-fixes] - - - repo: https://github.com/psf/black - rev: 24.3.0 - hooks: - - id: black - exclude: "^tests/mypy/negative.py" + - id: ruff-format - repo: https://github.com/pre-commit/mirrors-mypy rev: v1.9.0 diff --git a/src/typeguard/_checkers.py b/src/typeguard/_checkers.py index 5ae7b03..67dd5ad 100644 --- a/src/typeguard/_checkers.py +++ b/src/typeguard/_checkers.py @@ -934,7 +934,8 @@ def builtin_checker_lookup( elif is_typeddict(origin_type): return check_typed_dict elif isclass(origin_type) and issubclass( - origin_type, Tuple # type: ignore[arg-type] + origin_type, + Tuple, # type: ignore[arg-type] ): # NamedTuple return check_tuple diff --git a/src/typeguard/_pytest_plugin.py b/src/typeguard/_pytest_plugin.py index 7bca9c2..7654d92 100644 --- a/src/typeguard/_pytest_plugin.py +++ b/src/typeguard/_pytest_plugin.py @@ -16,7 +16,7 @@ def pytest_addoption(parser: Parser) -> None: def add_ini_option( opt_type: ( Literal["string", "paths", "pathlist", "args", "linelist", "bool"] | None - ) + ), ) -> None: parser.addini( group.options[-1].names()[0][2:], diff --git a/src/typeguard/_suppression.py b/src/typeguard/_suppression.py index f6899a9..bbbfbfb 100644 --- a/src/typeguard/_suppression.py +++ b/src/typeguard/_suppression.py @@ -28,7 +28,7 @@ def suppress_type_checks() -> ContextManager[None]: ... def suppress_type_checks( - func: Callable[P, T] | None = None + func: Callable[P, T] | None = None, ) -> Callable[P, T] | ContextManager[None]: """ Temporarily suppress all type checking.