-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathruff.toml
More file actions
88 lines (79 loc) · 2.34 KB
/
ruff.toml
File metadata and controls
88 lines (79 loc) · 2.34 KB
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
output-format = "concise"
line-length = 88
[format]
docstring-code-format = true
skip-magic-trailing-comma = true
[lint]
preview = true
select = [
"A", # flake8-builtins
"ANN", # flake8-annotations
"ARG", # flake8-unused-arguments
"B", # flake8-bugbear
"BLE", # flake8-blind-except
"C4", # flake8-comprehensions
"D", # pydocstyle
"E", # pycodestyle error
"F", # Pyflakes
"FA", # flake8-future-annotations
"I", # isort
"ICN", # flake8-import-conventions
"ISC", # flake8-implicit-str-concat
"N", # pep8-naming
"NPY", # NumPy-specific rules
"PD", # pandas-vet
"PIE", # flake8-pie
"PL", # pylint
"PT", # flakeru8-pytest
"RET", # flake8-return
"RUF", # Ruff-specific rules
"SIM", # flake8-simplify
"TC", # flake8-type-checking
"W", # pycodestyle warning
]
ignore = [
"ANN002", # missing type for *args
"ANN003", # missing type for **kwargs
"D401", # first line in docstring as imperative mood
"PLR6301", # no-self-use
"PLR0913", # too-many-arguments
"PLR0904", # too-many-public-methods
"PLR0916", # too-many-boolean-expressions
"PLR0912", # too-many-branches
"PLR0904", # too-many-public-methods
"PLR0911", # too-many-return-statements
"PLR0914", # too-many-local-variables
"PLR0915", # too-many-statements
"PLR0917", # too-many-positional-arguments
"PLC1901", # compare-to-empty-string
"PLR2004", # magic-value-comparison
"RUF067", # non empty init module
]
[lint.per-file-ignores]
"tests/*" = [
"A004", # Shadowing builtins name
]
"src/**/builtins/*" = [
"A001", # Builtin variable shadowing
"A004", # Shadowing a Python builtin through import
"N801", # Invalid class name (not CamelCase)
]
"src/**/__init__.py" = [
"F401", # Imported but unused (false positive)
"F403", # Unable to detect undefined names wiht `from ... import *`
"F405", # Unable to detect (un)defined names due to `from ... import *`
]
[lint.flake8-annotations]
allow-star-arg-any = true
mypy-init-return = true
suppress-none-returning = true
[lint.flake8-unused-arguments]
ignore-variadic-names = true
[lint.isort]
split-on-trailing-comma=false
[lint.pycodestyle]
ignore-overlong-task-comments = true
[lint.pydocstyle]
convention = "numpy"
[lint.pylint]
max-args = 10