Home

mweinbach / agent-coworker

publicmweinbach/agent-coworker
Overview Code History Branches Pull requestsIssuesInsights
main
HomeOverview Code PRsIssues

fix: let rerun child-agent states replace equal-timestamp snapshots

6 months ago

d9a5726
Authored
mweinbach4/13/2026, 7:07:48 PM
The stale-snapshot guard should only reject strictly older agent summaries. Equal-timestamp follow-up status events are legitimate during child-agent reruns, so the projector and desktop transcript rebuilders now allow the later event to win while still blocking older wait-result snapshots.

Constraint: Child reruns can publish a synthetic running summary before sessionInfo.updatedAt advances.
Rejected: Keep terminal-vs-nonterminal tie-break on equal timestamps | leaves reused child agents stuck in completed until the rerun finishes.
Confidence: high
Scope-risk: narrow
Directive: Use updatedAt to reject only strictly older agent summaries; equal timestamps still need event-order semantics.
Tested: bun run typecheck; bun test
Not-tested: Remote MCP integration tests remain skipped by default.

Parent5e1eb3e

4 files changed
  • apps/desktop/src/app/store.feedMapping.ts+0−16
  • apps/desktop/test/store-feed-mapping.test.ts+66−0
  • src/server/session/SessionSnapshotProjector.ts+0−16
  • test/sessionSnapshotProjector.test.ts+61−0