Skip to content

fix(host): keep a replayed compaction off the remote mirror - #1693

Merged
huichen merged 1 commit into
mainfrom
pr/huichen
Nov 25, 2026
Merged

huichen merged 1 commit into
mainfrom
pr/huichen

Conversation

@huichen

@huichen huichen commented Nov 25, 2026

Copy link
Copy Markdown
Collaborator

Summary

A session-scope replay re-sends every manual compaction a conversation ever had. The observer already dropped those replays for the desktop webview, but the remote mirror still published them, so a phone with no durable position for an old checkpoint appended its divider at the bottom of the timeline, over the streaming row (measured 2026-11-25 on a2677cac: 11-23 and 11-24 dividers under the newest reply while the session's own context was intact). This PR gates the mirror publish with the same replay rule and adds a test-only recorder so both lanes are asserted end to end.

Commits

  • fix(host): keep a replayed compaction off the remote mirror

Verification

  • cargo fmt --all -- --check — clean (rust 1.99.1, the pinned toolchain)
  • cargo clippy -p future-host --all-targets -- -D warnings — clean
  • cargo test -p future-host --lib — 2362 passed, 0 failed, 15 ignored (854.49s)

User-visible changes

  • Remote mirror / mobile timeline: a compaction lifecycle event that arrives from a session replay is no longer published to the mirror. Before: every replay re-emitted the conversation's whole compaction history, and a reconnecting phone appended those old dividers at the tail over the streaming row. After: replay-origin compaction events stay out of the mirror, matching the rule the desktop webview already follows; every other event, and every live compaction, still publishes. Rollback: revert e6a6838ae.

A session-scope replay carries every manual compaction the conversation
ever had, and the observer already dropped those for the webview. The
mirror lane published them anyway, so a phone with no durable position
for an old checkpoint appended its divider at the bottom of the timeline,
over the streaming row (measured 2026-11-25 on a2677cac: 11-23 and 11-24
dividers under the newest reply while the session's context was intact).

Gate the mirror publish with the same replay rule and record published
events in a test-only recorder, so both lanes are asserted end to end.
@huichen
huichen enabled auto-merge (squash) November 25, 2026 11:36
@huichen
huichen merged commit 7f6ad77 into main Nov 25, 2026
21 checks passed
@huichen
huichen deleted the pr/huichen branch November 25, 2026 11:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant