test: prove writer termination before peer commit #221

Merged
svc-agent-writer merged 1 commit from proof/mail-precommit-termination into main 2026-11-15 02:29:24 +00:00

Summary

writer transaction: domain + change + event + projection
  → SIGKILL before COMMIT
  → reopen: no phantom rows
  → retry twice: one committed mutation

Closes the literal pre-commit termination gap in recovery case P01 and adds a writer-process restart/cursor check for P03. Application source, dependencies and contract bytes remain identical to Mail 0.15.0.

Evidence

  • Before: pre-commit coverage injected a SQLite error; the existing post-commit test terminated a child process.
    After: a real pre-commit SIGKILL is required, followed by rollback and exactly-once retry assertions. A new writer process also preserves identity/epoch and authenticates a retained cursor before appending the next event.
  • All 95 store tests and Ruff lint/format checks pass. Independent review passed. Exact commands and source hashes are in docs/testing/recovery-process-termination.md.

Merge Danger

Door: two-way

Tests and evidence only; no runtime, image release or live fault injection.

Blast Radius: tests

## Summary ```text writer transaction: domain + change + event + projection → SIGKILL before COMMIT → reopen: no phantom rows → retry twice: one committed mutation ``` Closes the literal pre-commit termination gap in recovery case P01 and adds a writer-process restart/cursor check for P03. Application source, dependencies and contract bytes remain identical to Mail 0.15.0. ## Evidence - **Before:** pre-commit coverage injected a SQLite error; the existing post-commit test terminated a child process. **After:** a real pre-commit SIGKILL is required, followed by rollback and exactly-once retry assertions. A new writer process also preserves identity/epoch and authenticates a retained cursor before appending the next event. - All 95 store tests and Ruff lint/format checks pass. Independent review passed. Exact commands and source hashes are in `docs/testing/recovery-process-termination.md`. ## Merge Danger **Door:** two-way Tests and evidence only; no runtime, image release or live fault injection. **Blast Radius:** tests
test: prove writer termination before peer commit
All checks were successful
ci/woodpecker/pr/validation Pipeline was successful
4eb2d96143
Co-Authored-By: Codex GPT-5 <noreply@openai.com>
Sign in to join this conversation.
No description provided.