diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a6c700a..4fe1b9e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -46,8 +46,6 @@ repos: rev: v1.13.0 hooks: - id: mypy - args: - - --config-file=setup.cfg additional_dependencies: - pytest - flake8 diff --git a/pyproject.toml b/pyproject.toml index 917b4c5..6e7a0cf 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -70,3 +70,16 @@ exclude_lines = [ 'if TYPE_CHECKING:', 'pragma: no cover' ] + +[tool.mypy] +python_version = 3.9 +strict = true +warn_redundant_casts = true +warn_unused_configs = true +warn_return_any = true +show_error_codes = true +ignore_missing_imports = true + +[[tool.mypy.overrides]] +module = ["tests.*"] +disallow_untyped_defs = false diff --git a/setup.cfg b/setup.cfg index 8702940..dfef943 100644 --- a/setup.cfg +++ b/setup.cfg @@ -31,15 +31,3 @@ per-file-ignores = flake8_type_checking/checker.py:SIM114 flake8_type_checking/types.py:D tests/**.py:D103,D205,D400,D102,D101 - -[mypy] -python_version = 3.9 -strict = True -warn_redundant_casts = True -warn_unused_configs = True -warn_return_any = True -show_error_codes = True -ignore_missing_imports = True - -[mypy-tests.*] -disallow_untyped_defs = False