-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathpyproject.toml
More file actions
58 lines (54 loc) · 1.73 KB
/
Copy pathpyproject.toml
File metadata and controls
58 lines (54 loc) · 1.73 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
48
49
50
51
52
53
54
55
56
57
58
[tool.ruff]
target-version = "py310"
line-length = 100
extend-exclude = [
".venv",
".venv-singing",
".worktrees",
"firmware",
"node_modules",
"dotty-pi-ext/node_modules",
]
[tool.ruff.lint]
# Conservative starter set: pyflakes + pycodestyle errors. Style/format
# concerns (E501 line-length, formatting) deferred to a future PR so this
# one stays reviewable.
select = ["E", "F"]
ignore = [
"E501", # line-length — defer to formatter PR
]
[tool.coverage.run]
# Only measure first-party Python — exclude tests, scripts, firmware,
# and the dotty-pi-ext Node project.
source = [
"bridge",
"custom-providers/pi_voice",
"dotty-behaviour",
]
omit = [
"*/tests/*",
"*/__init__.py",
]
[tool.coverage.report]
# Skip lines that are deliberately uncovered (TYPE_CHECKING blocks,
# defensive `if not …: raise NotImplementedError`, etc.).
exclude_lines = [
"pragma: no cover",
"raise NotImplementedError",
"if TYPE_CHECKING:",
"if __name__ == .__main__.:",
]
skip_covered = false
show_missing = true
[tool.ruff.lint.per-file-ignores]
# Tests legitimately mutate sys.path before imports, define throwaway
# fake-clock lambdas, and pack one-line mock setups on a single line.
"tests/**" = ["E402", "E702", "E731"]
"custom-providers/pi_voice/tests/**" = ["E402", "E731"]
# bridge.py has an intentional late `from fastapi import APIRouter` after
# the admin-router setup block. Refactoring it would just create churn.
"bridge.py" = ["E402"]
# xiaozhi-patches are bind-mount overrides that have to preserve upstream
# file structure (imports after a duck-typed shim class, etc.) — adding a
# top-level import block would diverge from the source they're patching.
"custom-providers/xiaozhi-patches/**" = ["E402"]