Cleanup: break up the massive app.py into separate modules of manageable size.

This commit is contained in:
2026-09-03 13:36:29 +00:00
parent 2f533eaf09
commit 4413c7efdf
24 changed files with 2496 additions and 1947 deletions
+2 -2
View File
@@ -53,7 +53,7 @@ class Node(msgspec.Struct, omit_defaults=True):
class Data(msgspec.Struct):
...
#: API keys gating the translator service WebSocket (/_translate/{key}):
#: key -> display name; the first is generated at bootstrap (app.py).
#: key -> display name; the first is generated at bootstrap (state.py).
translate_keys: dict[str, str] = {}
#: Wanted target languages for the translator service (presence-keys);
#: jobs are offered only in these ∩ a connection's capabilities.
@@ -147,7 +147,7 @@ translation data, in the same transaction:
Chunking must be deterministic and shared with render/save, so
`chunk_markdown` + `chunk_key` live in `pagerite/i18n.py` (or a small
`pagerite/chunks.py`) and are imported by both `migrations.py` and
`views.py`/`app.py`.
`views.py`/`state.py`.
## Implementation notes (deviations from the plan above)