-
Notifications
You must be signed in to change notification settings - Fork 0
/
ruff.toml
69 lines (68 loc) · 2.52 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
line-length = 120
select = [
"F", # pyflakes
"E", # pycodestyle errors
"W", # pycodestyle warnings
"C90", # mccabe
"I", # isort
"N", # pep8-naming
"UP", # pyupgrade
"YTT", # flake8-2020
"S", # flake8-bandit
"BLE", # flake8-blind-except
"FBT003", # flake8-boolean-trap
"B", # flake8-bugbear
"A", # flake8-builtins
"COM", # flake8-commas
"C4", # flake8-comprehensions
"T10", # flake8-debugger
"ISC", # flake8-implicit-str-concat
"G010", # Logging statement uses warn instead of warning
"G201", # Logging .exception(...) should be used instead of .error(..., exc_info=True)
"G202", # Logging statement has redundant exc_info
"INP", # flake8-no-pep420
"PIE", # flake8-pie
"T20", # flake8-print
"PYI", # flake8-pyi
"PT", # flake8-pytest-style
"Q", # flake8-quotes
"RSE", # flake8-raise
"RET", # flake8-return
"SIM", # flake8-simplify
"TCH", # flake8-type-checking
"ARG", # flake8-unused-arguments
"PTH", # flake8-use-pathlib
"ERA", # flake8-eradicate
"PGH", # pygrep-hooks
"PLC0414", # Import alias does not rename original package
"PLE", # Error
"PLW", # Warning
"TRY", # tryceratops
"FLY", # flynt
"RUF", # ruff-specific rules
"ANN001", # missing type annotation for arguments
"ANN002", # missing type annotation for *args
"ANN003", # missing type annotation for **kwargs
]
unfixable = [
"ERA001", # eradicate: found commented out code (can be dangerous if fixed automatically)
]
ignore = [
"A002", # builtin shadowing in arguments
"A003", # builtin shadowing in attributes
"D203", # 1 blank line required before class docstring
"ARG002", # Unused method argument
"TRY003", # Avoid specifying long messages outside the exception class
"TRY300", # Consider moving statement into the else clause
"ARG001", # Unused first argument
"PT019", # Fixture without value is injected as parameter, use @pytest.mark.usefixtures instead
"SIM108", # Use ternary operator instead of if-else block (ternaries lie to coverage)
"F403",
]
[per-file-ignores]
"app/tests/*" = [
"S", # ignore bandit security issues in tests
"B018", # ignore useless expressions in tests
"PT012", # ignore complex with pytest.raises clauses
"S101",
]