-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathruff.toml
More file actions
61 lines (55 loc) · 1.36 KB
/
ruff.toml
File metadata and controls
61 lines (55 loc) · 1.36 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
extend-exclude = [
"**/tests/",
".github/scripts/",
"**/demos/",
]
line-length = 120
target-version = "py310"
exclude = [
".git",
"*.ipynb",
".ruff_cache",
".venv",
"venv",
".vscode",
"dist",
".pytest_cache",
"__init__.py",
"**/__version__.py",
"__version__.py",
]
[lint]
ignore = [
'D100', # Missing docstring in public class
'D101', # Missing docstring in public class
'D102', # Missing docstring in public method
'D104', # Missing docstring in public package
'D105', # Missing docstring in magic method
'D107', # Missing docstring in `__init__`
'D203', # 1 blank line required before class docstring (conflicts with formatter)
'D211', # blank-line-before-class
'D213', # multi-line-summary-second-line (conflicts with D212)
]
select = [
'B', # flake8-bugbear
'D', # pydocstyle
'E', # pycodestyle
'F', # pyflakes
'I', # isort
'N', # pep8-naming
'RUF100', # check for valid noqa directives
'UP', # pyupgrade
'W', # pycodestyle
'TID252', # relative-imports
]
[lint.per-file-ignores]
"__init__.py" = ["D404", "F401"] # Allow unused imports in __init__.py
"**/tests/**" = ["D100", "D101", "D102", "D103"] # Relaxed docstring rules for tests
fixable = ["ALL"]
[format]
quote-style = "double"
[lint.isort]
known-first-party = ['workspace_extractor']
lines-after-imports = 2
lines-between-types = 1
order-by-type = true