Skip to content
This repository was archived by the owner on Feb 7, 2024. It is now read-only.

Commit aadd8ec

Browse files
authored
Merge pull request #46 from TezRomacH/mypy-config
⚡ Upgraged mypy config
2 parents fad8753 + 0d9ee31 commit aadd8ec

File tree

6 files changed

+17
-3
lines changed

6 files changed

+17
-3
lines changed

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ repos:
1818
exclude: ^{{ cookiecutter.project_name }}/
1919

2020
- repo: https://github.com/asottile/pyupgrade
21-
rev: v2.4.1
21+
rev: v2.4.4
2222
hooks:
2323
- id: pyupgrade
2424
exclude: ^{{ cookiecutter.project_name }}/

setup.cfg

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,11 @@ docstring_style = google
1111
[mypy]
1212
# mypy configurations: http://bit.ly/2zEl9WI
1313
python_version = 3.7
14+
pretty = True
1415
allow_redefinition = False
1516
check_untyped_defs = True
1617
disallow_any_generics = True
18+
disallow_incomplete_defs = True
1719
ignore_missing_imports = True
1820
implicit_reexport = False
1921
strict_optional = True
@@ -26,6 +28,8 @@ warn_unused_configs = True
2628
warn_return_any = True
2729
warn_unreachable = True
2830
show_error_codes = True
31+
show_column_numbers = True
32+
show_error_context = True
2933

3034
[tool:pytest]
3135
# Directories that are not visited by pytest collector:

{{ cookiecutter.project_name }}/.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ repos:
1616
additional_dependencies: [tomlkit, toml]
1717

1818
- repo: https://github.com/asottile/pyupgrade
19-
rev: v2.4.1
19+
rev: v2.4.4
2020
hooks:
2121
- id: pyupgrade
2222
args: [--py37-plus]

{{ cookiecutter.project_name }}/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ pre-commit = "^2.4.0"
4141
[tool.poetry.dev-dependencies]
4242
darglint = "^1.3.0"
4343
isort = "^4.3.21"
44-
pyupgrade = "^2.4.1"
44+
pyupgrade = "^2.4.4"
4545
black = "^19.10b0"
4646
mypy = "^0.770"
4747
bandit = "^1.6.2"

{{ cookiecutter.project_name }}/setup.cfg

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,11 @@ docstring_style = google
1111
[mypy]
1212
# mypy configurations: http://bit.ly/2zEl9WI
1313
python_version = 3.7
14+
pretty = True
1415
allow_redefinition = False
1516
check_untyped_defs = True
1617
disallow_any_generics = True
18+
disallow_incomplete_defs = True
1719
ignore_missing_imports = True
1820
implicit_reexport = False
1921
strict_optional = True
@@ -26,6 +28,14 @@ warn_unused_configs = True
2628
warn_return_any = True
2729
warn_unreachable = True
2830
show_error_codes = True
31+
show_column_numbers = True
32+
show_error_context = True
33+
34+
# plugins = pydantic.mypy, sqlmypy
35+
36+
# [pydantic-mypy]
37+
# init_typed = True
38+
# warn_untyped_fields = True
2939

3040
[tool:pytest]
3141
# Directories that are not visited by pytest collector:

{{ cookiecutter.project_name }}/{{ cookiecutter.project_name.lower().replace(' ', '_').replace('-', '_') }}/py.typed

Whitespace-only changes.

0 commit comments

Comments
 (0)