-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.ruff.toml
More file actions
47 lines (39 loc) · 1.61 KB
/
Copy path.ruff.toml
File metadata and controls
47 lines (39 loc) · 1.61 KB
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
# The contents of this file is based on https://github.com/home-assistant/core/blob/dev/pyproject.toml
target-version = "py314"
# Vendored third-party integrations (local testing only) — never lint or format
# these. Add any new vendored component dir here.
exclude = ["custom_components/dreo"]
[lint]
select = [
"ALL",
]
ignore = [
"ANN401", # Dynamically typed expressions (typing.Any) are disallowed
"D203", # no-blank-line-before-class (incompatible with formatter)
"D212", # multi-line-summary-first-line (incompatible with formatter)
"COM812", # incompatible with formatter
"ISC001", # incompatible with formatter
]
[lint.flake8-pytest-style]
fixture-parentheses = false
[lint.pyupgrade]
keep-runtime-typing = true
[lint.mccabe]
max-complexity = 25
[lint.per-file-ignores]
"custom_components/btoddb_room_climate_controller/tests/*.py" = [
"ANN", # type annotations not required in tests
"C408", # dict() literal style
"D103", # missing docstrings in test functions
"D104", # missing docstring in public package
"FBT002", # boolean default positional arg
"INP001", # deliberately no __init__.py: keeps pytest from importing the HA-dependent integration package
"PLR0913", # too many arguments
"PLR2004", # magic values in comparisons
"PT018", # assertion should be broken into parts
"S101", # assert is the normal test pattern
"SLF001", # tests legitimately exercise private members (e.g. controller._on_change)
]
"custom_components/btoddb_room_climate_controller/engine.py" = [
"S101", # assert used for type-narrowing invariants
]