-
Notifications
You must be signed in to change notification settings - Fork 2
/
.ruff.toml
62 lines (54 loc) · 1.23 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
# Exclude a variety of commonly ignored directories.
extend-exclude = [
"__init__.py",
]
# Same as Black.
line-length = 120
indent-width = 4
# Assume Python 3.9
target-version = "py39"
[lint]
# TODO: should be the following list, but Ruff does not yet impl all of them.
# W503,W504
# E203
# C408
ignore = [
"C408",
#"E203",
"E402",
#"W503",
#"W504",
"D203",
"D211",
"D213",
"UP006",
"UP007", # see ruff GH#4427
]
select = [
"B", # flake8-bugbear
"C", # flake8-comprehensions
#"D", # note: all relevant D's will be set by setting pydocstyle.convention=numpy!
"E", # pycodestyles
"F", # pyflakes
"W", # pycodestyle warnings
"UP", # pyupgrade
"T2", # flake8-print
"I001", # isort
"ICN", # import conventions, e.g. import numpy as np
#"B950", # not yet implemented by Ruff.
"RUF100", # ensure 'noqa' declarations are still valid.
]
[lint.pydocstyle]
convention = "numpy"
[lint.mccabe]
max-complexity = 15 # max branches inside a function.
[lint.isort]
known-first-party = [
"weldx",
"weldx_widgets",
]
required-imports = [
"from __future__ import annotations",
]
[lint.flake8-import-conventions]
extend-aliases = { xarray = "xr" }