-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
61 lines (53 loc) · 1.89 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.ruff]
target-version = "py312"
line-length = 79
extend-exclude = [
"src/scrap/database/migrations/versions",
]
[tool.ruff.lint]
select = ["ALL"]
ignore = [
"COM812", # Conflicts with the formatter
"ISC001", # Conflicts with the formatter
"ANN101", # "missing-type-self"
"PT001", # https://github.com/astral-sh/ruff/issues/8796#issuecomment-1825907715
"PT004", # https://github.com/astral-sh/ruff/issues/8796#issuecomment-1825907715
"PT005", # https://github.com/astral-sh/ruff/issues/8796#issuecomment-1825907715
"PT023", # https://github.com/astral-sh/ruff/issues/8796#issuecomment-1825907715
# Thoughtful ignores
"N818", # Exception name should be named with an Error suffix
"D", # Missing docstring
"TRY401", # Redundant exception object included in `logging.exception` call
"EM101", # Checks for the use of string literals in exception constructors
"ANN401", # Dissallows `Any` in typing
"BLE001", # Dissallows `except Exception`
"PLR0913", # Too many arguments in function definition
"PERF401", # Use a list comprehension to create a transformed list
"S324", # Dissallows hashlib.md5 usage
"ARG002", # Unused method argument
"TRY003", # Avoid specifying long messages outside the exception class
"ARG005", # Unused lambda argument
]
[tool.ruff.lint.per-file-ignores]
"**/__init__.py" = [
"F401", # Imported but unused
"F403", # Wildcard imports
]
"**/env.py" = [
"ERA001", # Found commented-out code
]
[tool.ruff.lint.isort]
lines-after-imports = 2
[tool.ruff.lint.mccabe]
max-complexity = 10
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.ruff.format]
docstring-code-line-length = 72
[tool.mypy]
disallow_untyped_defs = true # Functions need to be annotated
warn_unused_ignores = true
exclude = [
"env",
"src/scrap/database/migrations/versions",
]