-
Notifications
You must be signed in to change notification settings - Fork 26
/
.ruff.toml
53 lines (47 loc) · 1.95 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
extend = "pyproject.toml"
lint.ignore = [
# NOTE: To find a rule code to fix, run:
# ruff --select="ALL" --statistics src/geovista/<subpackage>
# flake8-boolean-trap (FBT)
# https://docs.astral.sh/ruff/rules/#flake8-boolean-trap-fbt
# NOTE: A good thing to fix, but changes API.
"FBT001", # boolean-positional-arg-in-function-definition.
"FBT002", # boolean-default-value-in-function-definition.
"FBT003", # boolean-positional-value-in-function-call.
# Pylint (PL)
# https://docs.astral.sh/ruff/rules/#pylint-pl
"PLR0912", # Too many branches.
"PLR0913", # Too many arguments in function definition.
"PLR0915", # Too many statements.
"PLR2004", # Magic value used in comparison, consider replacing with a constant.
"PLW0603", # Using the global statement to update is discouraged.
# flake8-self (SLF)
# https://docs.astral.sh/ruff/rules/#flake8-self-slf
"SLF001", # Private member accessed.
# flake8-todos (TD)
# https://docs.astral.sh/ruff/rules/#flake8-todos-td
"TD003", # Missing issue link on the line following this TODO.
]
[lint.extend-per-file-ignores]
"conftest.py" = [
# flake8-annotations (ANN)
# https://docs.astral.sh/ruff/rules/#flake8-annotations-ann
"ANN001", # Missing type annotation for function argument.
"ANN201", # Missing return type annotation for public function.
]
"src/geovista/geoplotter.py" = [
# flake8-annotations (ANN)
# https://docs.astral.sh/ruff/rules/#flake8-annotations-ann
"ANN401", # Dynamically typed expressions (typing.Any).
]
"test_*.py" = [
# flake8-annotations (ANN)
# https://docs.astral.sh/ruff/rules/#flake8-annotations-ann
"ANN001", # Missing type annotation for function argument.
"ANN201", # Missing return type annotation for public funciton.
]
"test_slice_lines.py" = [
# eradicate (ERA)
# https://docs.astral.sh/ruff/rules/#eradicate-era
"ERA001", # Found commented-out code.
]