Skip to content

Commit

Permalink
Moves mypy config to pyproject.toml
Browse files Browse the repository at this point in the history
  • Loading branch information
Daverball committed Dec 13, 2024
1 parent c662abd commit ce6467c
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 14 deletions.
2 changes: 0 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ repos:
rev: v1.13.0
hooks:
- id: mypy
args:
- --config-file=setup.cfg
additional_dependencies:
- pytest
- flake8
13 changes: 13 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -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
12 changes: 0 additions & 12 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -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

0 comments on commit ce6467c

Please sign in to comment.