forked from typeddjango/django-stubs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
61 lines (54 loc) · 1.47 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
[tool.black]
target-version = ['py38']
line-length = 120
include = '\.pyi?$'
[tool.codespell]
ignore-words-list = "aadd,acount,nam,asend"
[tool.ruff]
# Adds to default excludes: https://ruff.rs/docs/settings/#exclude
extend-exclude = [
".*/",
"django-source",
"stubgen",
"out",
]
line-length = 120
target-version = "py38"
[tool.ruff.lint]
# See Rules in Ruff documentation: https://beta.ruff.rs/docs/rules/
select = [
"B", # bugbear
"E", # pycodestyle
"F", # pyflakes
"INP", # flake8-tidy-imports
"W", # pycodestyle
"I", # isort
"UP", # pyupgrade
"TID251", # Disallowed imports (flake8-tidy-imports.banned-api)
"PYI", # flake8-pyi
"RUF100", # Equivalent to flake8-noqa NQA103
"PGH004", # Equivalent to flake8-noqa NQA104
"PGH003", # Disallowed blanket `type: ignore` annotations.
]
ignore = ["PYI021", "PYI024", "PYI041", "PYI043"]
[tool.ruff.lint.per-file-ignores]
"*.pyi" = [
"B",
"E501",
"E741",
"E743",
"F403", # Use wildcard import
"F405",
"F822",
"F821",
]
"tests/*.py" = ["INP001", "PGH003"]
"ext/tests/*.py" = ["INP001"]
"setup.py" = ["INP001"]
[tool.ruff.lint.flake8-tidy-imports.banned-api]
"_typeshed.Self".msg = "Use typing_extensions.Self (PEP 673) instead."
[tool.ruff.lint.isort]
known-first-party = ["django_stubs_ext", "mypy_django_plugin"]
split-on-trailing-comma = false
[build-system]
requires = ["setuptools", "wheel"]