Skip to content

feat(agent-status): route structured sessions through canonical ownership - #20718

Merged
brennanb2025 merged 8 commits into
mainfrom
brennanb2025/pr2a-3-structured-routing
Sep 16, 2026
Merged

brennanb2025 merged 8 commits into
mainfrom
brennanb2025/pr2a-3-structured-routing

Conversation

@brennanb2025

@brennanb2025 brennanb2025 commented Sep 14, 2026 •

Copy link
Copy Markdown
Contributor
Files Added Deleted Net
Test 22 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​1128 $\color{#cf222e}{\Huge{\mathbf{−}}}$​82 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​1046
Prod 33 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​724 $\color{#cf222e}{\Huge{\mathbf{−}}}$​222 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​502

ELI5

Makes it live for native chat. Structured (native-chat) sessions now publish, revoke and forget
through the canonical store, and their child rows get fenced lifetimes. CLI/PTY agents keep their
producer and their row order, but the mechanism behind that order does change: legacy and
canonical rows are now merged into one list sorted by a shared counter both draw from, where the
legacy side previously relied on map insertion order alone. A regression there would surface through
shared-bounded-status-cache, relay-status-cache, or main-pane-alias-transfer — look at those
rather than taking "untouched" on trust.

Why only native chat

The original plan for this stage said "key everything by scoped subject." Implementation proved that
impossible and stopped rather than fudging it: the hook payload carries no execution host, WSL distro
or workspace kind anywhere, the structured sink carries only a workspace id, and relay ownership is
pane-keyed — while the subject type requires all four scope fields. Satisfying it literally would have
meant fabricating scope for PTY and relay evidence.

So the line moved to where trusted scope actually exists today: structured sessions already carry
their full owner location, so they migrate for real now; PTY/relay evidence waits for the PR that
binds it properly. All three reviewing seats signed that amended boundary.

The part that keeps this honest

The legacy adapter is temporary, and "temporary" needs a forcing function rather than an intention.
The required-suite ratchet over the legacy allowlist landed with #20717 — required-suite
specifically, because an e2e-only guard gates nothing in this repo — and it governs this PR rather
than being carried by it. The allowlist must be empty before the next stage can complete, and its
removal is proven by ablation rather than by disuse.

What this PR adds to that boundary is the admission guard itself: a payload carrying structuredHost
can no longer enter the legacy adapter at all, so the canonical store is the only path a structured
session has.

What a reviewer should check first

The structured publish/revoke/forget path, and specifically exact-subject forget — including the
record-deleted-first teardown case. Ownership transfer and teardown ordering is where this kind of
change goes wrong quietly.

Second: the renderer bridge production file is deliberately untouched. It is currently the only
source of native-chat child rows, and deleting it before a host-side producer exists would silently
kill them. That deletion belongs to a later PR, paired with its replacement.

Scope

Third of three, originally stacked on #20717 (now merged); this targets main. It also updates
docs/reference/agent-status-store.md to record the amended 2A boundary and drops the stale 2A
progress doc. What is still owed after this lands:

  • PR 2B binds trusted PTY/relay scope and hands ownership over atomically, retiring the current
    producers from the legacy manifest.
  • PR 2C admits full provider child observations before lossy summaries, and supplies structured
    turn/completion clocks.
  • Reader cutover needs whole-row delivery parity and capability negotiation first. Until both
    exist, StructuredAgentSessionStatusBridge and the main structured-row publication filters have to
    stay.
  • Pane-only old clients keep their existing successor-fact limitations. A legacy projection does
    not grant those clients canonical identity or action authority.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

Read the full 56-file diff end-to-end and exercised the touched suites locally (full src/main/agent-hooks subtree plus the shared store/child-work, native-chat wire, runtime, ipc, and relay files — all green). This slice moves native-chat (structured) sessions off the legacy adapter onto the canonical store while deliberately leaving PTY/OSC/relay evidence on the isolated adapter.

  • Canonical structured ingress — ingestStructuredStatus(summary, subject) now takes the exact host-scoped structured-session subject, validates it against the summary (kind/sessionId/workspaceId/finite updatedAt), refuses an address already held by legacy evidence, and writes through applyMutation({ reopenStructuredParent: true, parent }). Legacy readers are projected from the committed row via structuredStatusLegacyEvent, with receivedAt kept monotonic and stateStartedAt preserved across same-state updates.
  • Mixed enumeration order — combinedStatusEntries() merges legacy rows and canonical parents-with-status under one shared listing-order counter, so legacy and canonical rows cannot reorder each other through updates, drops, re-admission, or pane relocation.
  • Owner-address retention — StructuredAgentSessionStatusOwnership keeps the exact subject so teardown forgets it even after the session record and live session are deleted, forgets the previous scope before publishing a trusted relocation, and keeps the address when a downstream observer throws. The record-deleted-first teardown path no longer needs a pane-key lookup.
  • Legacy fencing — admission refuses structuredHost rows and canonically owned pane keys in both directions; applyNormalizedStatus returns undefined on refusal and its callers (lifecycle/retries/inference) were made null-safe.
  • Child-work lifetime fencing — new binding keys distinguish one alias across several proven lifetimes, resume tombstones retired fences beyond the bounded history, settled children are immutable, and freshness treats idle/done as terminal rather than decaying them.
  • Store hardening — an exact cumulative 16 MiB byte-budget pre-check (agent-status-store-byte-budget.ts) is now the final step of validateAgentStatusStoreState, and reopenStructuredParent is parsed only for a structured-session parent, clearing exactly that parent tombstone.
  • Credential tightening — structuredWorkerPaneKeyBelongsToSession now rejects the public structuredAgentSessionPaneKey, whose hash-derived leaf otherwise satisfies the terminal-UUID shape check.

I also verified the byte-budget accounting against serializeAgentStatusStoreSnapshot (base empty-array object + one comma per extra record + per-record bytes is byte-exact, and those records are deeply frozen so the WeakMap cache cannot go stale), and that this only converts a deferred serialize-time throw into an atomic mutation-time rejection. Benchmarked getSnapshot() at ~0.02 ms for a realistic canonical store, so the new per-notification enumeration is not a hot-path cost in this slice.

Pullfrog  | View workflow run | Using DeepSeek Flash (free via Pullfrog for OSS) | 𝕏

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

Incremental delta since the prior pullfrog review (c93a9e09f4 → 60c3f3c8d3), three files:

  • Re-admit after teardown — StructuredAgentSessionStatusFeed.publish no longer early-returns when an unchanged projection is seen while the ownership no longer holds the session's address. It now re-publishes through sink(summary, session.params.location) when ownership.matchesLocation(...) is false, restoring the canonical parent and its legacy projection after an earlier forget removed them.
  • Scope comparison — new StructuredAgentSessionStatusOwnership.matchesLocation compares all four execution-scope fields (executionHostId, wslDistro, workspaceId, workspaceKind) against the retained subject, so both a forgotten address and a moved address trigger the re-publish path.
  • Coverage — structured-agent-session-status-reentry.test.ts pins re-admission after forget and moving an unchanged projection to a new host scope (asserting the old subject is forgotten exactly once and the new one published).

This addresses the teardown/re-admit ordering hazard directly and reads correctly: the subject is stored in publish before the sink call, so a throwing sink cannot cause a re-publish loop, and a forget that throws retains the subject for a later retry. The new test fails without the fix (parents would stay empty after re-adding the session). Local run of the re-entry, feed, and ownership suites is green.

Pullfrog  | View workflow run | Using DeepSeek Flash (free via Pullfrog for OSS) | 𝕏

@brennanb2025
brennanb2025 force-pushed the brennanb2025/pr2a-2-canonical-store-contract branch from d94b0d1 to c1ac898 Compare September 15, 2026 17:44
@brennanb2025
brennanb2025 force-pushed the brennanb2025/pr2a-3-structured-routing branch from 60c3f3c to 53cfb0c Compare September 15, 2026 17:59

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ℹ️ No critical issues — one minor suggestion inline.

Reviewed changes

This increment is a rebase of the structured-routing series onto the updated pr2a-2 base (c93a9e09f4/60c3f3c8d3 → 030f435b98/53cfb0c2db). Every file is byte-identical to its previously reviewed version except structured-worker-identity.ts; the canonical ingress, listing, ownership, legacy fencing, child-work lifetime, store hardening, and the re-admit-after-teardown fix are otherwise unchanged code the prior reviews already read.

  • Rebased the two-commit series onto base c1ac898c58, leaving the previously reviewed behavior intact across server-ingest-structured.ts, server-listeners.ts, server-status-update.ts, the ownership/feed wire, and the shared child-work/store files.
  • Re-applied the structuredAgentSessionPaneKey credential guard during conflict resolution into persistedStructuredWorkerPaneKeyIsValid, where the updated base already carries the identical predicate, producing a duplicate && term (flagged inline).

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using DeepSeek Flash (free via Pullfrog for OSS) | 𝕏

…ip and fence child lifetimes

Restacked onto the canonical store and child-work contract. Completing that
restack drops the `reopenStructuredParent` mutation flag this change had
carried, along with its contract field, its codec branch, and its single
call site in structured ingest, which passed a hardcoded `true`.

The flag was a narrow escape hatch from the absolute `tombstones.has(...)`
rule that governed parent upserts in this branch's original base. The
canonical store replaces that rule with a revision envelope, because a
bounded store compacts tombstones away and a presence-based guard silently
stops fencing once one is evicted. With the envelope deciding the outcome,
the escape hatch has nothing left to escape from, so removing it changes no
production behaviour.

`agent-status-store-reopen.test.ts` is rewritten against the envelope: the
reopen case now pins that an unflagged republication succeeds while replay
from before the reopen stays fenced even after the parent tombstone is
compacted away, and the second case pins where the guard genuinely bites —
a republication inside the removing mutation itself, for every subject kind.
…dings

- agent-status-store-byte-budget.ts: type the byte-budget helper's
  record parameter as the union of what its call sites actually pass
  (the snapshot header plus each store entity record) instead of the
  broad `object`.
- server-structured-canonical-status.test.ts: replace `Reflect.apply`
  with a typed, explicitly-bound call that models a caller at an
  untyped boundary omitting the trusted owner subject.
@brennanb2025
brennanb2025 force-pushed the brennanb2025/pr2a-3-structured-routing branch from 0e13d31 to 93e0273 Compare September 16, 2026 05:46
@brennanb2025
brennanb2025 changed the base branch from brennanb2025/pr2a-2-canonical-store-contract to main September 16, 2026 05:46

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ℹ️ No critical issues — one minor cleanup suggestion inline.

Reviewed changes

This increment restacks the structured-routing series onto the now-merged canonical-store contract (0e13d31087 → 93e0273f8a); the three commits are the same logical changes as the prior review, re-based, with one semantic change.

  • Dropped the reopenStructuredParent escape hatch — the mutation field, its codec branch, and the hardcoded true at the structured-ingest call site are gone. The store's revision envelope (upsertParent rejects when tombstone.revision >= revision) already decides parent reopen, and agent-status-store-reopen.test.ts was rewritten to pin the successful reopen and the same-mutation fence for every subject kind.
  • Adapted to the new base APIs — getAliasesForChild, binding-key tombstones/queries, the new agentStatusStoreFitsByteBudget, and the extracted resume/stop admission helpers; agent-status-child-work-stop.ts and agent-status-store-run-index.ts are now taken from the base instead of being carried by the PR.
  • Carried forward unchanged — the re-admit-after-teardown matchesLocation fix and the anti-slop lint cleanup. structured-agent-session-status-feed.ts, structured-agent-session-status-ownership.ts, server-listeners.ts, and structured-worker-identity.ts are byte-identical to the prior reviewed state.

I traced the flag removal myself and it is behavior-preserving: agent-status-store-mutation.ts:145 fences on the tombstone revision, every structured publish allocates snapshot.revision + 1, and no production mutation pairs removeParent with a same-mutation parent. The focused suites (24 tests across reopen/bounds/byte-budget/lifetime/canonical-status/reentry) are green on this head.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using DeepSeek Flash (free via Pullfrog for OSS) | 𝕏

Comment thread src/shared/agent-status-store-state.ts Resolved
@coderabbitai

coderabbitai Bot commented Sep 16, 2026 •

Copy link
Copy Markdown
Contributor

Review Change StackReview Change Stack

📝 Walkthrough

Walkthrough

The pull request adds subject-aware canonical storage for structured agent status. It updates feed ownership, runtime wiring, listener replay, legacy admission, and lifecycle reset behavior. It adds child-work binding codecs, resume handling, alias queries, lifetime fencing, and byte-budget validation. It also updates child freshness projection and related tests.

Priority: ➖ Normal

Merge Risk: 🟡 Moderate · up to 6185d

Structured status can be missing, retained after teardown, or removed while another valid session remains. These lifecycle and state-lookup risks should be resolved before merging.

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description explains the scope, rationale, migration boundary, and deferred work. However, it omits several required template sections, including a Linked Issue entry using "Fixes #", Visual Proof… Complete the required template sections. Add the linked issue, provide visual proof or state N/A with a reason, document testing and platforms, complete AI Disclosure when applicable, add Review and Notes content, and mark the relevant Chec…
Docstring Coverage ⚠️ Warning Docstring coverage is 25.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 44 functions across 51 files. (4 skipped:… Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the main change: routing structured sessions through canonical ownership.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description explains the scope, rationale, migration boundary, and deferred work. However, it omits several required template sections, including a Linked Issue entry using "Fixes #", Visual Proof or an explicit N/A reason, Testing details and checkboxes, AI Disclosure, Review, Notes, and the Checklist.

Resolution

Complete the required template sections. Add the linked issue, provide visual proof or state N/A with a reason, document testing and platforms, complete AI Disclosure when applicable, add Review and Notes content, and mark the relevant Checklist items.

Full details: Docstring Coverage

Explanation

Docstring coverage is 25.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 44 functions across 51 files. (4 skipped: 1 unsupported, 3 over the file limit.)

  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch

Warning

Git: CodeRabbit could not clone the repository, so clone-backed analysis was skipped and this review may be incomplete. Verify repository clone access, such as SSH credentials, before requesting another full review. If clone access is intentionally unavailable, use path_filters to narrow the review scope.


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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

⚠️ Outside the diff (1)

🟠 Major · Update getAlias for binding-keyed storage.

src/shared/agent-status-store.ts:93-94
🎯 Functional Correctness | 🟠 Major | 🏗️ Heavy lift

Update getAlias for binding-keyed storage.

state.aliases now uses binding keys, but getAlias still computes an alias key. These encodings have different prefixes, so this method returns null for every stored alias.

Replace this API with a set-valued lookup, or scan for the requested alias identity and define how ambiguity is reported.


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Advanced

Run ID: 753ee200-13a6-4204-a8a7-cb6dd8277e96

📥 Commits

Reviewing files that changed from the base of the PR and between feb04ec and 93e0273.

📒 Files selected for processing (56)
  • docs/reference/agent-status-canonical-boundary.md
  • docs/reference/agent-status-store.md
  • src/main/agent-hooks/first-work-branch-rename.test.ts
  • src/main/agent-hooks/server-ingest-structured-status.test.ts
  • src/main/agent-hooks/server-structured-canonical-status.test.ts
  • src/main/agent-hooks/server.ts
  • src/main/agent-hooks/server/server-ingest-structured.ts
  • src/main/agent-hooks/server/server-lifecycle.ts
  • src/main/agent-hooks/server/server-listeners.ts
  • src/main/agent-hooks/server/server-state.ts
  • src/main/agent-hooks/server/server-status-inference.ts
  • src/main/agent-hooks/server/server-status-retries.ts
  • src/main/agent-hooks/server/server-status-update.ts
  • src/main/agent-hooks/server/server-structured-status-row.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-forget-status.test.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-feed-test-session.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-feed.test.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-feed.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-ownership.test.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-ownership.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-reentry.test.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-subscribers.test.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-surface-lifetime.test.ts
  • src/main/orcad/orcad-entry.ts
  • src/main/runtime/orca-runtime-tests/worktree-ps-structured-host.spec.ts
  • src/main/runtime/rpc/methods/structured-agent-session-rpc.test-fixture.ts
  • src/main/runtime/runtime-worktree-agent-rows-structured.test.ts
  • src/main/runtime/runtime-worktree-structured-agent-rows-liveness.test.ts
  • src/main/runtime/structured-worker-identity.test.ts
  • src/main/runtime/structured-worker-identity.ts
  • src/main/startup/main-process-runtime-service.ts
  • src/relay/agent-status-store-relay-context.test.ts
  • src/renderer/src/components/native-chat/StructuredAgentSessionStatusBridge.test.tsx
  • src/renderer/src/components/sidebar/useWorktreeAgentRows.test.ts
  • src/renderer/src/components/sidebar/worktree-subagent-child-rows.test.ts
  • src/renderer/src/components/sidebar/worktree-subagent-child-rows.ts
  • src/shared/agent-hook-listener/listener-state.ts
  • src/shared/agent-status-child-work-admission-core.ts
  • src/shared/agent-status-child-work-admission-operations.ts
  • src/shared/agent-status-child-work-admission.ts
  • src/shared/agent-status-child-work-binding.ts
  • src/shared/agent-status-child-work-freshness.ts
  • src/shared/agent-status-child-work-lifetime.test.ts
  • src/shared/agent-status-child-work-projection.test.ts
  • src/shared/agent-status-child-work-resume.ts
  • src/shared/agent-status-legacy-adapter.test.ts
  • src/shared/agent-status-legacy-adapter.ts
  • src/shared/agent-status-store-byte-budget.test.ts
  • src/shared/agent-status-store-byte-budget.ts
  • src/shared/agent-status-store-child-queries.ts
  • src/shared/agent-status-store-codec.ts
  • src/shared/agent-status-store-mutation.ts
  • src/shared/agent-status-store-persistence.ts
  • src/shared/agent-status-store-reopen.test.ts
  • src/shared/agent-status-store-state.ts
  • src/shared/agent-status-store.ts

Included review availability: Your plan provides up to 10 included reviews per hour; 7 remain after this review.

Comment on lines +55 to +56
this.subjects.set(summary.sessionId, subject)
sink.publish(summary, subject)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗄️ Data Integrity & Integration | 🟠 Major | 🏗️ Heavy lift

🔎 Supported by static analysis

🏁 Script executed:

sed -n '1,110p' src/main/native-chat/agent-session-wire/structured-agent-session-status-ownership.ts
sed -n '130,290p' src/main/native-chat/agent-session-wire/structured-agent-session-status-feed.ts
rg -n "matchesLocation|published|publish.*catch|sink\\(" src/main/native-chat/agent-session-wire/structured-agent-session-status-*.ts

Repository: stablyai/orca

Length of output: 12604


🏁 Script executed:

rg -n -C 8 "StructuredAgentSessionStatusSink|dropStructuredStatus|structured status|structured-session|status.*publish" src/main src/shared

Repository: stablyai/orca

Length of output: 50370


🏁 Script executed:

rg -n -C 12 "new StructuredAgentSessionStatusFeed|StructuredAgentSessionStatusSink|dropStructuredStatus|structuredAgentSessionStatus" src/main src/shared

Repository: stablyai/orca

Length of output: 50370


🏁 Script executed:

rg -n -C 20 "ingestStructuredStatus|dropStructuredStatus" src/main/agent-hooks src/main

Repository: stablyai/orca

Length of output: 50370


🏁 Script executed:

sed -n '17,125p' src/main/agent-hooks/server/server-ingest-structured.ts

Repository: stablyai/orca

Length of output: 4587


Keep failed status publications eligible for retry.

StructuredAgentSessionStatusFeed.sink() catches errors from AgentHookServer.ingestStructuredStatus(). That method commits the canonical row through canonicalStatusStore.applyMutation(). If it throws before the commit, the feed has already stored the summary and ownership has already stored the subject. The next unchanged publication sees matchesLocation(...) === true, and no pending or error state forces another publish. The canonical row can remain absent until another path causes a new sink call.

Track pending publication in StructuredAgentSessionStatusOwnership. Make matchesLocation() return false while publication is pending, and clear the pending state only after sink.publish() succeeds.

if (!subject) {
return
}
this.sink()?.forget(subject)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win

🔎 Supported by static analysis

🏁 Script executed:

rg -n "new StructuredAgentSessionStatusFeed|StructuredAgentSessionClientDelivery|forgetStatus|closeSession|\\.close\\(|dropStructuredStatus|ownerEpoch|owner.*generation" src/main
sed -n '1,120p' src/main/native-chat/agent-session-wire/structured-agent-session-status-ownership.ts

Repository: stablyai/orca

Length of output: 50370


🏁 Script executed:

set -eu
printf '%s\n' '--- ownership ---'
sed -n '1,140p' src/main/native-chat/agent-session-wire/structured-agent-session-status-ownership.ts
printf '%s\n' '--- feed ---'
sed -n '1,230p' src/main/native-chat/agent-session-wire/structured-agent-session-status-feed.ts
printf '%s\n' '--- client delivery ---'
sed -n '1,130p' src/main/native-chat/agent-session-wire/structured-agent-session-client-delivery.ts
printf '%s\n' '--- host lifetime ---'
sed -n '1,180p' src/main/native-chat/agent-session-wire/structured-agent-session-host-lifetime.ts
printf '%s\n' '--- host construction/use ---'
sed -n '1,230p' src/main/native-chat/agent-session-wire/structured-agent-session-host.ts
printf '%s\n' '--- feed construction sites ---'
rg -n -C 5 'StructuredAgentSessionStatusFeed|new StructuredAgentSessionStatusFeed|StructuredAgentSessionStatusOwnership|new StructuredAgentSessionStatusOwnership' src/main/native-chat src/main/orcad src/main/runtime
printf '%s\n' '--- sink wiring and implementation ---'
rg -n -C 8 'dropStructuredStatus|publish:.*structured|forget:.*structured|StructuredAgentSessionStatusSink|structured status' src/main/orcad src/main/native-chat src/main/agent-hooks src/main/runtime

Repository: stablyai/orca

Length of output: 50370


🏁 Script executed:

set -eu
printf '%s\n' '--- remaining feed publish/close section ---'
sed -n '190,380p' src/main/native-chat/agent-session-wire/structured-agent-session-status-feed.ts
printf '%s\n' '--- host teardown ---'
sed -n '1,240p' src/main/native-chat/agent-session-wire/structured-agent-session-host-teardown.ts
printf '%s\n' '--- host construction sites ---'
rg -n -C 8 'new StructuredAgentSessionHost|StructuredAgentSessionHost\\(' src/main --glob '*.ts' --glob '!*.test.ts'
printf '%s\n' '--- status sink wiring ---'
rg -n -C 10 'dropStructuredStatus|ingestStructuredStatus|StructuredAgentSessionStatusSink|statusSink' src/main/orcad src/main/agent-hooks src/main/native-chat --glob '*.ts' --glob '!*.test.ts'
printf '%s\n' '--- canonical store implementation ---'
rg -n -C 10 'dropStructuredStatus|ingestStructuredStatus|structuredStatus|StructuredStatus' src/main/agent-hooks/server src/shared --glob '*.ts' --glob '!*.test.ts'
printf '%s\n' '--- host lifetime call sites ---'
rg -n -C 8 'forgetStatus\\(|clientDelivery\\.closeSession|statusFeed\\.close|evictHeldStructuredAgentSession' src/main/native-chat --glob '*.ts' --glob '!*.test.ts'

Repository: stablyai/orca

Length of output: 9626


🏁 Script executed:

set -eu
printf '%s\n' '--- non-test host construction sites ---'
rg -n -F -C 8 'new StructuredAgentSessionHost' src/main --glob '*.ts' --glob '!*.test.ts'
printf '%s\n' '--- status sink wiring ---'
rg -n -F -C 10 'dropStructuredStatus' src/main/orcad src/main/agent-hooks src/main/native-chat --glob '*.ts' --glob '!*.test.ts'
rg -n -F -C 10 'ingestStructuredStatus' src/main/agent-hooks src/main/orcad src/main/native-chat --glob '*.ts' --glob '!*.test.ts'
printf '%s\n' '--- canonical status implementation ---'
fd -i 'agent-hook-server' src/main
rg -n -F -C 12 'structuredStatus' src/main/agent-hooks src/main/orcad --glob '*.ts' --glob '!*.test.ts'
printf '%s\n' '--- relevant host lifecycle callers ---'
rg -n -F -C 8 'tearDownStructuredAgentSessionHost' src/main/native-chat --glob '*.ts' --glob '!*.test.ts'
rg -n -F -C 8 'StructuredAgentSessionHost' src/main/native-chat --glob '*.ts' --glob '!*.test.ts' | head -240

Repository: stablyai/orca

Length of output: 50369


🏁 Script executed:

set -eu
printf '%s\n' '--- canonical store bindings ---'
rg -n -F -C 12 'canonicalStatusStore' src/main/agent-hooks src/main/shared src/shared --glob '*.ts' --glob '!*.test.ts'
printf '%s\n' '--- applyMutation definitions ---'
rg -n -F -C 18 'applyMutation' src/main/agent-hooks src/shared --glob '*.ts' --glob '!*.test.ts'
printf '%s\n' '--- runtime factory and lifecycle ---'
rg -n -F -C 12 'createStructuredAgentSessionRuntime' src/main --glob '*.ts' --glob '!*.test.ts'
rg -n -F -C 12 'installStructuredAgentSessionRuntime' src/main --glob '*.ts' --glob '!*.test.ts'
rg -n -F -C 12 'flushAllStreamedEvents' src/main/runtime src/main/native-chat --glob '*.ts' --glob '!*.test.ts'
printf '%s\n' '--- runtime construction references ---'
rg -n -F -C 8 'structuredAgentSessionRuntime' src/main --glob '*.ts' --glob '!*.test.ts' | head -240

Repository: stablyai/orca

Length of output: 18892


🏁 Script executed:

set -eu
printf '%s\n' '--- agent status store ---'
sed -n '1,240p' src/shared/agent-status-store.ts
printf '%s\n' '--- runtime module outline and construction ---'
rg -n '^(export )?(async )?(function|class|const) |new StructuredAgentSessionHost|host =|close|shutdown|dispose' src/main/runtime/structured-agent-session-runtime.ts
sed -n '240,390p' src/main/runtime/structured-agent-session-runtime.ts
printf '%s\n' '--- runtime callers and singleton bindings ---'
rg -n -F -C 10 'structured-agent-session-runtime' src/main --glob '*.ts' --glob '!*.test.ts'
rg -n -F -C 10 'createStructuredAgentSessionRuntime' src/main --glob '*.ts' --glob '!*.test.ts'

Repository: stablyai/orca

Length of output: 21572


🏁 Script executed:

set -eu
printf '%s\n' '--- runtime ensure/stop/teardown ---'
sed -n '100,235p' src/main/runtime/structured-agent-session-runtime.ts
printf '%s\n' '--- mutation removal branch ---'
rg -n -F -C 18 'removeParent' src/shared/agent-status-store-mutation.ts

Repository: stablyai/orca

Length of output: 9981


🏁 Script executed:

set -eu
printf '%s\n' '--- runtime install completion and restore calls ---'
sed -n '1,115p' src/main/runtime/structured-agent-session-runtime.ts
sed -n '300,430p' src/main/runtime/structured-agent-session-runtime.ts
printf '%s\n' '--- record store open/close contract ---'
rg -n -F -C 12 'static async open' src/main/native-chat/agent-session-record-store.ts src/main --glob '*record-store*.ts'
rg -n -F -C 10 'class AgentSessionRecordStore' src/main/native-chat src/main --glob '*.ts' | head -100
printf '%s\n' '--- lease release and attach publication boundary ---'
rg -n -F -C 14 'releaseStoredStructuredAgentSessionOwner' src/main/native-chat/agent-session-wire --glob '*.ts'
rg -n -F -C 12 'publishStatus' src/main/native-chat/agent-session-wire/structured-agent-session-attach-orchestration.ts src/main/native-chat/agent-session-wire/structured-agent-session-attach.ts --glob '*.ts'

Repository: stablyai/orca

Length of output: 12044


🏁 Script executed:

set -eu
printf '%s\n' '--- record store load and transaction initialization ---'
rg -n -F -C 14 'loadProtectedAgentSessionStore' src/main/runtime --glob '*.ts'
rg -n -F -C 14 'fromLoadedStore' src/main/runtime/agent-session-store-transaction-queue.ts
printf '%s\n' '--- concrete ensure caller ---'
sed -n '1,90p' src/main/runtime/orca-runtime-get-worktree-ps.ts
printf '%s\n' '--- attach publication path ---'
rg -n -F -C 18 'publishStatus(sessionId' src/main/native-chat/agent-session-wire --glob '*.ts'

Repository: stablyai/orca

Length of output: 12342


Fence status cleanup to the current owner.

stopStructuredAgentSessionRuntime() clears the installation slot before awaiting the old runtime teardown, so ensureStructuredAgentSessionHost() can create a new feed while the old feed still retains its subject. The new feed can publish the same persisted session and subject before the old feed calls forget(). dropStructuredStatus() then removes the current row for that exact subject without checking an owner generation or expected revision. The old feed can therefore delete the newer row.

Pass an owner generation or publication token through publish and forget, and remove the canonical row only when that token still owns it.

Comment on lines +64 to +65
this.sink()?.forget(subject)
this.subjects.delete(sessionId)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win

Retain the subject when the sink is unavailable.

If this.sink() returns undefined, Line 64 performs no cleanup. Line 65 still deletes the retained subject. A later retry cannot identify the canonical row, so teardown can leave stale status permanently.

Resolve the sink first. Delete the subject only after sink.forget(subject) completes.

Proposed fix
   forget(sessionId: string): void {
     const subject = this.subjects.get(sessionId)
     if (!subject) {
       return
     }
-    this.sink()?.forget(subject)
+    const sink = this.sink()
+    if (!sink) {
+      return
+    }
+    sink.forget(subject)
     this.subjects.delete(sessionId)
   }
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
this.sink()?.forget(subject)
this.subjects.delete(sessionId)
const sink = this.sink()
if (!sink) {
return
}
sink.forget(subject)
this.subjects.delete(sessionId)

Comment on lines +28 to +30
const alias = deserializeAgentChildWorkBindingKey(tombstone.key)
if (alias && keys.has(serializeAgentChildWorkAliasKey(alias))) {
matches.push(deepFreezeAgentStatusStoreValue({ ...alias, revision: tombstone.revision }))

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗄️ Data Integrity & Integration | 🟠 Major | 🏗️ Heavy lift

🔎 Supported by static analysis

🏁 Script executed:

rg -n "compactTombstones|tombstones|resolveChildAliases|resolveAgentStatusChildBindings|deleted children|retired" src/shared/agent-status-store* src/shared/agent-status-child-work*
sed -n '1,220p' src/shared/agent-status-store-child-queries.ts
sed -n '1,240p' src/shared/agent-status-child-work-lifetime.test.ts

Repository: stablyai/orca

Length of output: 15798


🏁 Script executed:

#!/bin/bash
set -eu
printf '%s\n' '--- mutation compaction and mutation paths ---'
sed -n '1,310p' src/shared/agent-status-store-mutation.ts
printf '%s\n' '--- admission core ---'
sed -n '1,240p' src/shared/agent-status-child-work-admission-core.ts
printf '%s\n' '--- store state invariants and snapshot restore ---'
sed -n '110,285p' src/shared/agent-status-store-state.ts
printf '%s\n' '--- tombstone-limit and reopen tests ---'
sed -n '220,320p' src/shared/agent-status-store.test.ts
sed -n '1,100p' src/shared/agent-status-store-reopen.test.ts

Repository: stablyai/orca

Length of output: 27675


🏁 Script executed:

set -eu
sed -n '1,310p' src/shared/agent-status-store-mutation.ts
sed -n '1,240p' src/shared/agent-status-child-work-admission-core.ts
sed -n '110,285p' src/shared/agent-status-store-state.ts
sed -n '220,320p' src/shared/agent-status-store.test.ts
sed -n '1,100p' src/shared/agent-status-store-reopen.test.ts

Repository: stablyai/orca

Length of output: 27512


🏁 Script executed:

set -eu
rg -n "resolveAgentChildWorkAliasRecords|resolveChildAliases|mintChildWorkId|created: true|buildAgentChildWorkAliases|announce\\(" src/shared/agent-status-child-work-admission.ts src/shared/agent-status-child-work-admission-*.ts
sed -n '1,320p' src/shared/agent-status-child-work-admission.ts

Repository: stablyai/orca

Length of output: 6967


🏁 Script executed:

set -eu
sed -n '1,125p' src/shared/agent-status-child-work-admission-operations.ts

Repository: stablyai/orca

Length of output: 4468


Keep deleted lifetime fences after tombstone compaction.

removeChild creates both child and alias tombstones. compactTombstones can remove both when the tombstone limit overflows. After snapshot restore, resolveAgentStatusChildBindings then finds no binding. announceAgentChildWork treats the empty result as a new child and can mint a replacement for the delayed observation.

Keep a compact durable fence for retired bindings, and add a regression test that deletes a child, forces tombstone compaction, restarts the store, and replays the old observation.

item.revision > state.revision ||
(item.entity === 'parent' && !deserializeAgentStatusSubject(item.key)) ||
(item.entity === 'alias' && !deserializeAgentChildWorkAliasKey(item.key)) ||
(item.entity === 'alias' && !deserializeAgentChildWorkBindingKey(item.key)) ||

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗄️ Data Integrity & Integration | 🟠 Major | 🏗️ Heavy lift

🔎 Supported by static analysis

🏁 Script executed:

rg -n "AGENT_STATUS_STORE_SNAPSHOT_VERSION|snapshotVersion|schemaVersion|agent-status.*snapshot|last-status|applySnapshot|stateFromSnapshot|alias tombstone|serializeAgentChildWorkAliasKey" src docs
sed -n '1,260p' src/shared/agent-status-store-state.ts
sed -n '1,180p' src/shared/agent-status-store-persistence.ts

Repository: stablyai/orca

Length of output: 50372


🏁 Script executed:

set -u
printf '%s\n' '--- focused files ---'
wc -l src/shared/agent-status-store-state.ts src/shared/agent-status-store-persistence.ts src/shared/agent-status-store-contract.ts 2>/dev/null || true
sed -n '1,280p' src/shared/agent-status-store-state.ts
printf '%s\n' '--- persistence ---'
sed -n '1,240p' src/shared/agent-status-store-persistence.ts
printf '%s\n' '--- contract ---'
sed -n '1,180p' src/shared/agent-status-store-contract.ts
printf '%s\n' '--- relevant repository references ---'
rg -n --glob '!src/cli/bundled-skill-guides.ts' --glob '!**/*.map' \
  'AGENT_STATUS_STORE_SNAPSHOT_VERSION|agentStatusStoreStateFromSnapshot|serializeAgentChildWorkAliasKey|deserializeAgentChildWorkBindingKey|serializeAgentChildWorkBindingKey|tombstone' \
  src/shared docs README.md package.json 2>/dev/null | head -n 300
printf '%s\n' '--- focused diff ---'
git diff -- src/shared/agent-status-store-state.ts src/shared/agent-status-store-persistence.ts src/shared/agent-status-store-contract.ts src/shared | head -n 500

Repository: stablyai/orca

Length of output: 34864


🤖 get_repo_knowledge executed:

get_repo_knowledge stablyai/orca /tmp/coderabbit-repo-knowledge/stablyai-orca-89dc44e4/architecture /tmp/coderabbit-repo-knowledge/stablyai-orca-89dc44e4/learnings /tmp/coderabbit-repo-knowledge/stablyai-orca-89dc44e4/conventions

Length of output: 47429


🏁 Script executed:

set -u
printf '%s\n' '--- alias and binding encodings ---'
sed -n '1,240p' src/shared/agent-status-child-work-alias.ts
sed -n '1,120p' src/shared/agent-status-child-work-binding.ts
printf '%s\n' '--- snapshot codec ---'
sed -n '1,330p' src/shared/agent-status-store-codec.ts
printf '%s\n' '--- store snapshot and replica callers ---'
sed -n '1,220p' src/shared/agent-status-store.ts
printf '%s\n' '--- mutation tombstone handling ---'
sed -n '1,280p' src/shared/agent-status-store-mutation.ts
printf '%s\n' '--- focused tests and compatibility references ---'
rg -n -C 5 --glob 'src/shared/agent-status-store*.test.ts' --glob 'src/shared/agent-status-child-work*.test.ts' \
  'snapshot|tombstone|alias|legacy|version|replica|restore|reopen' src/shared
printf '%s\n' '--- recent revision and parent comparison ---'
git log -1 --oneline --decorate
parent="$(git rev-parse HEAD^ 2>/dev/null || true)"
printf 'parent=%s\n' "$parent"
if [ -n "$parent" ]; then
  git show "$parent:src/shared/agent-status-store-state.ts" 2>/dev/null | sed -n '1,280p'
  printf '%s\n' '--- parent binding file ---'
  git show "$parent:src/shared/agent-status-child-work-binding.ts" 2>/dev/null | sed -n '1,120p'
  printf '%s\n' '--- parent mutation alias paths ---'
  git show "$parent:src/shared/agent-status-store-mutation.ts" 2>/dev/null | sed -n '100,270p'
fi

Repository: stablyai/orca

Length of output: 50370


🏁 Script executed:

set -u
log=/tmp/coderabbit-shell-logs/shell-output-fShZYV
printf '%s\n' '--- omitted history section from prior result ---'
rg -n -A 180 -B 5 -- '--- recent revision and parent comparison ---|^parent=' "$log" | head -n 400
printf '%s\n' '--- concise history ---'
git log -4 --oneline --decorate -- src/shared/agent-status-child-work-binding.ts src/shared/agent-status-store-state.ts src/shared/agent-status-store-mutation.ts src/shared/agent-status-store-contract.ts
printf '%s\n' '--- current and parent binding signatures ---'
parent="$(git rev-parse HEAD^ 2>/dev/null || true)"
printf 'parent=%s\n' "$parent"
if [ -n "$parent" ]; then
  printf '%s\n' 'parent binding:'
  git show "$parent:src/shared/agent-status-child-work-binding.ts" 2>/dev/null | sed -n '1,100p'
  printf '%s\n' 'parent state tombstone/alias lines:'
  git show "$parent:src/shared/agent-status-store-state.ts" 2>/dev/null | rg -n -C 4 \
    'serializeAgentChildWork|deserializeAgentChildWork|item.entity|tombstone|SNAPSHOT_VERSION' | head -n 180
  printf '%s\n' 'parent mutation alias/tombstone lines:'
  git show "$parent:src/shared/agent-status-store-mutation.ts" 2>/dev/null | rg -n -C 4 \
    'serializeAgentChildWork|deserializeAgentChildWork|removeAlias|tombstone' | head -n 180
  printf '%s\n' 'parent contract version:'
  git show "$parent:src/shared/agent-status-store-contract.ts" 2>/dev/null | rg -n -C 3 \
    'SNAPSHOT_VERSION|Tombstone|Snapshot'
fi

Repository: stablyai/orca

Length of output: 21913


🏁 Script executed:

set -u
printf '%s\n' '--- introducing commit metadata ---'
git show --stat --oneline 8ef5feb112
printf '%s\n' '--- introducing commit relevant diff ---'
git diff 8ef5feb112^ 8ef5feb112 -- \
  src/shared/agent-status-child-work-binding.ts \
  src/shared/agent-status-store-state.ts \
  src/shared/agent-status-store-mutation.ts \
  src/shared/agent-status-store-contract.ts \
  src/shared/agent-status-store-codec.ts \
  src/shared/agent-status-store.ts | head -n 500
printf '%s\n' '--- pre-transition state and mutation ---'
git show 8ef5feb112^:src/shared/agent-status-store-state.ts 2>/dev/null | rg -n -C 8 \
  'serializeAgentChildWork|deserializeAgentChildWork|item.entity|tombstone|SNAPSHOT_VERSION' | head -n 240
git show 8ef5feb112^:src/shared/agent-status-store-mutation.ts 2>/dev/null | rg -n -C 8 \
  'serializeAgentChildWork|deserializeAgentChildWork|removeAlias|tombstone' | head -n 240
printf '%s\n' '--- pre-transition contract and codec version ---'
git show 8ef5feb112^:src/shared/agent-status-store-contract.ts 2>/dev/null | rg -n -C 4 \
  'SNAPSHOT_VERSION|Tombstone|Snapshot'
git show 8ef5feb112^:src/shared/agent-status-store-codec.ts 2>/dev/null | rg -n -C 5 \
  'SNAPSHOT_VERSION|tombstone'
printf '%s\n' '--- initial store commit aliases/tombstones ---'
git show 0325f1a22e:src/shared/agent-status-store-mutation.ts 2>/dev/null | rg -n -C 5 \
  'serializeAgentChildWork|deserializeAgentChildWork|removeAlias|tombstone' | head -n 180

Repository: stablyai/orca

Length of output: 36992


🏁 Script executed:

set -u
printf '%s\n' '--- store documentation ---'
for f in docs/reference/agent-status-store.md docs/reference/agent-status-canonical-boundary.md; do
  if [ -f "$f" ]; then
    printf '%s\n' "--- $f ---"
    rg -n -C 5 'snapshot|persist|replica|version|tombstone|compatib|migration' "$f" | head -n 240
  fi
done
printf '%s\n' '--- persistence and transport call sites ---'
rg -n -C 5 --glob '!src/cli/bundled-skill-guides.ts' \
  'serializeAgentStatusStoreSnapshot|deserializeAgentStatusStoreSnapshot|applySnapshot|applyTransportEnvelope|type: .snapshot.|snapshot:' \
  src/main src/relay src/shared docs | head -n 360
printf '%s\n' '--- reopen and transport tests ---'
sed -n '1,140p' src/shared/agent-status-store-reopen.test.ts
sed -n '1,180p' src/shared/agent-status-transport-envelope.ts
rg -n -C 4 'applySnapshot|snapshot|replica|transport' src/shared/agent-status-store*.test.ts src/shared/agent-status-transport-envelope*.ts | head -n 300

Repository: stablyai/orca

Length of output: 50369


Preserve version-1 snapshot compatibility. The binding-key transition kept AGENT_STATUS_STORE_SNAPSHOT_VERSION at 1, although the previous implementation wrote alias-only keys into alias tombstones. Current agentStatusStoreStateFromSnapshot accepts the snapshot version, then validateAgentStatusStoreState rejects those tombstones because it only parses binding keys. A persisted snapshot or replica snapshot can therefore fail restoration.

If version 1 remains supported, add a compatibility reader for the legacy tombstone shape before current validation. Otherwise, bump the snapshot version and reject the old format explicitly.

docs/reference/ holds implementation detail, not rollout progress. The
canonical-boundary notes move to the effort's working directory; the
agent-status-store status section keeps the boundary statement and loses
the now-dangling link.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Outside the diff (1)

🟡 Minor · Align getAlias with the binding index.

src/shared/agent-status-store.ts:93-94
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Align getAlias with the binding index. AgentStatusStore.getAlias accepts AgentChildWorkAliasIdentity, which omits the child-work ID and fence, but upsertAliases stores records under serializeAgentChildWorkBindingKey. The lookup therefore misses every active alias record and returns null. Since one alias can name several bindings, make getAlias binding-specific or replace it with the existing resolveChildAliases API.


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Advanced

Run ID: f6096f4a-fb5c-483e-bf4a-c111d068a473

📥 Commits

Reviewing files that changed from the base of the PR and between 93e0273 and 69f14ab.

📒 Files selected for processing (1)
  • docs/reference/agent-status-store.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • docs/reference/agent-status-store.md

Included review availability: Your plan provides up to 10 included reviews per hour; 7 remain after this review.

…truction

The hook server's canonical store was built in an instance-member initializer, so
constructing AgentHookServer — which happens at import time for the module
singleton — demanded a live randomUUID. Any importer that stubs node:crypto threw
'Invalid agent status store epoch' before a single test ran.

The store is now created on first canonical access and reset by dropping it, so
construction owes nothing to a crypto implementation and the epoch still rotates
per authority incarnation.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ℹ️ No new issues introduced by this delta.

Reviewed changes

Incremental delta since the prior pullfrog review (69f14ab7ac → 65b9885ccf), one file, one commit:

  • Lazy canonical epoch — AgentHookServerState.canonicalStatusStore is now a lazy getter over private canonicalStatusStoreInstance, so constructing the AgentHookServer module singleton no longer calls randomUUID() and owes nothing to a live node:crypto implementation. Any importer that stubs node:crypto previously threw Invalid agent status store epoch at import time.
  • Reset by dropping — resetCanonicalStatus() now nulls the stored instance instead of eagerly building a replacement, so the epoch still rotates per authority incarnation on the next canonical access.

I verified the fix is behavior-preserving: createAgentStatusStore is the only production store seeded from randomUUID() (every other call site passes a literal epoch), no production call site captures a store reference across resetCanonicalStatus(), and the motivating suite — ssh-relay-session-reconnect-incarnation.test.ts, which mocks randomUUID to return undefined while transitively importing the singleton via ssh-relay-session.ts — now passes (15/15), with pnpm tc:node clean. This review is non-approving only because two earlier Pullfrog inline threads remain open and are untouched by this commit.

Pullfrog  | Fix it ➔ | View workflow run | Using DeepSeek Flash (free via Pullfrog for OSS) | 𝕏

… pane guard

Two leftovers from the canonical-store routing change:

agent-status-store-snapshot-budget.ts lost its only caller when the store state
switched to agentStatusStoreFitsByteBudget. Nothing in the repo imports it now,
so the module goes with the caller it existed for. The replacement is not a
straight copy: it only memoises a record's measured size once the record is
frozen, so a still-mutable record can no longer return a stale byte count.

persistedStructuredWorkerPaneKeyIsValid repeated its public-pane-key rejection
verbatim three lines below the first one. The tests covering that rejection pass
on the first occurrence alone, so the second decided nothing and only obscured
which predicate was load-bearing.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

Incremental delta since the prior pullfrog review (65b9885ccf → 0f5db831a0), one commit that only removes code:

  • Removed a duplicated credential guard — persistedStructuredWorkerPaneKeyIsValid no longer evaluates paneKey !== structuredAgentSessionPaneKey(...) twice, and parsed.tabId/isTerminalLeafId are unchanged, so the rejection of the public status pane key is preserved. With the duplicate gone, structured-worker-identity.ts is byte-identical to its base version and drops out of the PR diff.
  • Deleted the orphaned snapshot budget — agent-status-store-snapshot-budget.ts, unreferenced since this PR moved validateAgentStatusStoreState onto agentStatusStoreFitsByteBudget, is removed, leaving a single byte-budget implementation.

Both changes retire the two prior Pullfrog inline threads (now resolved); no behavioral surface is introduced. Focused suites green (structured-worker-identity 17 tests, agent-status-store-byte-budget 2 tests) and pnpm tc:node clean.

Pullfrog  | View workflow run | Using DeepSeek Flash (free via Pullfrog for OSS) | 𝕏

…owned

Three defects found reviewing the structured routing path.

combinedStatusEntries defaulted a missing listing order to 0, but the counter it
compares against starts at 1, so any unordered row sorted above every ordered
one. Unknown order now sorts last.

The owner map recorded a session as owned before the sink ran. A publish that
threw therefore left matchesLocation reporting an owned location for a row that
was never written, and the unchanged-projection path — the only thing that would
re-offer it — stopped. The address still has to survive a throw so teardown can
forget a row that did land, so the two facts are now separate: the address is
recorded up front, and only a publish that returned marks the row as landed.

The reopen test claimed the revision envelope rather than the tombstone fences a
stale replay. It cannot tell: transport consecutiveness, the parent-revision
validator and the tombstone guard each refuse that replay alone, and ablating any
two leaves the test green. It now asserts the outcome and says so.
# Conflicts:
#	src/shared/agent-status-store-snapshot-budget.ts
@brennanb2025

Copy link
Copy Markdown
Contributor Author

Merge-gate review — verified at 6185d0623b

Reviewed against the outcome, not just the diff, in an isolated detached worktree. Four defects found and fixed on the branch; the PR body has been corrected where its prose overclaimed.

The three red checks at the head I picked up

  1. tests node 24 1/8 — real, fixed. AgentHookServerState built the canonical store in an instance-member initializer, so constructing AgentHookServer — which happens at import time for the module singleton — demanded a live randomUUID. Any importer that stubs node:crypto threw Invalid agent status store epoch before a test ran. Fixed on the production side: the epoch is minted on first canonical access and reset by dropping the store. The stub in ssh-relay-session-reconnect-incarnation.test.ts is untouched and now passes 15/15 — stubbing node:crypto is a normal thing for a test to do, and a class that cannot be constructed without live crypto was the defect.
  2. tests node 24 2/8 — not this PR. ReferenceError: window is not defined from React's scheduler firing after environment teardown, attributed to AiVaultSessionSubagents.test.tsx — a file this PR does not touch and which imports nothing from the diff. Its afterEach calls document.body.replaceChildren() without unmounting the React roots, a pattern shared by ~138 files in this repo. Timing-dependent; did not reproduce locally. The PR changes shard composition by adding test files, which is what surfaced it.
  3. verify — pure downstream noise. Its step dump shows every other job success/skipped and only test: expected success, got failure.

Defects found by review and fixed

  • Failed structured publish latched as owned. StructuredAgentSessionStatusOwnership.publish recorded the owner before calling the sink. A throwing publish therefore left matchesLocation reporting an owned location for a row that was never written, and the unchanged-projection path — the only thing that re-offers it — stopped. The row stayed absent with nothing re-deriving it. The address still has to survive a throw so teardown can forget a row that did land (an observer can throw after the write), so the two facts are now separate: the address is recorded up front, and only a publish that returned marks the row landed. Pinned by a new test; ablating the landed check reddens it.
  • combinedStatusEntries() sorted unordered rows first. It defaulted a missing listing order to 0 while the counter it compares against starts at 1, so any unordered row sorted above every ordered one. Now sorts last via an explicit sentinel.
  • Orphaned module. agent-status-store-snapshot-budget.ts lost its only caller when the store switched to agentStatusStoreFitsByteBudget; nothing in the repo imported it. Deleted. (The replacement is not a straight copy — it only memoises a record's size once the record is frozen, so a still-mutable record can no longer return a stale byte count.)
  • Dead predicate. persistedStructuredWorkerPaneKeyIsValid repeated its public-pane-key rejection verbatim three lines below the first one. The two tests covering that rejection pass on the first occurrence alone. Removed.
  • Reopen test claimed a mechanism it cannot distinguish. Its comment attributed the fencing to the revision envelope rather than the tombstone. Measured: transport consecutiveness, the parent-revision validator and the tombstone guard each refuse that replay alone, and ablating any two leaves the test green. It now asserts the outcome and says plainly that it does not attribute the layer. Note for the record: commit 8ef5feb112's message overclaims that test as "pinning" behaviour — left as-is rather than rebasing.

What I verified held

  • Nothing disappears during the dual-source window. The legacy adapter refuses any entry with structuredHost defined and any pane key already in canonicalSubjectsByPane, so a pane cannot be in both sources; combinedStatusEntries() concatenates and sorts without needing a dedupe pass, and getStatusSnapshotForPane falls back legacy→canonical. Persisted structured rows do not exist to be lost on upgrade — the serializer drops rows carrying structuredHost and the validator rejects them.
  • Legacy row order is preserved, by a changed mechanism. At merge-base getLegacyStatusListingOrder had zero production consumers; readers used map insertion order. Both changed lines (moveToEnd bumping the number, move() taking a fresh order) are faithful ports of end-placement into the new numerically-sorted read path.
  • Child lifetimes are genuinely fenced. Alias keys became binding keys carrying (childWorkId, invocationId, generation), so invocations no longer collide on one key; resumeAgentChildWork removes bindings outside the bounded retained-fence set. The settled-membership latch has an explicit way to die — a higher generation supersedes it.
  • The legacy-ingress ratchet is real. It asserts the production caller set equals the manifest in both directions, forbids indirect and mutable-map bypasses, and self-tests its own detector with planted bypasses. Required vitest suite, not e2e.
  • SSH/WSL scope is honest. Subjects are built from the session record's real AgentSessionExecutionLocation; hasExactKeys means an under-specified location cannot pass as a subject. worktree-subagent-child-rows.ts now reports a stale parent's children as unverifiable instead of idle — that moves toward the execution-boundary vocabulary, replacing a claim that the agent was not working with an honest "cannot verify".

Residual risk, not fixed here

  • main is red, and that is what keeps this PR red. origin/main at 15cac6880236 fails both pnpm tc (TS6196) and oxlint on NativeChatMessageList.windowing.test.tsx:12 — an unused NativeChatMessage import from Native chat keeps scrolling to bottom #20898. Verified in isolation on a clean origin/main checkout. This PR's merged tree has no other typecheck error. typecheck and static analysis will clear on their own once main is fixed; nothing on this branch can fix them.
  • N-subjects-per-pane-key is a latent shape. The store deliberately allows it, and the PR tests 7 subjects on one pane key. Proved unreachable in production: one ownership map per process, and it forgets the previous subject before publishing a scope change. Every per-pane consumer iterates properly. But runtime-worktree-pty-agent-sources.ts collapses last-wins, so if it ever became reachable the symptom would be a silently arbitrary row, not a visible duplicate. The one-subject-per-pane-key invariant currently lives only in the feed's bookkeeping, not at the store boundary — worth stating for stage 3.
  • Over-guarding around reopen. Three independent layers enforce the same tombstone-vs-parent revision property, so no behaviour-level test can attribute or even detect the loss of two of them. Follow-up, and it overlaps fix(agent-status): one revision rule for every teardown marker #20967.
  • MAX_TOMBSTONE_KEY_LENGTH 4096 → 32768 is needed for binding-shaped keys and is safe today because nothing replicates this store yet (applySnapshot/applyTransportEnvelope have no production caller). It becomes a wire-compatibility question the moment 2B turns replication on: an older peer parsing at 4096 would reject a snapshot carrying a binding tombstone.
  • The ratchet's passed-map bypass detector is not individually pinned (two producing sites collapse into one deduplicated kind label). Dashboard pop-out shows no native-chat sessions because popout.tsx never mounts AppBackgroundServices — pre-existing, unrelated.

Gates at 6185d0623b

Gate Result
pnpm tc only main's pre-existing TS6196; no other error
pnpm run audit:anti-slop exit 0
pnpm run check:code-quality:changed 0 new findings across 53 files
npx oxfmt --check (6 touched files) clean, re-run after commit
src/shared/agent-status 245 passed, 1 expected fail
src/main/agent-hooks/ 88 files, 918 passed, 9 skipped
ssh agent-hooks integration 10/10
native-chat + ssh + identity 616 passed

Merged origin/main rather than rebasing; merge commit verified to have two parents.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

Incremental delta since the prior pullfrog review (0f5db831a0 → 6185d0623b), two commits:

  • A failed structured publish no longer latches as owned — StructuredAgentSessionStatusOwnership now tracks a separate landed set beside the retained address: the address is still recorded before the sink runs so teardown can forget a row that did land, but only a publish that returned marks it landed, so matchesLocation no longer suppresses the feed's unchanged-projection re-offer after a throw. The added test fails against the prior code (matchesLocation returned true after the throwing publish).
  • An unordered listing row now sorts last — combinedStatusEntries() defaulted a missing listing order to 0, but the shared counter starts at 1, so such a row sorted above every ordered one; the legacy and canonical defaults now share a Number.MAX_SAFE_INTEGER sentinel.
  • Reopen test asserts outcomes only — agent-status-store-reopen.test.ts no longer claims the revision envelope (rather than the tombstone) fences a stale replay; it verifies the spent replay is refused and a resequenced one is accepted, with a comment recording that transport consecutiveness, the parent-revision validator, and the tombstone guard each refuse it independently.
  • Merged origin/main — the base-side merge diff touches no PR file, so no conflict resolution was carried; the sync brought unrelated native-chat changes (structured-agent-session-host-handoff.ts, journal-store.ts, structured-agent-session-turns.ts) with no overlap.

Both prior Pullfrog inline threads are resolved and untouched by this delta. Focused suites (structured-agent-session-status-ownership 5, agent-status-store-reopen 2, server-structured-canonical-status 8) are green and pnpm tc:node is clean.

Pullfrog  | View workflow run | Using DeepSeek Flash (free via Pullfrog for OSS) | 𝕏

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🧹 Nitpick comments (1)
src/shared/agent-status-legacy-adapter.test.ts (1)

36-36: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Exercise the canonical-pane-key rejection branch.

canonicalPaneKeys is empty here. This input can be rejected only because it has structuredHost. Add a separate case that inserts 'structured-pane' into canonicalPaneKeys and admits a non-structured payload. The current assertion cannot detect a regression in isCanonicalPaneKey.

Based on learnings: a negative result alone does not show that the intended conditional branch ran.

Source: Learnings


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Advanced

Run ID: e2339122-00f6-4165-9206-153b6dc81274

📥 Commits

Reviewing files that changed from the base of the PR and between 0f5db83 and 6185d06.

📒 Files selected for processing (55)
  • docs/reference/agent-status-store.md
  • src/main/agent-hooks/first-work-branch-rename.test.ts
  • src/main/agent-hooks/server-ingest-structured-status.test.ts
  • src/main/agent-hooks/server-structured-canonical-status.test.ts
  • src/main/agent-hooks/server.ts
  • src/main/agent-hooks/server/server-ingest-structured.ts
  • src/main/agent-hooks/server/server-lifecycle.ts
  • src/main/agent-hooks/server/server-listeners.ts
  • src/main/agent-hooks/server/server-state.ts
  • src/main/agent-hooks/server/server-status-inference.ts
  • src/main/agent-hooks/server/server-status-retries.ts
  • src/main/agent-hooks/server/server-status-update.ts
  • src/main/agent-hooks/server/server-structured-status-row.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-forget-status.test.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-feed-test-session.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-feed.test.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-feed.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-ownership.test.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-ownership.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-status-reentry.test.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-subscribers.test.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-surface-lifetime.test.ts
  • src/main/orcad/orcad-entry.ts
  • src/main/runtime/orca-runtime-tests/worktree-ps-structured-host.spec.ts
  • src/main/runtime/rpc/methods/structured-agent-session-rpc.test-fixture.ts
  • src/main/runtime/runtime-worktree-agent-rows-structured.test.ts
  • src/main/runtime/runtime-worktree-structured-agent-rows-liveness.test.ts
  • src/main/runtime/structured-worker-identity.test.ts
  • src/main/startup/main-process-runtime-service.ts
  • src/relay/agent-status-store-relay-context.test.ts
  • src/renderer/src/components/native-chat/StructuredAgentSessionStatusBridge.test.tsx
  • src/renderer/src/components/sidebar/useWorktreeAgentRows.test.ts
  • src/renderer/src/components/sidebar/worktree-subagent-child-rows.test.ts
  • src/renderer/src/components/sidebar/worktree-subagent-child-rows.ts
  • src/shared/agent-hook-listener/listener-state.ts
  • src/shared/agent-status-child-work-admission-core.ts
  • src/shared/agent-status-child-work-admission-operations.ts
  • src/shared/agent-status-child-work-admission.ts
  • src/shared/agent-status-child-work-binding.ts
  • src/shared/agent-status-child-work-freshness.ts
  • src/shared/agent-status-child-work-lifetime.test.ts
  • src/shared/agent-status-child-work-projection.test.ts
  • src/shared/agent-status-child-work-resume.ts
  • src/shared/agent-status-legacy-adapter.test.ts
  • src/shared/agent-status-legacy-adapter.ts
  • src/shared/agent-status-store-byte-budget.test.ts
  • src/shared/agent-status-store-byte-budget.ts
  • src/shared/agent-status-store-child-queries.ts
  • src/shared/agent-status-store-codec.ts
  • src/shared/agent-status-store-mutation.ts
  • src/shared/agent-status-store-persistence.ts
  • src/shared/agent-status-store-reopen.test.ts
  • src/shared/agent-status-store-snapshot-budget.ts
  • src/shared/agent-status-store-state.ts
  • src/shared/agent-status-store.ts
💤 Files with no reviewable changes (1)
  • src/shared/agent-status-store-snapshot-budget.ts
🚧 Files skipped from review as they are similar to previous changes (3)
  • docs/reference/agent-status-store.md
  • src/shared/agent-status-child-work-admission.ts
  • src/main/native-chat/agent-session-wire/structured-agent-session-subscribers.test.ts

Included review availability: Your plan provides up to 10 included reviews per hour; 8 remain after this review.

Comment on lines +122 to +124
this.commitStatusRowMutation(structuredStatusLegacyEvent(previous.status), undefined)
this.notifyStatusChangeListeners()
this.emitStatusDropped(previous.status.paneKey)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗄️ Data Integrity & Integration | 🟠 Major | 🏗️ Heavy lift

Do not publish a pane deletion while another canonical subject remains.

Different execution scopes can produce the same paneKey for an identical session ID. After this method removes one subject, canonicalSubjectsByPane can still contain another subject for that pane.

The current code still publishes before → undefined and calls emitStatusDropped. Consumers can remove pane or child state even though getStatusSnapshotForPane still returns a surviving canonical row.

If subjects remain, publish the selected surviving row instead. Call emitStatusDropped only when the pane has no remaining subjects.

parentEvidenceFresh: args.parentIsFresh,
transportObservation: args.parentEntry.subagentObservation ?? 'live'
})
const state = freshness === 'done' ? 'idle' : freshness === 'monitoring' ? 'working' : freshness

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Preserve the done state.

When resolveAgentChildWorkFreshness returns done, this conversion changes the dashboard row to idle. A completed child then appears idle instead of completed.

Only convert monitoring to working. Add a done case to worktree-subagent-child-rows.test.ts.

Proposed fix
-    const state = freshness === 'done' ? 'idle' : freshness === 'monitoring' ? 'working' : freshness
+    const state = freshness === 'monitoring' ? 'working' : freshness
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
const state = freshness === 'done' ? 'idle' : freshness === 'monitoring' ? 'working' : freshness
const state = freshness === 'monitoring' ? 'working' : freshness

} else if (sourceOrder !== undefined) {
listingOrderByPaneKey.set(movedKey, sourceOrder)
} else {
listingOrderByPaneKey.set(movedKey, nextListingOrder())

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Validate the generated moved-entry order.

move stores nextListingOrder() without the validation used by admit. If the configured callback returns a negative, unsafe, or non-integer value, listingOrder exposes invalid state instead of throwing.

Proposed fix
         } else {
-          listingOrderByPaneKey.set(movedKey, nextListingOrder())
+          const order = nextListingOrder()
+          if (!Number.isSafeInteger(order) || order < 0) {
+            throw new RangeError(
+              'Legacy agent-status listing order must be a non-negative safe integer'
+            )
+          }
+          listingOrderByPaneKey.set(movedKey, order)
         }

}
state.aliases.set(
serializeAgentChildWorkAliasKey(record),
serializeAgentChildWorkBindingKey(record),

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | 🏗️ Heavy lift

Align getAlias with the binding-key map.

This change stores aliases under serializeAgentChildWorkBindingKey(record). getAlias in src/shared/agent-status-store.ts Line 94 still looks up serializeAgentChildWorkAliasKey(identity). Valid stored aliases therefore return null through the existing API.

Move callers to resolveChildAliases, or change the getAlias contract and lookup to use the binding-key identity.

@brennanb2025
brennanb2025 merged commit 291b4dd into main Sep 16, 2026
31 of 34 checks passed
ivanvykopal pushed a commit to ivanvykopal/orca that referenced this pull request Sep 20, 2026
…ship (stablyai#20718)

* feat(agent-status): route structured status through canonical ownership and fence child lifetimes

Restacked onto the canonical store and child-work contract. Completing that
restack drops the `reopenStructuredParent` mutation flag this change had
carried, along with its contract field, its codec branch, and its single
call site in structured ingest, which passed a hardcoded `true`.

The flag was a narrow escape hatch from the absolute `tombstones.has(...)`
rule that governed parent upserts in this branch's original base. The
canonical store replaces that rule with a revision envelope, because a
bounded store compacts tombstones away and a presence-based guard silently
stops fencing once one is evicted. With the envelope deciding the outcome,
the escape hatch has nothing left to escape from, so removing it changes no
production behaviour.

`agent-status-store-reopen.test.ts` is rewritten against the envelope: the
reopen case now pins that an unflagged republication succeeds while replay
from before the reopen stays fenced even after the parent tombstone is
compacted away, and the second case pins where the guard genuinely bites —
a republication inside the removing mutation itself, for every subject kind.

* fix(agent-status): re-admit unchanged structured owners after teardown

* fix(agent-status): clear anti-slop object-param and Reflect.apply findings

- agent-status-store-byte-budget.ts: type the byte-budget helper's
  record parameter as the union of what its call sites actually pass
  (the snapshot header plus each store entity record) instead of the
  broad `object`.
- server-structured-canonical-status.test.ts: replace `Reflect.apply`
  with a typed, explicitly-bound call that models a caller at an
  untyped boundary omitting the trusted owner subject.

* docs(agent-status): drop the 2A progress doc from docs/reference

docs/reference/ holds implementation detail, not rollout progress. The
canonical-boundary notes move to the effort's working directory; the
agent-status-store status section keeps the boundary statement and loses
the now-dangling link.

* fix(agent-status): mint the canonical epoch on first use, not at construction

The hook server's canonical store was built in an instance-member initializer, so
constructing AgentHookServer — which happens at import time for the module
singleton — demanded a live randomUUID. Any importer that stubs node:crypto threw
'Invalid agent status store epoch' before a single test ran.

The store is now created on first canonical access and reset by dropping it, so
construction owes nothing to a crypto implementation and the epoch still rotates
per authority incarnation.

* fix(agent-status): drop the orphaned snapshot budget and a duplicated pane guard

Two leftovers from the canonical-store routing change:

agent-status-store-snapshot-budget.ts lost its only caller when the store state
switched to agentStatusStoreFitsByteBudget. Nothing in the repo imports it now,
so the module goes with the caller it existed for. The replacement is not a
straight copy: it only memoises a record's measured size once the record is
frozen, so a still-mutable record can no longer return a stale byte count.

persistedStructuredWorkerPaneKeyIsValid repeated its public-pane-key rejection
verbatim three lines below the first one. The tests covering that rejection pass
on the first occurrence alone, so the second decided nothing and only obscured
which predicate was load-bearing.

* fix(agent-status): stop a failed structured publish from latching as owned

Three defects found reviewing the structured routing path.

combinedStatusEntries defaulted a missing listing order to 0, but the counter it
compares against starts at 1, so any unordered row sorted above every ordered
one. Unknown order now sorts last.

The owner map recorded a session as owned before the sink ran. A publish that
threw therefore left matchesLocation reporting an owned location for a row that
was never written, and the unchanged-projection path — the only thing that would
re-offer it — stopped. The address still has to survive a throw so teardown can
forget a row that did land, so the two facts are now separate: the address is
recorded up front, and only a publish that returned marks the row as landed.

The reopen test claimed the revision envelope rather than the tombstone fences a
stale replay. It cannot tell: transport consecutiveness, the parent-revision
validator and the tombstone guard each refuse that replay alone, and ablating any
two leaves the test green. It now asserts the outcome and says so.
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