Skip to content

fix(server): preserve attachments during incomplete replay - #30

Merged
asfires merged 1 commit into
mainfrom
t3code/guard-attachment-reconciliation
Aug 13, 2026
Merged

asfires merged 1 commit into
mainfrom
t3code/guard-attachment-reconciliation

Conversation

@asfires

@asfires asfires commented Aug 13, 2026

Copy link
Copy Markdown
Owner

Projection bootstrap treated its current read model as authoritative for attachment cleanup even when replay had stopped before the event-log head. That allowed files for not-yet-projected messages to be deleted as apparent orphans.

Require every expected projector cursor to exactly match the event-log head before bootstrap attachment reconciliation can remove files. If any projector is missing or lagging, reconciliation is skipped with a structured warning. A regression test truncates replay before an attachment-bearing event and verifies the file remains intact.

Verification: focused projection pipeline tests (28 passed), targeted lint, and server typecheck.

Generated with GPT-5.6-sol via the Codex harness in T3 Code.

@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:M labels Aug 13, 2026
@asfires
asfires merged commit 830b2b5 into main Aug 13, 2026
6 of 10 checks passed
@asfires
asfires deleted the t3code/guard-attachment-reconciliation branch August 13, 2026 18:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant