Repository navigation
refactor: enforce SQLite persistence boundaries - #294
Conversation
Move trigger-actor backfill storage and database initialization behind the persistence and migration layers, then pin the boundary with an architecture test and operational documentation.\n\nCo-authored-by: ecarreras <ecarreras@users.noreply.github.com>
pilipilisbot
left a comment
There was a problem hiding this comment.
Reviewed the persistence-boundary refactor and this looks ready to merge.
What I checked:
- The PR head matches
88dcc9eand the diff is scoped to actor backfill extraction, migration initialization ownership, boundary tests, and persistence docs. backfill_trigger_actors()now reads/writes throughActorBackfillRepository; write mode validates the migrated schema first and no longer performs feature-local DDL. Dry-run still reads legacy databases without mutating them.initialize_database()moved into the migrations package without changing the explicit migration path semantics.- The AST architecture test allows SQL only in persistence, migrations, and the dashboard read model, which matches the #260 boundary contract.
Validation run locally in a temporary venv:
git diff --check origin/main...HEADpytest -q tests/test_persistence_architecture.py tests/test_actors.py tests/test_queue.py tests/test_migrations.py tests/test_packaged_resources.py-> 74 passedpytest -q-> 541 passed, 1 unrelated Starlette/httpx deprecation warninggab --db <tmp>/bridge.sqlite3 migrate-db-> applied migrations 1 and 2 on a fresh temporary DB
No blocking findings from my side.
|
Post-merge follow-up: reviewed merge commit Validation evidence: GitHub |
|
Post-merge cleanup rerun: PR #294 is merged at |
|
Post-merge review follow-up: PR #294 is merged at |
Summary
The actor backfill no longer performs feature-local DDL. A write pass now requires the current migrated schema and directs operators to
gab migrate-db;--dry-runstill inspects legacy databases without mutation.No schema or public CLI/API shape changes are included.
Validation
pytest -q— 541 passedpytest -q tests/test_persistence_architecture.py tests/test_actors.py tests/test_queue.py tests/test_migrations.py tests/test_packaged_resources.py— 73 passedgit diff --checkRequested by: @ecarreras
Relates to #260.