ref: Select ALL ruff rules with exclusions (#4040)
Select ALL ruff rules with exclusions
This commit is contained in:
parent
e84148ed6d
commit
06c8e3d6c8
1 changed files with 25 additions and 43 deletions
|
|
@ -39,53 +39,35 @@ flake8-type-checking.runtime-evaluated-base-classes = [
|
||||||
"typing.TypedDict", # Needed by fastapi
|
"typing.TypedDict", # Needed by fastapi
|
||||||
"typing_extensions.TypedDict", # Needed by fastapi
|
"typing_extensions.TypedDict", # Needed by fastapi
|
||||||
]
|
]
|
||||||
select = [
|
select = ["ALL"]
|
||||||
"A",
|
|
||||||
"ASYNC",
|
|
||||||
"B",
|
|
||||||
"C4",
|
|
||||||
"COM",
|
|
||||||
"DJ",
|
|
||||||
"DTZ",
|
|
||||||
"E",
|
|
||||||
"EM",
|
|
||||||
"F",
|
|
||||||
"FA",
|
|
||||||
"FLY",
|
|
||||||
"FURB",
|
|
||||||
"G",
|
|
||||||
"I",
|
|
||||||
"ICN",
|
|
||||||
"INT",
|
|
||||||
"INP",
|
|
||||||
"ISC",
|
|
||||||
"LOG",
|
|
||||||
"NPY",
|
|
||||||
"PD",
|
|
||||||
"PERF",
|
|
||||||
"PIE",
|
|
||||||
"PT",
|
|
||||||
"PTH",
|
|
||||||
"PYI",
|
|
||||||
"Q",
|
|
||||||
"RET",
|
|
||||||
"RSE",
|
|
||||||
"RUF",
|
|
||||||
"SIM",
|
|
||||||
"SLOT",
|
|
||||||
"T10",
|
|
||||||
"TCH",
|
|
||||||
"TID",
|
|
||||||
"UP",
|
|
||||||
"W",
|
|
||||||
"YTT"
|
|
||||||
]
|
|
||||||
ignore = [
|
ignore = [
|
||||||
|
"C90", # McCabe complexity
|
||||||
|
"CPY", # Missing copyright
|
||||||
"COM812", # Messes with the formatter
|
"COM812", # Messes with the formatter
|
||||||
|
"ERA", # Eradicate commented-out code
|
||||||
|
"FIX002", # Line contains TODO
|
||||||
"ISC001", # Messes with the formatter
|
"ISC001", # Messes with the formatter
|
||||||
"PERF203", # Rarely useful
|
"PERF203", # Rarely useful
|
||||||
"RUF006", # TODO (Store a reference to the return value of `asyncio.create_task`)
|
"RUF012", # Pydantic models are currently not well detected. See https://github.com/astral-sh/ruff/issues/13630
|
||||||
"RUF012", # TODO (Mutable class attributes should be annotated with `typing.ClassVar`)
|
"TD002", # Missing author in TODO
|
||||||
|
"TD003", # Missing issue link in TODO
|
||||||
|
|
||||||
|
# Rules that are TODOs
|
||||||
|
"ANN",
|
||||||
|
"ARG",
|
||||||
|
"BLE",
|
||||||
|
"D",
|
||||||
|
"DOC",
|
||||||
|
"EXE",
|
||||||
|
"FBT",
|
||||||
|
"N",
|
||||||
|
"PL",
|
||||||
|
"RUF006", # Store a reference to the return value of `asyncio.create_task`
|
||||||
|
"S",
|
||||||
|
"SLF",
|
||||||
|
"T201",
|
||||||
|
"TRY",
|
||||||
|
"PGH",
|
||||||
]
|
]
|
||||||
|
|
||||||
[tool.ruff.lint.per-file-ignores]
|
[tool.ruff.lint.per-file-ignores]
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue