Repository navigation
Conversation
… wall clock Why: `buildMirroredAgentStatusPatch`'s merge (src/renderer/src/runtime/web-session-tabs-sync/agent-status-patch.ts:118) had a second arm, `existing.updatedAt > entry.updatedAt`, that let any client row -- proven owner or not -- outrank the host purely by cross-machine wall-clock comparison. The file's own comment already says cross-machine wall clocks are not comparable. Two consequences: a stale, unproven client row with a lucky clock could outrank the host forever, and a host `blocked`/`interactivePrompt` row -- meant to pierce the client fence via `hostAgentStatusPiercesClientAuthority` -- still lost to an unowned client row on wall clock alone, because piercing only disabled the first arm, not the second. A host row is now replaced only by `clientOwnsEntry` -- a proven, fresh, client-owned row the host does not pierce; the wall-clock arm is deleted. Test: `web-session-tabs-sync-host-authority.test.ts` (new) -- an unowned client row with a later wall clock no longer beats a host `blocked` row or a host `done` row; a proven fresh client-owned row still keeps its state when the host does not pierce. On `main`: ``` expected 'working' to be '(blocked|done)' ``` One existing test in `web-session-tabs-sync-agent-status.test.ts` built its "existing" mirrored row directly into state without ever registering it as a proven writer -- three of its five assertions were passing purely via the deleted wall-clock arm. Its expectations are updated to match the corrected contract, each with a one-line comment naming the change. Ran: both files above, every other test file under `src/renderer/src/runtime/`, and `pnpm run tc:web`. All pass. Tested on macOS only; no OS-specific code touched. Co-Authored-By: Claude Sonnet 5 <[email protected]> Claude-Session: https://claude.ai/code/session_017xLuDWCWWWjzMm64rL13TR
|
Pullfrog stalled The agent stopped emitting events for 125s and was killed by the activity-timeout watchdog. The model produced no output at all before the stall — the request was sent but nothing came back. This is usually transient; re-running often succeeds.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (3)
Included review availability: Your plan provides up to 10 included reviews per hour; 1 remains after this review. 📝 WalkthroughWalkthroughThe host agent-status patch no longer uses cross-machine wall-clock timestamps to preserve existing client rows. It preserves an existing row only when the row is proven client-owned and the host does not pierce it. Tests now cover host precedence for unowned rows and preservation of eligible client-owned rows. Existing expectations also reflect host timestamps, host turn state, and provider-session identity. Priority: ⬇️ Low Merge Risk: ⚪ Minimal · up to Host status synchronization now avoids cross-machine clock arbitration and has coverage for host precedence and valid client ownership. No current merge-blocking risk was identified. 🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
Full details: Description checkExplanation The description explains the change, reason, scope, tests, compatibility considerations, and checklist status. However, it omits the required Visual Proof section and does not provide the required linked issue; it states that no tracked issue exists instead. The manual-testing checklist item is also missing. Resolution Add the required ## Visual Proof section with
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |

ELI5
Two machines (the host running an agent, and a client mirroring its status) don't have synchronized clocks. Orca's renderer used to let a client's status update win over the host's just because the client's timestamp looked "newer" — even when the client wasn't the one actually running the agent. That let a stale, unrelated status beat the real one, forever.
What Changed
buildMirroredAgentStatusPatch's merge (src/renderer/src/runtime/web-session-tabs-sync/agent-status-patch.ts:118) had a second arm,existing.updatedAt > entry.updatedAt, that let any client row — proven owner or not — outrank the host purely by cross-machine wall-clock comparison. The file's own comment already said cross-machine wall clocks are not comparable. Two consequences: a stale, unproven client row with a lucky clock could outrank the host forever, and a hostblocked/interactivePromptrow — meant to pierce the client fence viahostAgentStatusPiercesClientAuthority— still lost to an unowned client row on wall clock alone, because piercing only disabled the first arm, not the second.A host row is now replaced only by
clientOwnsEntry— a proven, fresh, client-owned row the host does not pierce; the wall-clock arm is deleted.Why
Comparing wall clocks across two machines to decide which status wins is exactly the kind of "loss of contact / unrelated signal treated as authoritative" pattern this codebase's agent-status-store contract exists to prevent (the execution host owns status in one store; readers keep only presentation policy).
Linked Issue
No existing tracked issue — found via an independent orchestration/safety audit of this codebase (Odin, see final note); the main-process copies of this class of bug were already closed upstream per
docs/reference/agent-status-store.md.Testing
web-session-tabs-sync-host-authority.test.ts(new) — an unowned client row with a later wall clock no longer beats a hostblockedrow or a hostdonerow; a proven fresh client-owned row still keeps its state when the host does not pierce. Onmain:One existing test in
web-session-tabs-sync-agent-status.test.tsbuilt its "existing" mirrored row directly into state without ever registering it as a proven writer — three of its five assertions were passing purely via the deleted wall-clock arm. Its expectations are updated to match the corrected contract, each with a one-line comment naming the change.Ran: both files above, every other test file under
src/renderer/src/runtime/(185 files / 1562 tests), andpnpm run tc:node+pnpm run tc:web.tc:nodeis clean.tc:webcurrently reports ~290 pre-existing errors in this environment, entirely in unrelated@tiptap/markdown-editor files caused by a brokennode_modulessymlink for@tiptap/corein this local checkout (confirmed: zero of those errors are in any file this PR touches, and the missing top-levelnode_modules/@tiptap/coresymlink predates this change). Tested on macOS only; no OS-specific code touched.AI Disclosure
Review
Agent skill upstream boundary
docs/reference/agent-skill-sharing-upstream-boundary.mdand copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.Notes
Security: none. Cross-platform: no OS-specific code touched. Remote SSH: this is a renderer-side mirroring path for remote-runtime/structured-chat panes whose bytes never transit the host's own agent-status store; that residual (the renderer still writing authoritative rows itself in those two cases) is a separate, larger change and out of scope here. Mobile: not applicable. Backwards compatibility: no wire shape changed — this only removes one arm of a local merge decision.
Checklist
N/Awith reason — N/A, this changes which status value wins a merge, not any rendered layout; no visual diff to show.pnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred) — ran targetedvitest+tc:node/tc:weblocally (see Testing, including the pre-existing unrelatedtc:webenvironment issue); fullpnpm lint/pnpm buildleft to CI.Extracted from Odin (github.com/unempyd/odin), a derivative that closes Orca's residual orchestration and safety contracts; all of its changes are offered upstream.