move pyproject

This commit is contained in:
James Pine
2026-03-16 01:48:26 -07:00
parent b7781951df
commit 89d6e364d4
2 changed files with 8 additions and 8 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
# Python Style Guide # Python Style Guide
Target: **Python 3.12+** | Formatter/Linter: **Ruff** | Config: `pyproject.toml` (project root) Target: **Python 3.12+** | Formatter/Linter: **Ruff** | Config: `backend/pyproject.toml`
This guide codifies the conventions used across the backend, and prescribes the target style for code written during the refactor (Phases 3-6). Existing code should be migrated incrementally -- don't reformat entire files in unrelated PRs. This guide codifies the conventions used across the backend, and prescribes the target style for code written during the refactor (Phases 3-6). Existing code should be migrated incrementally -- don't reformat entire files in unrelated PRs.
+7 -7
View File
@@ -10,12 +10,12 @@ requires-python = ">=3.12"
[tool.ruff] [tool.ruff]
target-version = "py312" target-version = "py312"
line-length = 120 line-length = 120
src = ["backend"] src = ["."]
# Files/dirs to skip entirely. # Files/dirs to skip entirely.
extend-exclude = [ extend-exclude = [
"backend/voicebox-server.spec", "voicebox-server.spec",
"backend/build_binary.py", "build_binary.py",
] ]
[tool.ruff.lint] [tool.ruff.lint]
@@ -54,12 +54,12 @@ ignore = [
# Per-file rule overrides. # Per-file rule overrides.
[tool.ruff.lint.per-file-ignores] [tool.ruff.lint.per-file-ignores]
# Tests can use assert, print, and magic values freely. # Tests can use assert, print, and magic values freely.
"backend/tests/**" = ["S101", "T201", "PLR2004", "ERA001"] "tests/**" = ["S101", "T201", "PLR2004", "ERA001"]
# __init__.py re-exports are expected to have unused imports. # __init__.py re-exports are expected to have unused imports.
"**/__init__.py" = ["F401"] "**/__init__.py" = ["F401"]
# Entry points and scripts legitimately use print. # Entry points and scripts legitimately use print.
"backend/server.py" = ["T201"] "server.py" = ["T201"]
"backend/main.py" = ["T201"] "main.py" = ["T201"]
[tool.ruff.lint.isort] [tool.ruff.lint.isort]
known-first-party = ["backend"] known-first-party = ["backend"]
@@ -77,5 +77,5 @@ docstring-code-format = true
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
[tool.pytest.ini_options] [tool.pytest.ini_options]
testpaths = ["backend/tests"] testpaths = ["tests"]
asyncio_mode = "auto" asyncio_mode = "auto"