Skip to content

Commit 9cb1c35

Browse files
authored
chore(ci): move mypy config to pyproject.toml (#94)
1 parent 1fed193 commit 9cb1c35

File tree

2 files changed

+29
-27
lines changed

2 files changed

+29
-27
lines changed

.pre-commit-config.yaml

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -28,30 +28,3 @@ repos:
2828
hooks:
2929
- id: mypy
3030
additional_dependencies: [types-requests, types-setuptools]
31-
args:
32-
- --install-types
33-
- --non-interactive
34-
- --ignore-missing-imports
35-
# Disallow dynamic typing
36-
- --disallow-any-generics
37-
- --disallow-subclassing-any
38-
39-
# Disallow untyped definitions and calls
40-
- --disallow-untyped-defs
41-
- --disallow-incomplete-defs
42-
- --check-untyped-defs
43-
44-
# None and optional handling
45-
- --no-implicit-optional
46-
47-
# Configuring warnings
48-
- --warn-unused-ignores
49-
- --warn-no-return
50-
- --no-warn-return-any
51-
- --warn-redundant-casts
52-
53-
# Strict equality
54-
- --strict-equality
55-
56-
# Config file
57-
- --warn-unused-configs

pyproject.toml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,35 @@ py_version = 38
7070
[tool.black]
7171
target-version = ["py38"]
7272

73+
[tool.mypy]
74+
python_version = "3.8"
75+
install-types = true
76+
non-interactive = true
77+
ignore-missing-imports = true
78+
# Disallow dynamic typing
79+
disallow-any-generics = true
80+
disallow-subclassing-any = true
81+
82+
# Disallow untyped definitions and calls
83+
disallow-untyped-defs = true
84+
disallow-incomplete-defs = true
85+
check-untyped-defs = true
86+
87+
# None and optional handling
88+
no-implicit-optional = true
89+
90+
# Configuring warnings
91+
warn-unused-ignores = true
92+
warn-no-return = true
93+
no-warn-return-any = true
94+
warn-redundant-casts = true
95+
96+
# Strict equality
97+
strict-equality = true
98+
99+
# Config file
100+
warn-unused-configs = true
101+
73102
[tool.poetry.plugins]
74103
[tool.poetry.plugins."console_scripts"]
75104
manim-slides = "manim_slides.__main__:cli"

0 commit comments

Comments
 (0)