forked from acoular/acoular
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.ruff.toml
81 lines (71 loc) · 3.08 KB
/
.ruff.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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
# Exclude a variety of commonly ignored directories.
src = ["acoular"]
exclude = ["tests/unsupported", "docs/source", ".git"]
line-length = 120
[lint]
select = [
"F", # pyflakes
"C","E","R", "W", # pylint (including pycodestyle)
"C90", "I", "N","D", "UP",
"YTT", "ASYNC", "ASYNC1", "BLE", "B", "A", "COM", # flake8 plugins
"C4", "DTZ","T10","EM", "FA", "ISC", "ICN", # flake8 plugins
"LOG", "G", "INP", "PIE", "T20", "PYI", "PT", "RSE", # flake8 plugins
"RET", "SLF", "SLOT", "SIM", "TID", "TCH", "INT", "ARG", "TD", # flake8 plugins
"C901" # others
]
ignore = [
"C901", # do we want to measure code complexity -> TBD
"COM812", # conflict with ruff formatter
"ISC001", # conflict with ruff formatter
# D
"D401", # first line should be in imperative mood -> TBD
"D205", # 1 blank line required between summary line and description -> should be fixed by issue #216
"D100", # missing docstring in public module -> should be fixed by issue #216
"D101", # missing docstring in public class -> should be fixed by issue #216
"D102", # missing docstring in public method -> should be fixed by issue #216
"D103", # missing docstring in public function -> should be fixed by issue #216
"D104", # missing docstring in public package -> should be fixed by issue #216
"D105", # missing docstring in magic method -> should be fixed by issue #216
"D107", # missing docstring in __init__ -> should be fixed by issue #216
"D417", # missing argument descriptions in the docstring -> should be fixed by issue #216
# Others
"T20", # will be fixed when logging is implemented
"SLF001", # should be fixed with issue: #225
]
# Allow fix for all enabled rules (when `--fix`) is provided.
fixable = ["ALL"]
unfixable = []
[lint.pycodestyle]
ignore-overlong-task-comments = true
max-doc-length = 100
[lint.pydocstyle]
convention = "numpy" # Accepts: "google", "numpy", or "pep257".
[format]
quote-style = "single"
indent-style = "space"
skip-magic-trailing-comma = false
# Enable auto-formatting of code examples in docstrings. Markdown,
# reStructuredText code/literal blocks and doctests are all supported.
#
# This is currently disabled by default, but it is planned for this
# to be opt-out in the future.
docstring-code-format = true
# Set the line length limit used when formatting code snippets in
# docstrings.
#
# This only has an effect when the `docstring-code-format` setting is
# enabled.
docstring-code-line-length = "dynamic"
[lint.per-file-ignores]
"acoular/__init__.py" = ["F401"]
"acoular/demo/__init__.py" = ["F401"]
"acoular/tools/__init__.py" = ["F401"]
"acoular/aiaa/__init__.py" = ["F401"]
"acoular/fastFuncs.py" = ["N802", "N803","N806","N999"] # allow different naming convention
"acoular/environments.py" = ["N806"]
"acoular/sources.py" = ["N806"]
"acoular/tbeamform.py" = ["F841","N806"]
"acoular/tprocess.py" = ["N806"] #
"acoular/fbeamform.py" = ["N806","B023"]
"tests/cases/*" = ["N802"]
"examples/*" = ["A001", "B007", "D4", "E4", "E701", "F4", "UP036", "SIM108","SLF001", "INP001"]