-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
43 lines (38 loc) · 1.53 KB
/
Copy pathpyproject.toml
File metadata and controls
43 lines (38 loc) · 1.53 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
# Tooling config only (the app is run via Docker, not installed as a package).
[tool.pytest.ini_options]
asyncio_mode = "auto"
testpaths = ["tests"]
addopts = "-q"
# Put the repo root on sys.path so `import app` works when pytest is invoked as
# the bare console script (CI), not just via `python -m pytest`.
pythonpath = ["."]
markers = [
"integration: tests that need a real Mongo/Redis (spun up via testcontainers)",
]
[tool.ruff]
line-length = 100
target-version = "py313"
[tool.ruff.lint]
select = ["E", "F", "I", "B", "UP", "C4"]
ignore = [
"E501", # line length - long strings/urls are fine
"E701", # compact one-line if/clamp guards are an intentional style
"E702", # compact "read field; advance offset" idiom in the binary decoders
"B008", # Depends() in defaults is the standard FastAPI pattern
"UP017", # datetime.timezone.utc is fine; not churning to datetime.UTC
"UP042", # str+Enum is fine; not switching to StrEnum
"UP046", # keep Generic[T] base - runs across 3.11–3.13 (PEP 695 is 3.12+ only)
"B904", # API error translation is intentional (can tighten with `from None` later)
]
[tool.ruff.lint.per-file-ignores]
"tests/**" = ["B011"]
# Per-iteration union-find: find/union are rebuilt and consumed each loop pass,
# never stored as callbacks, so the loop-variable "capture" B023 warns about is safe.
"app/trove/leaderboards/detection.py" = ["B023"]
[tool.pyright]
include = ["app"]
venvPath = "."
venv = ".venv"
pythonVersion = "3.13"
typeCheckingMode = "basic"
reportMissingImports = true