-
Notifications
You must be signed in to change notification settings - Fork 2
/
pyproject.toml
63 lines (54 loc) · 1.48 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# Packaging
[build-system]
requires = ["setuptools >= 59"]
build-backend = "setuptools.build_meta"
# Note: `setuptools >= 61` supports having project metadata in `pyproject.toml` as well,
# but it dropped support for Python 3.6. To have our project buildable on Python 3.6, I
# had to keep metadata in `setup.cfg`.
# Tools - Pylint
[tool.pylint.main]
load-plugins = [
"pylint.extensions.bad_builtin",
"pylint.extensions.docstyle",
"pylint.extensions.set_membership",
]
disable = [
"missing-module-docstring",
"bad-mcs-classmethod-argument", # I prefer `mcs` over `cls`
"too-few-public-methods",
"too-many-branches",
"too-many-locals",
"too-many-statements",
"docstring-first-line-empty",
]
enable = [
"useless-suppression",
]
[tool.pylint.basic]
include-naming-hint = true
typevar-rgx = "^([A-Z]|T([A-Z][a-z]*)*)$"
# snake_case, but with no lower bound on name length
argument-rgx = "([^\\W\\dA-Z][^\\WA-Z]*|_[^\\WA-Z]*|__[^\\WA-Z\\d_][^\\WA-Z]+__)$"
variable-rgx = "([^\\W\\dA-Z][^\\WA-Z]*|_[^\\WA-Z]*|__[^\\WA-Z\\d_][^\\WA-Z]+__)$"
# Tools - Linting
[tool.isort]
profile = "black"
# Tools - Mypy
[tool.mypy]
warn_unused_configs = true
warn_redundant_casts = true
no_implicit_optional = true
follow_imports = "silent"
ignore_missing_imports = true
mypy_path = "./"
allow_redefinition = true
show_error_codes = true
exclude = [
"build/"
]
[[tool.mypy.overrides]]
module = [
"argtyped.*",
]
disallow_untyped_defs = true
disallow_incomplete_defs = true