Repository navigation
fix: preserve approval and workspace state after lost worker replies - #168094
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
|
Codex review: needs real behavior proof before merge. What this changesThis PR publishes committed approval and workspace state before worker replies arrive and recovers lost replies from the actual committed rows. Example: A local workspace update commits pending_ref="refs/openclaw/results/accepted", but its worker reply is lost.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Blocked before merge - 4 items remain This PR addresses a concrete state-recovery defect still present on current main; the earlier wrapper-inventory finding is fixed, and no additional discrete code defect was identified. Priority: P2 Before merge
Findings
Tests
Agent review detailsHow this fits togetherGateway storage owners send mutations to SQLite workers and receive commit receipts that update local projections consumed by approval, dispatch, and workspace operations. flowchart LR
A[Gateway storage owners] --> B[SQLite worker admission]
B --> C[Native transaction]
C --> D[Commit receipt]
D --> E[Owner projections]
E --> F[Authority checks and observers]
Technical reviewBest possible solution: Retain native committed postimages and existing final authority guards, with the authority-boundary and upgrade checks completed before landing. Do we have a high-confidence way to reproduce the issue? Current main reconstructs lost-reply recovery state from caller fields, and the changed regression supplies stale fields that differ from the committed row; this review ran no target code. Is this the best way to solve the issue? Capturing exact postimages at the existing mutation owner fixes the stale-state producer while preserving the no-replay contract and existing authority guards. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 430f975aacee. Merge-risk optionsMaintainer options:
Provenance checked
TestingProof path: in-process harness. SecurityNeeds attention: No concrete authorization bypass was found, but the changed publication timing still needs final-effect authority validation. EvidenceSecurity concerns:
What I checked:
Likely related people:
PR surfaceSource +1378, Tests +601, Docs +36, Other +1. Total +2016 across 69 files. Added test files: 2. View PR surface stats
LabelsLabel changes:
Label justifications:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment HistoryReviewed October 9, 2026, 11:01 PM ET / October 10, 2026, 03:01 UTC (Revision 3). |
Resolve publication-helper overlap by retaining batch installation and main's shared state adapter. Regenerate the database worker inventory. Validation: SQLite post-commit owner tests pass.
Include the placement receipt module in the native wrapper closure, resolve publication row types from the generated database contract, and retain admission in the authorization reducer fixture. Policy and deletion assertions are unchanged. Validation: authorization worker 3/3 (27.50s wall), wrapper closure 17/17 (30.69s wall), scoped P0/P1 autoreview clean. Remote architecture and published-driver update proof follow on this head.
|
Merged via squash.
|
…penclaw#168094) * fix(sqlite): publish approval and workspace commit facts * fix: close approval receipt cutover validation gaps Include the placement receipt module in the native wrapper closure, resolve publication row types from the generated database contract, and retain admission in the authorization reducer fixture. Policy and deletion assertions are unchanged. Validation: authorization worker 3/3 (27.50s wall), wrapper closure 17/17 (30.69s wall), scoped P0/P1 autoreview clean. Remote architecture and published-driver update proof follow on this head.
…ply text (wave-4 bundle) (#172669) * refactor(infra): remove redundant replay and freshness machinery Trust successful migration statements inside their synchronous transactions, reuse unchanged approval parses, share canonical package-root discovery, namespace directory caches by plugin identity, and simplify ephemeral presence, OS facts and suspension timer bookkeeping. Keep source validation, conflicts, transaction durability, postcommit checks, security authority and write settlement. Best-effort tradeoffs accepted - Node-host own-write verification (#108457): no human successful-SQL-loss report; SQL errors still roll back, and independent source retirement checks remain. - Workspace setup/attestation replay (#109147): no human driver-rewrite report; trust successful writes while retaining fingerprints and later source checks. - APNs expected-ID replay (#108543): no human silent-insert-loss report; canonical parsing, tombstones and receipts remain. - Device-auth presence assertion (#112663): no human successful-upsert-loss report; credential validation and transaction failure handling remain. - Device-identity replay (#110392): no human silent-row-rewrite report; preserve independent post-await verification before source deletion. - MCP OAuth replay (#161219): no human silent-write-loss report; canonical/source parsing and worker admission remain. - Exec-approval read/parse/deep-compare replay (#114063): no human successful-driver-rewrite report; malformed policy stays fail-closed and actual authority is unchanged. - Shared-auth target reread (#123349): no human silent-row-rewrite report; return the known SQL postimage and keep independent copy/flip/cleanup checks. - Identical authored approval bytes (#168094) reuse the existing parse; changed normalized bytes still parse before publication. - Plugin metadata fingerprinting (353d778): no human in-place metadata-mutation report; distinct objects remain isolated, and same-object edits use TTL/reset. - Duplicate asset ancestor search (7224585): no human cached-miss incident; canonical realpath/wrapper discovery remains, while newly appearing packages need owner invalidation/restart. - Presence logical clock (#134737): provenance is synthetic rollback/suspend tests; clock correction may temporarily retain or hide display rows until full update/reconnect, wall time catches up, or restart. TTL, capacity and connection privacy remain. - Suspension timer generation (#130003): the removed test directly called a canceled callback; native timer cancellation and current-entry authority remain. An out-of-contract timer implementation could resume a renewed lease early. - OS tuple-keyed cache (#135911): keep measured probe sharing and sticky labels; hot-patching OS identity needs restart rather than another namespace. - Presence list type guards (409a160): callers supply validated arrays; existing normalization still owns their values. Production +40/-228, net -188. Focused migration, asset/cache, presence/caller, approval-publication and suspension/OS tests pass, as do production and infra-test types, changed-file lint, assertion and suppression checks, and zero-cycle checks. Independent final review has no actionable P0-P2 findings. No schema, durability, retention, indexing, permission, recovery or public SDK change is intended. Broad changed-check is not claimed green: the original base reproduces the 455-versus-454 environment budget failure. The initial Web Push Doctor timeout remains unattributed; all Web Push production hunks were dropped and its exact test passed on restored source. Full build and hosted CI remain unrun. * refactor(agents): simplify reply preparation and refresh bookkeeping Share typed actor-store adapters and prepared async auth reads. Reuse the admitted memory-flush plan, retain last-good catalog views by provider, and remove unused metadata bookkeeping and config projections. Preserve live credential/effect authority, FIFO, transcript durability, and ordinary write settlement. Net production reduction: 303 lines. Best-effort tradeoffs accepted: - Plugin-drain successors (#162301, synthetic): wait the current drain once; a later reload owns its own publication and recovery. - A changed memory-flush plan during preparation (#162177/#121157, synthetic): finish with the admitted plan; the next turn resolves again. - Per-row catalog freshness (#158113, synthetic): failed discovery retains the provider's last-good configured and supplemental overlays until success. Existing auth/profile/source gates and successful-empty replacement remain. - MCP sibling invalidation during discovery (#138694, synthetic): a listing may briefly be stale; the next read observes the invalidation. - Passive context metadata supersession (#119607, synthetic): late discovered metadata may win until refresh. Keep the single current-promise check before replacing configured limits, preserving the human capacity fix (#39857). - Registration-time question answers (#110372/#134003, synthetic): a prompt can briefly race the answer; its terminal signal closes delivery. - Duplicate or never-attached internal question registrations: both real producers attach once synchronously. Unsupported misuse loses its extra diagnostic/disposal wakeup; ordinary lifecycle rejection remains. - Cancellation publication once/must-consume flags (#161124, synthetic): the sole internal producer invokes once. Keep active-scope/effect authority. - In-flight placement-service replacement (#164744, synthetic): use the captured startup service, with its observation and writer authority intact. - Compaction callback rebinding (#146732/#163264, synthetic): current work retains its captured callbacks and live assertion; later work captures anew. - Re-entrant logging between synchronous run-owner checks: #162227 removed the awaited retry, making the second check redundant. Real post-await and mutation-effect checks remain. - Startup diagnostic admission (#146792): the sole producer checks lifecycle immediately before recording. Remove only the recorder's duplicate check; preserve the human abort/recovery fix (#146692), reset, and admin redaction. Release-note context: verbose diagnostics no longer include suppressed reply text or background bash command contents. Execution and user replies remain unchanged. Config show uses the same schema-aware redactor without cloning an already detached result or redacting unused snapshot views. Validation: touched core, messaging and Gateway-method type graphs passed; 49 changed TypeScript files passed targeted lint/format; runtime and Madge cycles are both zero. Auth reader, question authority, memory flush, restart claim, catalog worker, cancellation and compaction boundary proof is recorded in the lane ledger. Final supplemental run: 392 tests passed, four failed across 28 files, with final source verification. All 120 agents-support tests passed, including refresh coalescing, publication, run-wait and compaction. The four failures were an unchanged 120s ACP reset deadline and three MCP fixtures settling before child startup markers (empty logs, existing 1-2s connection/4s catalog deadlines). Narrow failed-case replay passed ACP reset and two MCP cases; the one-second MCP retirement fixture still failed before its first child marker. Clean lane-base comparison could not reach assertions: the temporary checkout lacked workspace-local dependency links for worker compilation. That case is unresolved, not proven inherited; coordinator-bundle CI must adjudicate it. No deadline, retry, skip or assertion was weakened. The final selected real-dispatch suppressed-reply logging regression passed with completed source verification (one selected case, 202.58s wrapper). Independent P0-P2 review completed four passes. Declined duplicate findings about unsupported placement-service hot-swap (real observation/database/writer authority remains) and alleged run-wait awaits (only synchronous logging lies between the checks; real mutation and post-await checks remain). Broad check-changed is NOT green: env-name budget 455/454 also fails on the unchanged lane-base index, with no added env names; production/full-tree Knip hit their existing 600s budget; the silent legacy-store scan was interrupted after 782s. Those two scans are missing proof, not attributed inherited reds. Hosted coordinator-bundle CI remains the broad gate. Owned mock/type/legacy fixture findings were corrected and their targeted replays pass. No changelog, dependency, database schema, durability, retention, permission, or public API change is included. BELOW-500 branch-only coordinator handoff; no lane PR or merge. * chore: shrink stale reply assertion allowance * test: align catalog publication calls with current contract
…ply text (wave-4 bundle) (openclaw#172669) * refactor(infra): remove redundant replay and freshness machinery Trust successful migration statements inside their synchronous transactions, reuse unchanged approval parses, share canonical package-root discovery, namespace directory caches by plugin identity, and simplify ephemeral presence, OS facts and suspension timer bookkeeping. Keep source validation, conflicts, transaction durability, postcommit checks, security authority and write settlement. Best-effort tradeoffs accepted - Node-host own-write verification (openclaw#108457): no human successful-SQL-loss report; SQL errors still roll back, and independent source retirement checks remain. - Workspace setup/attestation replay (openclaw#109147): no human driver-rewrite report; trust successful writes while retaining fingerprints and later source checks. - APNs expected-ID replay (openclaw#108543): no human silent-insert-loss report; canonical parsing, tombstones and receipts remain. - Device-auth presence assertion (openclaw#112663): no human successful-upsert-loss report; credential validation and transaction failure handling remain. - Device-identity replay (openclaw#110392): no human silent-row-rewrite report; preserve independent post-await verification before source deletion. - MCP OAuth replay (openclaw#161219): no human silent-write-loss report; canonical/source parsing and worker admission remain. - Exec-approval read/parse/deep-compare replay (openclaw#114063): no human successful-driver-rewrite report; malformed policy stays fail-closed and actual authority is unchanged. - Shared-auth target reread (openclaw#123349): no human silent-row-rewrite report; return the known SQL postimage and keep independent copy/flip/cleanup checks. - Identical authored approval bytes (openclaw#168094) reuse the existing parse; changed normalized bytes still parse before publication. - Plugin metadata fingerprinting (f31bc71): no human in-place metadata-mutation report; distinct objects remain isolated, and same-object edits use TTL/reset. - Duplicate asset ancestor search (40fb74f): no human cached-miss incident; canonical realpath/wrapper discovery remains, while newly appearing packages need owner invalidation/restart. - Presence logical clock (openclaw#134737): provenance is synthetic rollback/suspend tests; clock correction may temporarily retain or hide display rows until full update/reconnect, wall time catches up, or restart. TTL, capacity and connection privacy remain. - Suspension timer generation (openclaw#130003): the removed test directly called a canceled callback; native timer cancellation and current-entry authority remain. An out-of-contract timer implementation could resume a renewed lease early. - OS tuple-keyed cache (openclaw#135911): keep measured probe sharing and sticky labels; hot-patching OS identity needs restart rather than another namespace. - Presence list type guards (3965f6b): callers supply validated arrays; existing normalization still owns their values. Production +40/-228, net -188. Focused migration, asset/cache, presence/caller, approval-publication and suspension/OS tests pass, as do production and infra-test types, changed-file lint, assertion and suppression checks, and zero-cycle checks. Independent final review has no actionable P0-P2 findings. No schema, durability, retention, indexing, permission, recovery or public SDK change is intended. Broad changed-check is not claimed green: the original base reproduces the 455-versus-454 environment budget failure. The initial Web Push Doctor timeout remains unattributed; all Web Push production hunks were dropped and its exact test passed on restored source. Full build and hosted CI remain unrun. * refactor(agents): simplify reply preparation and refresh bookkeeping Share typed actor-store adapters and prepared async auth reads. Reuse the admitted memory-flush plan, retain last-good catalog views by provider, and remove unused metadata bookkeeping and config projections. Preserve live credential/effect authority, FIFO, transcript durability, and ordinary write settlement. Net production reduction: 303 lines. Best-effort tradeoffs accepted: - Plugin-drain successors (openclaw#162301, synthetic): wait the current drain once; a later reload owns its own publication and recovery. - A changed memory-flush plan during preparation (openclaw#162177/openclaw#121157, synthetic): finish with the admitted plan; the next turn resolves again. - Per-row catalog freshness (openclaw#158113, synthetic): failed discovery retains the provider's last-good configured and supplemental overlays until success. Existing auth/profile/source gates and successful-empty replacement remain. - MCP sibling invalidation during discovery (openclaw#138694, synthetic): a listing may briefly be stale; the next read observes the invalidation. - Passive context metadata supersession (openclaw#119607, synthetic): late discovered metadata may win until refresh. Keep the single current-promise check before replacing configured limits, preserving the human capacity fix (openclaw#39857). - Registration-time question answers (openclaw#110372/openclaw#134003, synthetic): a prompt can briefly race the answer; its terminal signal closes delivery. - Duplicate or never-attached internal question registrations: both real producers attach once synchronously. Unsupported misuse loses its extra diagnostic/disposal wakeup; ordinary lifecycle rejection remains. - Cancellation publication once/must-consume flags (openclaw#161124, synthetic): the sole internal producer invokes once. Keep active-scope/effect authority. - In-flight placement-service replacement (openclaw#164744, synthetic): use the captured startup service, with its observation and writer authority intact. - Compaction callback rebinding (openclaw#146732/openclaw#163264, synthetic): current work retains its captured callbacks and live assertion; later work captures anew. - Re-entrant logging between synchronous run-owner checks: openclaw#162227 removed the awaited retry, making the second check redundant. Real post-await and mutation-effect checks remain. - Startup diagnostic admission (openclaw#146792): the sole producer checks lifecycle immediately before recording. Remove only the recorder's duplicate check; preserve the human abort/recovery fix (openclaw#146692), reset, and admin redaction. Release-note context: verbose diagnostics no longer include suppressed reply text or background bash command contents. Execution and user replies remain unchanged. Config show uses the same schema-aware redactor without cloning an already detached result or redacting unused snapshot views. Validation: touched core, messaging and Gateway-method type graphs passed; 49 changed TypeScript files passed targeted lint/format; runtime and Madge cycles are both zero. Auth reader, question authority, memory flush, restart claim, catalog worker, cancellation and compaction boundary proof is recorded in the lane ledger. Final supplemental run: 392 tests passed, four failed across 28 files, with final source verification. All 120 agents-support tests passed, including refresh coalescing, publication, run-wait and compaction. The four failures were an unchanged 120s ACP reset deadline and three MCP fixtures settling before child startup markers (empty logs, existing 1-2s connection/4s catalog deadlines). Narrow failed-case replay passed ACP reset and two MCP cases; the one-second MCP retirement fixture still failed before its first child marker. Clean lane-base comparison could not reach assertions: the temporary checkout lacked workspace-local dependency links for worker compilation. That case is unresolved, not proven inherited; coordinator-bundle CI must adjudicate it. No deadline, retry, skip or assertion was weakened. The final selected real-dispatch suppressed-reply logging regression passed with completed source verification (one selected case, 202.58s wrapper). Independent P0-P2 review completed four passes. Declined duplicate findings about unsupported placement-service hot-swap (real observation/database/writer authority remains) and alleged run-wait awaits (only synchronous logging lies between the checks; real mutation and post-await checks remain). Broad check-changed is NOT green: env-name budget 455/454 also fails on the unchanged lane-base index, with no added env names; production/full-tree Knip hit their existing 600s budget; the silent legacy-store scan was interrupted after 782s. Those two scans are missing proof, not attributed inherited reds. Hosted coordinator-bundle CI remains the broad gate. Owned mock/type/legacy fixture findings were corrected and their targeted replays pass. No changelog, dependency, database schema, durability, retention, permission, or public API change is included. BELOW-500 branch-only coordinator handoff; no lane PR or merge. * chore: shrink stale reply assertion allowance * test: align catalog publication calls with current contract
What Problem This Solves
Managed approval, placement, and workspace writers do not consistently publish their committed facts before completion. Some wait for an ordinary worker reply, and local workspace recovery reconstructs a row from the caller's stale snapshot after that reply is lost.
User Impact
Committed local workspace state now survives reply loss without adopting stale caller fields. Approval, environment, placement, and workspace owners receive exact committed facts through their existing publication boundaries. Final authority guards remain in place; this does not make incomplete writer families eligible for guard removal.
Schemas, stored bytes, permissions, retention, and released synchronous SDK completion contracts are unchanged. The published-driver × candidate update cell passed on the final head before merge.
Why This Change Was Made
This is the approval/exec and placement/environment/workspace portion of S4, using the merged receipt contract from #167570. Native kernels capture postimages or tombstones in their existing mutation statements. Workers install those facts from native COMMIT evidence, independently of reply delivery; settlement-dependent signals still wait for transport recovery. Compound publications install all facts before public observers, and proven rollbacks preserve prior facts.
The Gateway is the runtime database writer. No foreign-commit freshness probes are added. Other processes must use the Gateway or hold offline custody while it is stopped. This PR does not change SDK versions or remove final guards.
Coverage and retained boundaries
Explicitly incomplete: arbitrary raw/trigger/cascade writers; standing-grant generation companions, cascade child identities, and cron-specific worker transport of grant revocation facts; invalidation-only placement move error/cancellation paths; offline Doctor relocation/import. Retirement adapters without definite native settlement remain conservatively unknown. Existing exec, node dispatch, placement, workspace, and grant guards remain mandatory. These receipts confer neither permission nor cross-store exclusion.
Evidence
Final pushed head:
9c7a3b10f35038e57ed00418bcb33a92ebf84313.31c35d5f5b093b7f84e7fbd1a6107f8b17454b67: reply-loss recovery returns stalebase_commitbytes from the caller. The candidate returns the native committed row and performs one mutation.agents.tsconfig mutation (already fixed upstream by959197ba0923), Knip’sisTelegramReadOnlyControlLaneText/resolveContextTokensexports, and 13 existing max-lines violations. Failing source blobs match main base427f926e7c2d; remaining planned checks were executed separately rather than skipped. No T1 call-count growth.5856d58f; SDK export registration check passes. This comparison pins the measured pre-integration head, not a moving main.The final head integrates main
427f926e7c2donce to resolve a workspace-test import conflict. Thirty-one integrated workspace/receipt cases pass. Of the 46 changed production files, 44 are byte-identical to measured head2f3f87f0df07; the remaining two only rename locals without changing SQL, receipts, or control flow. Upstream test cleanup is preserved.Statement measurements
Measured baseline
31c35d5f5b093b7f84e7fbd1a6107f8b17454b67against reviewed candidate2f3f87f0df077cb868863975485574c0daccd349on one isolated Blacksmith Testbox (Linux, Node 24.19.0, 4 observed CPUs). Wrapper source-capsule verification pinned the candidate treedf808ede8fc47fdeb761a00a4fed2a59e398e956; source hashes cover all 64 changedsrcpaths. This is pre-integration evidence; later integration resolved a test-only overlap and local-variable renames, without changing the measured SQL/receipt logic.Testbox run, lease
tbx_01m4hnq9gerts46syn4y4vkdpv: four alternating baseline/candidate pairs; every run completed 13 turns, child, control RPCs, cron, compaction and shutdown. Exact phase/thread/SQL census conservation passed. All gated median wall ratios are 0.930–1.083; these are instrumented observation windows, not latency claims.The first-turn median rises 1809→1852.5 (+2.40%); warmed statements rise 1062.35→1065 (+0.25%). These are not claimed as per-phase savings. The required additional fourth alternating pair under the campaign RAW TURN INCREASE rule gives complete startup→shutdown statements 22383→22372 (−11) and requests 3375→3370 (−5), qualifying the raw turn increase as redistribution. MAIN increases 2535→2545 (+10) in that pair.
The complete four-run medians increase; the gate qualification is specifically the prescribed additional fourth-pair check, not a claim that the series aggregate or every phase decreased. Fourth-pair family totals (request-associated SQL includes admission/envelope statements):
Three local alternating affected-operation pairs cover 27 semantic phases (26 emit SQL; phase 16 is a zero-SQL environment-read assertion). Every phase has identical statement counts, 2077 total per run including setup/cleanup. Each run also has 33 SQLite-broker requests, 2 task-worker requests and 1 resource-close. The raw source-run census additionally captured 3836→3871 tsx/esbuild/ESM transformation messages; retained stacks identify every one as loader traffic, so they are excluded from database-request totals. The built shared workload has no corresponding loader traffic in the retained request-group samples. Focused millisecond-scale wall ratios are not a performance gate or latency claim. Bun 1.4.2 with native SQLite 3.53.4 passed all 27 semantic phases.
Remote failed native BEGIN executions remain reported separately (successful executions alone are counted): baseline [1,0,1,1], candidate [1,2,1,2]. All nine failures occur during connect in the unchanged plugin-lifecycle lease-release path (
releaseOpenClawStateLeaseBestEffortunderrunGatewayPostReadyStartupMaintenance); successful BEGIN elapsed-time diagnostics are retained; elapsed BEGIN time is an acquisition upper bound, not isolated lock wait. Earlier seven local shared pairs were duration-invalid and are not gate evidence. Their native lock-failure counts were baseline[0,0,0,0,0,0,1]and candidate[2,1,0,0,0,3,0], from post-ready plugin-lease release except one candidate agent-lease shutdown close.Both source-mapped qaRuntime builds passed. No evidence archive was created; raw traces/fixture databases were removed after aggregation. The compact evidence download passed SHA-256 verification for 54 files. The owned Testbox was stopped successfully; published-driver × candidate update proof passed on the final head (details below).
Test cost and change size
Focused owner commands used
pnpm test <owner-files> --maxWorkers=1. The broad first pass took 613.7 seconds including compilation and imports; the repair/unrun-owner pass took 434.6 seconds. The final shutdown-only proof took 52.2 seconds including worker artifact preparation (1.3 seconds in the test). These are grouped command wall times, not a claim that every file costs that wall time. Final-head CI passed in run 38018138302; the authorization worker shard completed in 358 seconds.Measured test-body time in the materially changed test files (shared compilation/import time is included only in the grouped wall times above):
src/node-host/node-worker-prepared-workspace-publication.test.tssrc/state/state-domain-publication.test.tssrc/gateway/worker-environments/store-projection.test.tssrc/gateway/worker-environments/placement-turn-claims.worker.test.tssrc/gateway/worker-environments/placement-turn-authority.test.tssrc/gateway/worker-environments/store-worker.test.tssrc/gateway/operator-approval-store.test.tssrc/gateway/worker-environments/placement-workspace-journal.test.tssrc/gateway/worker-environments/transcript-commit-store.test.tssrc/gateway/worker-environments/store-recovery.worker.test.tssrc/gateway/operator-approval-store.worker.test.tssrc/gateway/worker-environments/placement-session-tool-operations.worker.test.tssrc/gateway/worker-environments/local-workspace-store.test.tssrc/gateway/worker-environments/store-revocation-notify.test.tssrc/agents/workspace-state-store.test.tssrc/infra/exec-approvals-store.test.tssrc/state/session-repository-workspaces.test.tssrc/agents/workspace-state-read.worker.test.tsThe longer existing suites exercise real worker admission, native locks, lease/lifecycle closure, and committed-versus-unknown outcomes. New regressions extend those existing fixtures; the new generic receipt suite costs 0.25 seconds and the node prepared-workspace receipt case 2.44 seconds.
Production: +1,810 / −443 lines across 46 files. Tests/support: +672 / −81 across 19 files. Docs/generated inventory: +93 / −58 across two files. The shared staging adapter avoids separate transaction/receipt lifecycles in each family; domain policy and projections remain with their existing owners.
Final landing validation
Head
f9f3b04682ad3bde80f4ada516ad4bf911bd5dabpassed CI run 38018138302. Conflict-only integration retained main’s publication adapter. The small CI repair added the receipt module to the native wrapper inventory, removed two type-import cycles, and retained admission in the authorization reducer fixture without changing its policy or deletion assertions. Scoped P0/P1 autoreview was clean.Focused proof: authorization worker 3/3 (27.50 seconds wall, 0.407 seconds test execution); wrapper closure 17/17 (30.69 seconds wall); post-commit publications 9/9 (26.18 seconds wall). The final authorization CI shard took 358 seconds.
Testbox verified the final source head and tree
d4c815502da2752ce38a2d7c0031ce3c9d94d5ed. The remote import-cycle check reported zero cycles. Published driver2026.9.8upgraded to candidate2026.9.9; readiness returned 200, the running version matched, and durable and incognito after-state checks passed. The command completed successfully in 708.7 seconds (update phase: 184.0 seconds). The owned Testbox lease was stopped.