Repository navigation
Description
Part of #3596. Confirmed against main c5071f7 during the final combined epic review.
createSafetyClient (packages/ui-react/src/lib/safety-client.ts:51) retries gap, expiry and generation changes, but excludes capacity. When a subscription delta exceeds 100 records, the host drops it with capacity; selected-chat evidence is cleared and never reloaded until reselection or reconnect.
The existing contract (docs/integration-contract/wire.md:3295-3298, plus the bounded history section of docs/plans/reviewable-session-safety.md and docs/decisions/session-safety-reviews.md) requires a fresh snapshot for oversized deltas. This is restoration of existing behavior, with no wire change.
Acceptance criteria:
- Capacity subscription loss starts a fresh read for the selected target with a new request ID and no cursor.
- Recovery assembles all snapshot pages and subscribes at the final high-water; stale pages cannot settle the new read and partial evidence cannot restore normal policy.
- Consecutive capacity refusals permit at most one automatic recovery until valid advancing subscription progress or explicit refresh, reselection or reconnect; snapshot completion and duplicate updates do not rearm the bound.
- A failing-first client test and restored mutation demonstrate the recovery, retaining existing gap/expiry/generation recovery and terminal refusal behavior.
2026-11-20: independent PR review identified repeated subscribe-capacity refusal as the same recovery defect class; bounded recovery is included in scope.
Activity
schlessera commentedon Nov 20, 2026
Claim: safety-review-20261120, branch
fix/safety-review-findings-20261120. Dedicated checkout starts at main c5071f7. Failing-first client test confirmsSUBSCRIPTION_LOSS_REQUESTS_FRESH_SNAPSHOTreceives undefined for capacity (8 pass, 1 fail). Collision inspection reports shared proof closures with concurrent PRs; no ownership takeover is intended. Will repair this with the sibling indicator defect in one small UI fix PR.schlessera commentedon Nov 20, 2026
Implemented fresh paginated snapshot recovery for capacity subscription loss, with a new request ID and final subscription watermark. Capacity during an actual page read remains terminal to avoid a retry loop. Failing-first: 8 pass/1 fail at
SUBSCRIPTION_LOSS_REQUESTS_FRESH_SNAPSHOT. Removing the fix again gives 11 pass/1 fail at that same assertion; restored focused client run passes all 12. Existing gap/expiry/generation recovery and read-refusal checks are retained. PR and complete qualification follow.schlessera commentedon Nov 20, 2026
Delivered by PR #4269, squash
63bb400b31403ee319926d38e223711a9bf0e7e1on main, milestone 0.45.0. Failing-first and restored mutation receipts, 28 focused safety tests, 11 pinned browser tests, build, strict typecheck and current-candidate preflight passed. Independent review returned no findings; the clean base merge preserved that review. Candidate run https://github.com/schlessera/brain-kit/actions/runs/44764503535 and automatic-main run https://github.com/schlessera/brain-kit/actions/runs/44767813281 passed. Main qualification audited all nine selected categories and all 17 successful job checkouts at the exact squash, whose parent/tree match the tested candidate. Main attempt 1 had a registry reset before endurance tests; one documented infrastructure retry passed. Operational incident #4272 separately awaits a subsequent inclusive plan for its controller marker; no implementation remains here. Epic #3596 is intentionally open for follow-up review.