Skip to content

fix(update): report deferred repairs as warnings and clear resolved notices - #155389

Merged
steipete merged 6 commits into
mainfrom
upd/repair-restart-before-doctor
Sep 22, 2026
Merged

steipete merged 6 commits into
mainfrom
upd/repair-restart-before-doctor

Conversation

@steipete

@steipete steipete commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

Closes #153377

What Problem This Solves

Fixes update repair failing on a safe Doctor maintenance refusal and replaying pending-migration warnings after those migrations completed.

User Impact

Update repair now succeeds with a recorded warning when maintenance cannot start safely, including contention from an unknown or non-serving process. It restores a service it stopped, retains pending migrations and recovery history, and gives the next repair step. Active/incomplete writes, unreadable state, live or unverified Gateway shutdown, revoked authority and unsettled cleanup retain their failure behavior.

A completed migration stops replaying its matching historical warning. Unresolved, reintroduced, newer and unrelated warnings remain visible; stored update history is unchanged.

Why This Change Was Made

Doctor maintenance owns a closed refusal classification: deferred coordinator contention, an active agent database lease or unavailable admission; data-at-risk active mutation, unreadable state, incomplete migration or unverified Gateway shutdown. Update callers consume that decision through the existing Doctor response channel instead of treating diagnostics as success/failure policy. This also preserves unsafe refusals across the post-plugin advisory handling added in #154543. The former serving-Gateway-only exception is removed. The published parent-owned continuation also admits database maintenance before opening plugin state; native service custody remains with the parent. This prevents a later schema mutation while the same non-serving process still holds the coordinator after Doctor defers.

The warning reader projects explicit completed migration IDs/times through the existing state worker. It supports both published state migration is pending: and current data/settings upgrade is unfinished: messages without loading retired migration reports or inferring completion from absence.

This preserves main's native stop-custody compensation and partial-coordinator cleanup from #153167, including restoration after update authority changes; lost update authority still remains terminal afterward.

The reporter's restart-verification-before-error timestamps reflect compensation after refused admission. Maintenance was already attempted first, so this fix preserves that ordering. Thanks @mattash for the independent evidence and @johnnyjrizzo for the original report.

There are no new configuration/CLI options, dependencies, SQLite schema changes or version bumps. Production LOC is +536/-229 (net +307): +164 for typed classification, IPC and caller propagation with authority/cancellation preservation, +93 for the worker-owned completion projection and historical-warning filter, and +50 for the task-event ordering repair and its line-cap extraction. This exceeds the net-zero target to cover every update entry point, keep reads off the Gateway thread, and retain observer ordering in the existing event owner; the 67-line special-case helper is removed. Tests and test support are +1724/-1066 (net +658); docs +31/-28.

The CI follow-up also fixes task completion observers publishing a linked task before its backing task. Native readback now retains observer order in the accepted-event owner, including reentrant listeners. Existing persistence, flow and notification settlement remain with their owners.

Evidence

Latest worker-link ordering repair: head 39fd8af00a1daf2c98c645c4a93b3569fcfada5f, rebased onto 48b6d5e566f3ce58c9b84f0eb0bf5ef689152371.

The failure is a shared task-event owner race. A synchronous registry read joins the backing event’s durable worker commit, then consumes the linked event natively while the backing event still awaits asynchronous reconciliation/publication. The linked observer can overtake its predecessor. The affected task owner, admission/broker code and original test were byte-identical on main and the pre-fix PR. This PR’s worker contract/runtime delta only adds migration-completion reads; those branches do not execute for task events. No added link-commit await or moved link publication was found.

The native event path now defers observer dispatch behind earlier granted or deferred events in the existing accepted FIFO. Persistence, projections, flow effects, commit/rollback settlement and terminal-notification ownership remain unchanged. The marker stays installed through listener dispatch, so a reentrant listener cannot publish a third event before other listeners receive the second. This latter case was caught by P1 review and is covered by a separate regression. No timer, retry, timeout increase, new queue, weakened assertion, suppression or baseline change is used.

The original backing-first array expectation and every original case/assertion remain unchanged. Shared setup moved to sqlite-worker-managed-task-link.test-support.ts; the new sqlite-worker-managed-task-link.ordering.test.ts protects reentrant multi-listener order without exceeding the file cap.

Base-relative interdiff versus cb736f06b05: the rebase preserves all 35 original changed files’ added/deleted line sequences exactly. This delta is production +91/-41 (net +50); tests/support +262/-102 (net +160). The semantic fix adds 32 net production lines to carry deferred observer publication through the existing owner and preserve reentrant dispatch ordering. A mechanical extraction of event-source identity capture/equality adds 18 net lines, keeping the existing owner below the 700-line ratchet without a suppression or baseline change.

Pre-fix comparison used job 106898307294’s original core-runtime-infra-storage-state-hosted-12 configuration and include order, through node --import tsx scripts/ci-run-node-test-shard.mts: 61 files / 849 collected tests, including 6 existing skips. Head N=3: FAIL/PASS/PASS (304.065/269.337/300.809 s); main N=3: PASS/PASS/PASS (267.864/334.831/330.046 s). The failed head run reproduced both reversed-array event cases. These runs used the prepared Node 24.19.0 runtime and fresh scratch caches; original CI used 24.20.0 and restored caches. Input order and worker settings were preserved; parallel emitted file order naturally varied. No-output retry was disabled.

A deterministic receipt gate, after the actual worker commit and before observer publication, then failed at the unchanged order assertion on both exact main and head under checksum-verified official Node 24.20.0 (21.705/20.663 s). This establishes the common owner race; the ungated main passes do not establish its absence. Lease tbx_01m35bcejc85aysanmf50bq3vz (run) was stopped. Full source identity and original command configuration were verified for the comparisons.

The reentrant red control against the first reviewed producer failed for the intended A/C/B reversal in 17.778 s wall (0.976 s test time), with the durable-success assertion already passed. The first attempt had failed before reaching the regression because a CLI fixture lacked the backing flow required by the existing helper; the corrected fixture uses an independent ACP backing. The red-result classifier initially missed the terminal’s truncated three-element code frame; its saved raw output was qualified directly, and that valid red test was not rerun. No production change was needed for either harness correction.

Fresh P1 Codex autoreview is scoped-clean on all six files against rebased head f6a71a60cfb406eeebd48e8082eb2bbe289b1532, final candidate tree 8d6fff6e47de7ef1356cd13773065cf15a692c6d. The review includes the reentry fix and both coherent extractions.

Final source proof on Node 24.20.0: all three original shard replays passed 61 files / 843 active tests + 6 existing skips each (335.026/289.645/321.962 s wall; 2,529 passing executions). The owner/PR batch passed 25 files / 598 tests in 241.111 s wall. Both changed files passed individually before that batch: original managed-link 17/17 (44.501 s wall, 22.674 s test time), reentrant ordering 1/1 (23.801 s wall, 1.401 s test time). Every final lane verified the candidate tree and 117 source/test hashes.

Both changed files also passed N=20 each, 360 test executions with zero failures. The original 17-case file took 31.589–55.604 s wall (median 34.901 s); its maximum case was 2.835 s and maximum summed file test time was 30.813 s. The one-case reentrant sibling took 15.889–24.506 s wall (median 18.330 s), with maximum test time 1.565 s. These runs retain the existing real SQLite-worker/native lifecycle fixtures and separate preparation from test time. Across the full final shard proof, the maximum case was 18.310 s and maximum file test time 54.242 s; no slow-test threshold was crossed. All 14 current added/modified PR test files are covered by the 25-file batch; the deleted serving-holder-specific maintenance suite is replaced by the covered general refusal suite.

The full static command passed with exit 0 in 39m14.312s: explicit line-cap ratchet, check:changed, core typecheck, all 25 test-type shards, all five core lint stripes, storage/schema and boundary guards, and zero runtime import cycles. The only lint warning is the unchanged cron timer test line count. No gate was skipped. The committed tree exactly matches the reviewed and tested candidate tree above.

Worker-order Testbox leases and commands

Provider: blacksmith-testbox. The native runner’s command exit code owns the proof; stopping the lease can cancel its attached Actions container.

Proof Lease Run
head-1 tbx_01m35aszy3crcxebzy6c5103zc run
head-2 tbx_01m35aszxw73mkfvxq4j9ft082 run
head-3 tbx_01m35aszmg6420ahrh4c9khas2 run
main-1 tbx_01m35aszn6nxe21dcy6vd89ff7 run
main-2 tbx_01m35aszmdh3hjcgbykd1vjxj5 run
main-3 tbx_01m35aszxkjj57nfr0g7j73sxq run
shard-1 tbx_01m35byav8zt1bkpm2xazx0skx run
shard-2 tbx_01m35byazrspv86sfj6jmrd9dr run
shard-3 tbx_01m35byb4h5wjyy9ennwyn34bm run
owners tbx_01m35byattn183z2t6s9bq5s1x run
static tbx_01m35byav7p4aa7dnk5b2rbtcm run

The three final shard commands were node --import tsx scripts/ci-run-node-test-shard.mts, with the original singleton storage-state-hosted-12 group, all 64 include patterns in original order, group workers 2, outer workers 3, plan concurrency 1, and no-output retry disabled. All 61 collected files and their case declarations are retained. Parallel file completion order is not an invariant and differed from the historical log; input/configuration order is preserved.

The owner/PR command used verified Node 24.20.0:

node scripts/run-vitest.mjs \
  src/cli/update-cli/update-command-convergence-authority.test.ts \
  src/cli/update-cli/update-command-doctor-authority-callers.test.ts \
  src/cli/update-cli/update-command-finalize-refusal.test.ts \
  src/cli/update-cli/update-command-fresh-doctor.test.ts \
  src/commands/doctor-maintenance.settlement.refusals.test.ts \
  src/commands/doctor-maintenance.settlement.test.ts \
  src/commands/doctor-update-run.test.ts \
  src/flows/doctor-health.legacy-update.test.ts \
  src/flows/doctor-health.migration-refusal.test.ts \
  src/infra/deferred-plugin-migrations.test.ts \
  src/infra/sqlite-worker-managed-task-link.test.ts \
  src/infra/update-doctor-result.test.ts \
  src/logging/diagnostic-support-redaction.test.ts \
  src/commands/doctor-update-refusal.test.ts \
  src/tasks/task-registry-agent-events.test.ts \
  src/tasks/task-registry-agent-events.lineage.test.ts \
  src/tasks/task-registry-agent-events.liveness.test.ts \
  src/tasks/task-registry-worker-publication.test.ts \
  src/tasks/task-registry-transition.native.test.ts \
  src/tasks/task-registry-create.native.test.ts \
  src/tasks/task-registry-terminal-notification.test.ts \
  src/tasks/task-registry-terminal-read.test.ts \
  src/tasks/task-registry.notifications.test.ts \
  src/tasks/task-registry.test.ts \
  src/infra/sqlite-worker-managed-task-link.ordering.test.ts \
  --maxWorkers=1 \
  --sequence.shuffle=false

Standalone runs used the same router with one of the two managed-link files and --maxWorkers=1, twenty times per file. Static commands were pnpm check:line-cap-ratchet --base origin/main and node scripts/check-changed.mjs --base origin/main.

Earlier-head evidence is retained below with its source identities.

Latest tests-only line-cap repair: head b0082f660b16e9b1bf69c898e2aa81e3028f673e (reviewed production remains unchanged).

The CI ratchet measured the merge result: this branch's settlement suite had 997 counted lines, and main's added same-installation restoration case contributed 22, producing the reported 1,019. The branch-local ratchet correctly passed before the split; it did not model that merged file. The projected full Git merge against main 875aaaffcb7571385dbaca24fa56eef2f195896f is clean after the split and preserves that incoming case.

The contiguous lease/refusal classification and public-diagnostic cases now live in src/commands/doctor-maintenance.settlement.refusals.test.ts (326 physical lines). The original settlement suite is 449 lines; shared mocks/setup/cleanup live in doctor-maintenance.settlement.test-support.ts (265). All 182 assertion calls and 21 mock factories are preserved; moved bodies and shared setup are unchanged. Remaining cases only use the support module's live stopped export through its namespace. The existing non-isolated runner resets the support module and its hooks between files. No coverage, assertion, suppression, baseline, production code, timeout, or dependency change.

Delta versus 9b989f2bdeb: production +0/-0; tests/support +602/-592 (net +10) for imports and exports. The coordinator's r4 review covers this tests-only delta; an independent preservation audit found no issues.

Proof on the frozen tree 9ab2c3958e4ce3f33e6f8187e6851ce5202dd10b:

  • Combined run: 2 files / 31 tests passed (21 settlement + 10 refusal), in settlement-then-refusals order, 16.581 s wall. The original suite also had 31 cases.
  • Each file passed independently: settlement 21/21 in 15.488 s wall (0.103 s tests); refusals 10/10 in 15.720 s wall (0.131 s tests). No slow-test threshold crossed.
  • Explicit pnpm check:line-cap-ratchet --base origin/main: exit 0 in 5.835 s; 30 changed source files, no new violations or over-cap growth. The local script also passed after the split.
  • Full node scripts/check-changed.mjs --base origin/main: exit 0, all 31 steps passed, including 25 test-type shards, five core lint stripes, and zero runtime import cycles. Testbox command time was 2,113.396 s (35m13.396s). The only lint warning is the unchanged cron timer line count already on main.

Test/ratchet lease: tbx_01m34hgq287191g80swgzf4fpa (run); full static lease: tbx_01m34hgq3f09b9rpktwb0ajzmy (run). All 33 selected source/test hashes were verified. Both validation leases are confirmed stopped.

Commands: node scripts/run-vitest.mjs src/commands/doctor-maintenance.settlement.test.ts src/commands/doctor-maintenance.settlement.refusals.test.ts --maxWorkers=1 --sequence.shuffle=false, each file separately with --maxWorkers=1, pnpm check:line-cap-ratchet --base origin/main, and node scripts/check-changed.mjs --base origin/main.

The following evidence records the preceding heads with their original identities.

Rebase after the clean r4 review: head 9b989f2bdebb2fea13d9c35ec25b35b15d20e3b1, onto fetched main 80b9608a25e191a17e1466d750c2f76a38a38507.

This is a mechanical rebase. The signed added/deleted line sequence of every one of the 33 base-relative PR files is identical to reviewed head 45aa5f7b74d against its old base. Base-relative production interdiff: +0/-0; semantic changes: none. Full PR counts remain production +445/-188, tests +874/-386, docs +31/-28. The raw head-to-head production change in the two overlapping owners is +26/-18 and exactly matches inherited main, excluded from the lane interdiff.

Conflicts combined imports and regression blocks while preserving main's landed #153764 behavior: the installed target owns convergence before parent worker/runtime use; a retained incompatible runtime cannot fall back locally after declined handoff; requester authority is checked after executor settlement immediately before publishing the result. Our deferred-only warning path, unsafe terminal path, admission-before-mutation ordering, and unobserved restoration reads remain unchanged. Both sets of tests are retained without assertion edits. A separate source audit confirmed the composition and exact patch identity; r4's clean reviewed patch is unchanged.

Fresh Testbox proof on tree eaf3d8d3394190f42b2009856286491552953417: 12 files / 263 tests passed per round, N=3, 789 passes total. This includes every PR-owned test file, doctor-update-refusal (16/16 per round), and doctor-health.legacy-update (10/10 per round). The prior file-argument order and repository router were retained; verbose logs confirm identical actual file/case traversal across all three rounds. All 32 selected source/test hashes were verified.

Round wall times: 131.006 / 107.785 / 175.260 s, including preparation. No individual test exceeded 30 s and no file exceeded 120 s of test time. The full node scripts/check-changed.mjs --base origin/main gate passed with exit 0: 31 steps, all 25 test-type shards, all five core lint stripes, and zero runtime import cycles. Testbox command time was 2,760.404 s (46m00.404s). The only warning is the unchanged cron test line count already on main; no gate was bypassed.

R4 proof Lease Result
test-1 tbx_01m34b4d9k0kwcqpjdc9ydm24t (run) exit 0; 12 files / 263 passed; 131.006 s wall
test-2 tbx_01m34b4d1xv999affedxaxhky7 (run) exit 0; 12 files / 263 passed; 107.785 s wall
test-3 tbx_01m34b4d1sh8t6s1ywxyecqsjf (run) exit 0; 12 files / 263 passed; 175.260 s wall
Full static gate tbx_01m34b4d2a19nnnz6qha4meqnv (run) exit 0; 31 steps; 2,760.404 s command time

The first static invocation was rejected by the wrapper before executing checks because its base argument was a raw SHA. The corrected invocation uses the required --base origin/main and verifies that reference against the pinned base. No checks ran against a wrong base, and no source change was needed. All four validation leases are confirmed stopped.

Repeated command:

node \
  scripts/run-vitest.mjs \
  src/flows/doctor-health.legacy-update.test.ts \
  src/flows/doctor-health.migration-refusal.test.ts \
  src/commands/doctor-maintenance.settlement.test.ts \
  src/cli/update-cli/update-command-doctor-authority-callers.test.ts \
  src/cli/update-cli/update-command-finalize-refusal.test.ts \
  src/cli/update-cli/update-command-fresh-doctor.test.ts \
  src/cli/update-cli/update-command-convergence-authority.test.ts \
  src/commands/doctor-update-run.test.ts \
  src/infra/deferred-plugin-migrations.test.ts \
  src/infra/update-doctor-result.test.ts \
  src/logging/diagnostic-support-redaction.test.ts \
  src/commands/doctor-update-refusal.test.ts \
  --maxWorkers=1 \
  --sequence.shuffle=false

The following evidence belongs to the preceding head 45aa5f7b74d and is retained with its original source identity.

Latest CI repair (head 45aa5f7b74dd80476f6ece6f103a0e7f69b94cc8; rebased onto 4cf81a5c196e331f4eacb038c964d337af88d146):

The released Git-driver regression was in the refusal owner: converting errors into typed refusal members removed the original Doctor could not enter maintenance. Error: prefix and let already-typed errors bypass the Git recovery warning recorder. The common admission-failure path now preserves the typed member while adding the existing recovery instructions and support-log record. Terminal refusals retain their exact released messages; safe stopped/no-write refusals still become recorded update warnings. No test or assertion changed in this delta.

Reported row at 2e5ee9c1c33 Verdict
compact-small-17, released Git driver Owner fix restores exact terminal messages and recovery records. Pre-fix: exactly 3 failed / 13 passed in 38.487 s; candidate: 16/16 passed in each of three full rounds, unchanged assertions.
compact-small-14, retained deleted agent Main-before 97e9ce9bf666: 1 failed / 7 passed (49.409 s). Main fix e99e75e2e60: 8 passed (49.116 s), unchanged test. b068eab4076 was already in the previous PR head; the missing automatic-target filter is fixed by the included rebase. Hard-link safety stays enforced.
Windows checkout sentinel readiness Coordinator-attributed unrelated flake; report only, unchanged and not rerun.

Production interdiff versus 2e5ee9c1c33: +14/-13, net +1, in doctor-maintenance.ts and doctor-maintenance-inspection.ts; tests +0/-0. The one added line documents the released-driver compatibility contract. Inherited main changes are excluded from this interdiff.

L1203 overlap: reviewed #155610 at 1743dfd1b1cf956427ff0c0582a0337b27d300c6. No production files overlap; only docs/cli/update/how-updates-run.md has edits, in separate sections. Our typed refusal and recovery recording execute in target Doctor. L1203 stops the parent from reading state-backed policy after target handoff while retaining identity/native custody; this delta adds no such parent read. No conflict identified by source review. No rebase onto or execution of that PR; combined runtime proof remains unrun.

The frozen candidate tree 5bd21322cfc726302f79c8ee46fe2fa453eb1b12 is exactly the tree of final head 45aa5f7b74dd80476f6ece6f103a0e7f69b94cc8. All runs verified 71 source/test hashes. N=3: 51 files and 1,397 tests passed per round; 4,191 executions total, zero failures. The verbose-log comparison confirms identical actual file traversal and identical per-file case order across all three rounds. Coverage includes both reported suites, the previous repair suites, and all importing siblings selected for the changed owners.

The unchanged released-refusal suite passed 16/16 each round (12.070 / 8.246 / 12.847 s test time); retained-deleted-agent passed 8/8 each round (18.904 / 13.563 / 22.132 s). Config-fence passed 25/25 and legacy-update passed 10/10 in each round. Round wall times were 1,210.308 / 1,293.218 / 1,567.869 s, including shared preparation.

No individual test exceeded 30 s (maximum 12.217 s). Existing aggregate test costs remain visible: update-cli.test.ts 229.102–519.423 s across 513 cases, doctor-health.test.ts up to 184.822 s across 94 cases, and update-command-lease.test.ts up to 157.416 s across 54 cases. These are the previously diagnosed per-case real SQLite/config/lease isolation and subprocess-custody fixture costs; no timeout, retry, assertion, skip, or baseline changed.

P1 Codex autoreview: scoped-clean on the two-file delta against rebased head 3d012ffc780b02621ecd59208ba6ca48f1ff4ef1. The full node scripts/check-changed.mjs --base origin/main gate passed with exit 0: core types, all 25 test-type shards, all five core lint stripes, storage guards, and zero runtime import cycles. Testbox command wall was 40m11.367s. The sole lint warning is the unchanged cron timer line count already on main; no gate was skipped or bypassed.

Proof Testbox lease Command result
test-1 tbx_01m347sg8qj6pvb4ypx75d1ge3 (run) exit 0; 51 files / 1,397 tests; 1210.308 s wall
test-2 tbx_01m347sfyq2e98src5wqvg3c61 (run) exit 0; 51 files / 1,397 tests; 1293.218 s wall
test-3 tbx_01m347sfz57qk94f4bm00vkb38 (run) exit 0; 51 files / 1,397 tests; 1567.869 s wall
Full static gate tbx_01m347sfztan6aqzw8f2jcmek2 (run) exit 0; Testbox command 40m11.367s
Exact main attribution tbx_01m348fmmdpn842x69spy4babz (run) before: exit 1, 1 failed / 7 passed; after: exit 0, 8 passed

The first exact-main attribution setup collected zero tests because a root dependency symlink omitted workspace-local dependencies (mdast-util-from-markdown). Normal frozen-lockfile installs in the isolated physical checkouts corrected that fixture setup; exact revisions and unchanged test hashes were reverified. The original setup failure is retained separately (29.746 s); it was not counted as a product failure. Both attribution leases and all four final validation leases are confirmed stopped.

Latest repeated Testbox command
node \
  scripts/run-vitest.mjs \
  src/flows/doctor-health.legacy-update.test.ts \
  src/flows/doctor-health.test.ts \
  src/flows/doctor-health.migration-refusal.test.ts \
  src/flows/doctor-health.update.test.ts \
  src/flows/doctor-health.update-scope.test.ts \
  src/flows/doctor-health.update-budget.test.ts \
  src/flows/doctor-health.update-schema.test.ts \
  src/flows/doctor-health.unsupported-state.test.ts \
  src/flows/doctor-health.plugin-load.test.ts \
  src/flows/doctor-health.fleet-preflight.test.ts \
  src/flows/doctor-health.dangling-workshop-index.test.ts \
  src/commands/doctor-maintenance.finish-revalidation.test.ts \
  src/commands/doctor-maintenance.foreground-update.test.ts \
  src/commands/doctor-maintenance.installation.test.ts \
  src/commands/doctor-maintenance.native-identity.test.ts \
  src/commands/doctor-maintenance.plugin-preflight.test.ts \
  src/commands/doctor-maintenance.schema-preflight.test.ts \
  src/commands/doctor-maintenance.service-inspection.test.ts \
  src/commands/doctor-maintenance.session-workers.test.ts \
  src/commands/doctor-maintenance.settlement.test.ts \
  src/commands/doctor-maintenance.worker.test.ts \
  src/cli/update-cli/update-command-config-fence.test.ts \
  src/cli/update-cli/update-command-doctor-authority-callers.test.ts \
  src/cli/update-cli/update-command-lifecycle.test.ts \
  src/cli/update-cli/update-command-lease.test.ts \
  src/cli/update-cli/update-command-legacy-finalize.test.ts \
  src/cli/update-cli/update-command-finalize-refusal.test.ts \
  src/cli/update-cli/update-command-fresh-doctor.test.ts \
  src/cli/update-cli/update-command-convergence-authority.test.ts \
  src/commands/doctor-update-run.test.ts \
  src/infra/deferred-plugin-migrations.test.ts \
  src/infra/update-doctor-result.test.ts \
  src/logging/diagnostic-support-redaction.test.ts \
  src/cli/update-cli/update-command-contention.test.ts \
  src/cli/update-cli/update-command-pending-recovery.test.ts \
  src/cli/update-cli/update-command-plugin-caller.test.ts \
  src/cli/update-cli/update-command-fresh-doctor-authority.test.ts \
  src/cli/update-cli/update-command-post-core-failure.test.ts \
  src/cli/update-cli/update-finalization-lifecycle.test.ts \
  src/cli/update-cli/update-config-provenance.integration.test.ts \
  src/cli/update-cli/update-load-path-finalization.integration.test.ts \
  src/cli/update-cli.test.ts \
  src/commands/doctor-update-refusal.test.ts \
  src/infra/state-migrations.retained-deleted-agent.test.ts \
  src/commands/doctor-update-schema-guard.test.ts \
  src/commands/triage-repair-isolation.test.ts \
  src/cli/update-cli/update-command-service-maintenance.test.ts \
  src/config/sessions/session-accessor.sqlite-worker-coordination.test.ts \
  src/state/openclaw-state-maintenance-resources.test.ts \
  src/cli/update-cli/update-repair-history.test.ts \
  src/infra/state-migrations.outbound-custody.test.ts \
  --maxWorkers=1 \
  --sequence.shuffle=false

All three commands used the repository router and original test declaration order. The separate static command was node scripts/check-changed.mjs --base origin/main against the pinned rebase base above. Wrapper exit codes own the proof; lease cleanup can cancel its attached Actions container afterward.

The next section records the preceding CI repair at 2e5ee9c1c33; its historical proof is retained below.

CI follow-up to head 91c3bb922791018434fe741a1a990acd06c737f5 (run 35691627918):

  • compact-small-12 / storage-state-hosted-7: the legacy-update suite had three terminal-refusal regressions; its Doctor-health sibling had five more for foreign/queued/unverified services and an update parent that had not stopped the Gateway. The new closed-union member gateway-state-unverified is produced by the shutdown/inspection owner and preserved through Doctor IPC. The legacy tests still require rejection and unchanged state; they now additionally assert the typed refusal, with an external-supervisor variant protecting the legacy-lock barrier. The fresh-process matrix also checks the new unsafe member. No refusal expectation was relaxed to successful update behavior.
  • compact-small-11 / storage-state-hosted-5: both config-fence failures were observing config reads during cleanup after executor revocation, not warning rows. Restoration input reads now use observe: false in resume, finalization and Doctor compensation. The existing exact health/audit expectations are unchanged.
  • config-89: inherited the main Slack fixture fix 99f7055b339 by rebasing onto main (final base 2fd14c2a244395153e0bbb10af7a7669611b2b58); this lane does not modify that test.

Final CI-repair candidate: 2e5ee9c1c33a7dd18a3810a74647b9ab0f2fa44f, source tree 57b5852bb2a4e681482e456b9eb908b179a902c8.

  • Pre-fix Testbox control reproduced exactly 11 failures: all ten original CI failures plus the added external legacy-lock case. The fixed source was restored and verified before positive proof.
  • Final integrated N=3: 42 files / 1,264 tests passed per run, 3,792 passing executions. Identical file arguments, declaration order, --maxWorkers=1 --sequence.shuffle=false, default repository router. Wall times: 1,409.700 / 1,119.795 / 1,080.543 s.
  • Final P1 Codex delta autoreview: scoped-clean, using the current main owner context. The rebase was conflict-free and the changed lane source/test files remained byte-identical.
  • Final full check:changed: passed: 31 steps, including all 25 test-type shards, five lint stripes, and zero runtime import cycles; 33m31.48s command time.
  • Production interdiff versus 91c3bb92279: +52/-28, net +24 lines, excluding inherited main changes. Test interdiff +92/-64 (net +28); docs +3/-3. The production delta adds the explicit unsafe member/producer classification and removes observing effects from restoration reads.
  • Initial static validation passed all 25 type shards but found two unchanged plugin lint errors from 08773da26446. Final rebase includes their owning main fix 0051fa8f8f3; no suppression or baseline edit was used.

Final Testboxes (blacksmith-testbox): tests tbx_01m341r14avfs60x7p2vtby6rm (run), tbx_01m341r12588fcj0jzsxqkj4sw (run), tbx_01m341r13v8k96r9y9pazbxpks (run); static tbx_01m341r13g7km1hxvtb2v379b1 (run). Each run verified the physical checkout and 62 source/test hashes. All four final leases are confirmed stopped. The sole final lint warning is the unchanged cron test line count; both inherited plugin errors are absent.

The 42-file command covers both failed Doctor suites and config-fence, the original 10 PR suites, every doctor-maintenance.*.test.ts sibling, Doctor update/health siblings, finalizer/resume/config-provenance callers, and the direct update-cli.test.ts caller. Tests keep original declaration order. Changed-file individual timings on the identical test source before final main integration: doctor-health.legacy-update.test.ts 10/10, 27.793 s wall; update-command-fresh-doctor.test.ts 76/76, 23.807 s wall.

No individual case exceeded 30 s. Existing aggregate costs are recorded rather than hidden: final update-cli.test.ts was 284.380–520.734 s for 513 cases (per-case isolated home/prefix/executor directories, ports/PID reads and real SQLite); Doctor health reached 151.652 s across real multi-agent schema/lease/migration fixtures; update-command-lease reached 122.345 s across isolated fresh-process custody fixtures. Compiler preparation is separate. No bounded defect was demonstrated in these fixture costs; no timeouts, retries, assertions or skips were changed to accommodate them.

The original evidence below describes prior head 91c3bb922791018434fe741a1a990acd06c737f5. Its live safe-contention and published-driver cells remain recorded; the final repair delta is covered above.

  • Pre-fix Testbox regressions fail for managed-service non-serving contention in both repair option paths, and for stale migration warnings with both historical phrasings. Data-at-risk controls remain terminal.
  • Unsafe-response regressions fail pre-fix at both actual IPC boundaries: two missing-producer-metadata cases and three child-adapter cases that incorrectly became advisories. All pass after the fix, with no subsequent config validation/readiness work after unsafe refusal.
  • Data compatibility: there is no SQLite schema or stored-format change. The real published-driver cell exposed post-core preparation opening a schema before maintenance under {completionOwner: "parent"}. A real version-16 schema/native-coordinator regression fails pre-fix and passes with preparation behind admission, asserting unchanged schema and pending records; the immutable 2026.9.5 upgrade cell below verifies the installed-driver contract. Warning filtering only reads existing completion IDs/times and leaves stored history intact.
  • Previous head: all 228 tests across 10 touched files passed five times in the same command order (1,140 executions). Related lifecycle suites: 162/162 passed. All 10 individual file runs passed before integration; the three files changed during integration passed individually again at the timings below. Longest observed final touched-suite case was 3.980 s; no slow/flaky threshold crossed in these suites.
  • Previous-head P1 Codex autoreview: scoped-clean for the complete integrated candidate, including the worker adapter and main’s native stop-custody restoration.
  • Real user-systemd repair: plain path exit 0 in 342.555 s; --no-restart exit 0 in 342.909 s. Each exercised running service → verified stop → actual separate non-serving coordinator holder → warning → native restoration, then checked a new Gateway PID, RPC health, succeeded ledger and unchanged pending obligation. Owned service/holder cleanup passed. These final fault-injection cells exercise main’s existing 330 s stopped-service allowance at real wall time; this PR neither adds nor enlarges it. Unit fixtures use virtual monotonic time and remain fast.
  • Previous-head canonical package build and tarball validation passed. Tarball SHA-256: 2b482757e26f7fcd481fda965ec8deebdd7b532e32838f4588aa43e498775609.
  • The previous-head full node scripts/check-changed.mjs --base origin/main gate passed (32m24s), including core types, all 25 test-type shards, lint, guards, and zero runtime import cycles. Its one lint warning is the unchanged src/cron/service/timer.test.ts line count already on main; changed-file growth and suppression guards passed.
  • Published 2026.9.5 → candidate: exit 0 in 114.556 s; run 05837af2-fcce-4792-b639-c2776118b932 succeeded. Both warning:openclaw doctor and warning:finalize:plugins:0 remain recorded. Full pending-record equality passed; Gateway PID changed 15345 → 18192 and RPC health passed. The actual candidate Doctor IPC carried status: ok, kind: deferred, reason: coordinator-contention, and its warning was retained by the immutable published parent.
Prior-head Testbox commands and measured cost

Provider: blacksmith-testbox. Final repeated and sibling tests: tbx_01m33pns8dnxvtwescb377e7sj (run). Final static checks: tbx_01m33pp6c3hvpccwrcwknjkajv (run). Final package, individual file timings and live service cells: tbx_01m33qc5c5hp6p4xs900pbdb2c (run). Original A/B red fixtures ran on tbx_01m3387e2aq59ax4nkx0cpwpjy (run); unsafe IPC red proof used tbx_01m33cc0nce4j6z73cq5xv98zv (run); published-continuation red proof used tbx_01m33cc3g22xnerg3tsjhr8cdx (run).

Previous tested source tree 519973af4232cdcc71a68209656e4ee204c3309a is the tree of head 91c3bb922791018434fe741a1a990acd06c737f5. Each command verified the physical checkout and source hashes before execution. Repeat rounds took 45.79–62.76 s. Testbox wrapper exit results own this proof; lease cleanup can cancel the attached Actions container afterward.

Repeated command used node scripts/run-vitest.mjs with the 10 files below and --maxWorkers=1; file order was identical for all five rounds. Individual timings use the same wrapper with one file and --maxWorkers=1; settlement, finalize-refusal and fresh-doctor were refreshed on the final integrated tree:

Test file Wall time
update-command-finalize-refusal.test.ts 21.736 s
doctor-update-run.test.ts 18.33 s
doctor-maintenance.settlement.test.ts 14.251 s
deferred-plugin-migrations.test.ts 18.51 s
update-doctor-result.test.ts 1.79 s
update-command-fresh-doctor.test.ts 16.935 s
doctor-health.migration-refusal.test.ts 25.31 s
update-command-convergence-authority.test.ts 14.26 s
update-command-doctor-authority-callers.test.ts 18.29 s
diagnostic-support-redaction.test.ts 2.04 s

Live commands used the supported CLI with isolated state/profile/unit and a free port. A task-only systemctl proxy injected the real coordinator holder only after a native verified stop; plain repair released it through a task-only ExecStartPre, while the published path released it at actual activation entry after both deferrals, before unchanged native restart admission. No product source changes, sleeps, retries or fabricated refusal results were used by the harness. The npm published-driver cell uses the immutable 2026.9.5 launcher and verified registry artifact against the candidate tarball. Its synthetic pending reason is seeded through the published writer after startup using current canonical guidance, so intentional wording normalization is independent of the full obligation-preservation assertion.

No timeouts were increased, retries used as fixes, tests disabled, baselines changed or lint suppressions added. Build/transform preparation is included in wall timings. The draft-head CI run is attached to exact head 91c3bb922791018434fe741a1a990acd06c737f5 and was skipped under the draft policy. Testbox proof above is complete; completed PR test-job timings are not available at publication.

The harness was corrected for native handoff exit 75, an observer that touched unrelated npm lifecycle argv, bounded package-mismatch assertion output, activation environment propagation, and the contender’s release lifetime. On the final lease, the first published baseline start refused the task-owned systemd drop-in: runner umask 0002 created it as 0775/0664. A mode probe established the cause; the fixture now creates its new directory/file as 0700/0600, preserving the existing security check and service parent. Only the published cell was rerun against unchanged source and tarball hashes after this fixture fix. These were fixture defects; the actual post-core admission failure was fixed in production and covered by a failing regression. Optional Testbox portal-sync warnings occurred after successful commands and did not affect their exit 0 or saved evidence. The first static invocation rejected a SHA base before executing checks; recording the reviewed merge allowed the standard origin/main gate above.

@clawsweeper

clawsweeper Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation cli CLI command changes commands Command implementations size: XL maintainer Maintainer-authored PR labels Sep 22, 2026
@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. P0 Emergency: data loss, security bypass, crash loop, or unusable core runtime. labels Sep 22, 2026
@clawsweeper

clawsweeper Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge. Reviewed September 22, 2026, 5:21 PM ET / 21:21 UTC (Revision 8).

ClawSweeper review

What this changes

Update repair records safe maintenance deferrals as warnings, hides resolved migration notices without rewriting history, and preserves task-completion observer order.

Merge readiness

⛔ Blocked before merge - 1 item remains

This remains a useful, maintainer-owned fix. No actionable introduced defect was found, and the inspected upgrade evidence resolves the previous compatibility-proof blocker.

Priority: P0
Reviewed head: 39fd8af00a1daf2c98c645c4a93b3569fcfada5f

Review scores

Measure Result What it means
Overall readiness 🦞 diamond lobster (5/6) Strong real upgrade evidence and focused negative controls support a coherent repair with no actionable finding.
Proof confidence 🦞 diamond lobster (5/6) Sufficient (live_output): The complete captured body records real systemd repair/restoration and a published 2026.9.5 updater-to-candidate run with warning retention, unchanged pending obligations and healthy replacement Gateway. These earlier-head observations are supplemented by current refusal and worker-order regressions. The completion projection changes no stored-data contract, so no migration is required.
Patch quality 🦞 diamond lobster (5/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (live_output): The complete captured body records real systemd repair/restoration and a published 2026.9.5 updater-to-candidate run with warning retention, unchanged pending obligations and healthy replacement Gateway. These earlier-head observations are supplemented by current refusal and worker-order regressions. The completion projection changes no stored-data contract, so no migration is required.
Evidence reviewed 10 items Introduced patch and merge identity: Reviewed the pinned merge-base-to-head changes. Raw test-merge records confirm the supplied base followed by the exact PR head; inspected merge-result hunks retain the warning filter and event-order repair.
Maintenance classification preserves refusal boundaries: Doctor compensates for its own stopped service before classifying admission failures. Caller-authority failures, cancellation and unsettled cleanup remain terminal; callers consume the typed deferred outcome without continuing convergence.
Read-only warning projection: The new worker operation selects existing completed migration IDs and timestamps. The display filter preserves later, unresolved and reintroduced warnings; neither the migration writer nor stored history format changes.
Findings None None.
Security None None.

How this fits together

The updater delegates state repair to Doctor, which coordinates database access and Gateway service restoration. Recorded outcomes feed update history and diagnostics; task completion events separately pass through the existing SQLite-backed event queue.

flowchart TD
  A[Update or repair request] --> B[Doctor maintenance admission]
  B --> C[Admitted repair]
  B --> D[Safe deferral]
  B --> E[Unsafe refusal]
  C --> F[Service restoration and recorded outcome]
  D --> F
  E --> F
  G[Migration completion receipts] --> H[Current warning display]
  F --> H
Loading

Before merge

  • Add data-model compatibility proof - Confirm migration or upgrade compatibility proof before merge.
Agent review details

Security

None.

PR surface

Source +307, Tests +658, Docs +3. Total +968 across 41 files.

View PR surface stats
Area Files Added Removed Net
Source 21 536 229 +307
Tests 17 1724 1066 +658
Docs 3 31 28 +3
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 41 2291 1323 +968

Review metrics

Metric Value Why it matters
Production growth justification Production net +307; tests/support net +658 The body accounts for classification across update entrypoints, worker-owned receipt reads and event ordering, while removing the serving-only special case.

Stored data model

Persistent data-model change detected: migration/backfill/repair: src/cli/update-cli/update-command-fresh-doctor.ts, migration/backfill/repair: src/commands/doctor-agent-lease-refusal.ts, migration/backfill/repair: src/commands/doctor-maintenance-inspection.ts, migration/backfill/repair: src/commands/doctor-maintenance-stale-service.ts, migration/backfill/repair: src/commands/doctor-maintenance.ts, migration/backfill/repair: src/commands/doctor-update-run.ts, and 7 more. Confirm migration or upgrade compatibility proof before merge.

Root-cause cluster

Relationship: fixed_by_candidate
Canonical: #153377
Summary: This PR is the explicit implementation candidate for the update-repair contention report; adjacent merged restoration work does not replace it.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Technical review

Best possible solution:

Keep Doctor authoritative for maintenance safety, preserve pending recovery obligations, and derive current notices from explicit completion receipts.

Do we have a high-confidence way to reproduce the issue?

Yes, source inspection establishes the stale-warning path, and the supplied real contention runs establish the repair failure scenario; this read-only review did not execute current main.

Is this the best way to solve the issue?

Yes. The patch extends the existing maintenance and event owners, preserves unsafe refusals, and filters diagnostics without adding a competing store or migration.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 9c87f193a96f.

Labels

Label changes:

No label changes.

Label justifications:

  • P0: The linked official-release report describes a blocked update-recovery path requiring technical intervention, meeting the update UX override.
  • rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🦞 diamond lobster and patch quality is 🦞 diamond lobster.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (live_output): The complete captured body records real systemd repair/restoration and a published 2026.9.5 updater-to-candidate run with warning retention, unchanged pending obligations and healthy replacement Gateway. These earlier-head observations are supplemented by current refusal and worker-order regressions. The completion projection changes no stored-data contract, so no migration is required.
  • proof: sufficient: Contributor real behavior proof is sufficient. The complete captured body records real systemd repair/restoration and a published 2026.9.5 updater-to-candidate run with warning retention, unchanged pending obligations and healthy replacement Gateway. These earlier-head observations are supplemented by current refusal and worker-order regressions. The completion projection changes no stored-data contract, so no migration is required.

Evidence

What I checked:

  • Introduced patch and merge identity: Reviewed the pinned merge-base-to-head changes. Raw test-merge records confirm the supplied base followed by the exact PR head; inspected merge-result hunks retain the warning filter and event-order repair. (5b702d5e24c7)
  • Maintenance classification preserves refusal boundaries: Doctor compensates for its own stopped service before classifying admission failures. Caller-authority failures, cancellation and unsettled cleanup remain terminal; callers consume the typed deferred outcome without continuing convergence. (src/commands/doctor-maintenance.ts:414, 39fd8af00a1d)
  • Read-only warning projection: The new worker operation selects existing completed migration IDs and timestamps. The display filter preserves later, unresolved and reintroduced warnings; neither the migration writer nor stored history format changes. (src/infra/deferred-plugin-migrations.ts:148, 39fd8af00a1d)
  • Published-driver and native recovery evidence: Retrieved the complete PR body and verified its 41,864 UTF-16 units and captured SHA-256 648f3f9d62778ecc910854a06bc39320526e5f1c35aa087ff5e3719bec345e0f. Historical head 91c3bb9 records real user-systemd repair with and without --no-restart, restored Gateway PID/RPC health, retained pending obligations, and an immutable 2026.9.5 updater-to-candidate run completing in 114.556 seconds. These are explicitly earlier-head observations, supplemented by subsequent refusal and current-head regression evidence. (91c3bb922791)
  • Upgrade refusal protects existing state: The regression exercises the parent-owned continuation against a real version-16 database and coordinator contention, asserting unchanged schema and pending rows, no plugin dispatch, and a recorded warning. This supports the published-driver evidence and resolves the previous generic migration-proof concern. (src/cli/update-cli/update-command-doctor-authority-callers.test.ts:233, 39fd8af00a1d)
  • Task observer ordering: Deferred observer publication stays in the existing accepted-event FIFO, retains its marker during reentrant dispatch, and rechecks publication identity. The new regression uses the production worker operation with a held committed receipt. The body reports three original-shard passes and 598 owner/PR tests against the final candidate tree. (src/tasks/task-registry-agent-events.ts:564, 39fd8af00a1d)

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • Jason (Json): Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • Vincent Koc: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (7 earlier review cycles)
  • reviewed 2026-09-22T03:51:34.955Z sha 7d247e4 :: needs maintainer review before merge. :: none
  • reviewed September 22, 2026, 12:47 AM ET / 04:47 UTC (Revision 2) sha unknown :: blocked before merge. :: none
  • reviewed 2026-09-22T05:47:51.703Z sha 91c3bb9 :: needs maintainer review before merge. :: none
  • reviewed 2026-09-22T08:47:42.641Z sha 2e5ee9c :: blocked before merge. :: none
  • reviewed 2026-09-22T10:36:14.627Z sha 45aa5f7 :: needs changes before merge. :: none
  • reviewed 2026-09-22T13:18:35.821Z sha b0082f6 :: blocked before merge. :: none
  • reviewed 2026-09-22T18:51:31.073Z sha cb736f0 :: blocked before merge. :: none

@steipete
steipete marked this pull request as ready for review September 22, 2026 05:40
@github-actions

github-actions Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

⚠️ Security sensitive changes

This maintainer PR changes sensitive security components. This comment is informational because the PR author has repository Maintain or Admin access.

  • Current SHA: 39fd8af00a1daf2c98c645c4a93b3569fcfada5f
  • Maintainer: @steipete
  • Repository role: admin

These security sensitive changes were made:

  • src/logging/diagnostic-support-redaction.ts: Controls credential persistence, secret resolution, or redaction. Check storage permissions, credential scope, and exposure in logs or responses.

Carefully review these changes before merging.

@steipete
steipete enabled auto-merge (squash) September 22, 2026 05:46
@steipete
steipete disabled auto-merge September 22, 2026 06:21
@steipete
steipete force-pushed the upd/repair-restart-before-doctor branch from 91c3bb9 to 2e5ee9c Compare September 22, 2026 08:35
@steipete
steipete enabled auto-merge (squash) September 22, 2026 08:40
@clawsweeper clawsweeper Bot added rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. labels Sep 22, 2026
@steipete
steipete disabled auto-merge September 22, 2026 09:17
@steipete
steipete force-pushed the upd/repair-restart-before-doctor branch from 2e5ee9c to 45aa5f7 Compare September 22, 2026 10:26
@steipete
steipete force-pushed the upd/repair-restart-before-doctor branch from 45aa5f7 to 9b989f2 Compare September 22, 2026 11:30
@steipete
steipete enabled auto-merge (squash) September 22, 2026 11:34
@steipete
steipete disabled auto-merge September 22, 2026 12:17
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 23, 2026
…otices (openclaw#155389)

* fix(update): defer safe Doctor refusals and resolve stale migration warnings

* fix(update): preserve deferred maintenance across installed drivers

Carry typed refusals through Doctor IPC and admit parent-owned continuation before plugin state preparation. Keep migration receipt reads in the existing state worker.

* fix(update): preserve unsafe maintenance and observation fences

* fix(doctor): preserve released driver refusal recovery

* test(doctor): split maintenance refusal settlement cases

* fix(tasks): preserve accepted completion event order

Keep native successor observers behind committed worker events in the existing accepted FIFO, including reentrant listeners. Preserve durable settlement and the backing-first event contract.
@roboclaw-bot roboclaw-bot mentioned this pull request Sep 24, 2026
2 of 8 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli CLI command changes commands Command implementations docs Improvements or additions to documentation maintainer Maintainer-authored PR P0 Emergency: data loss, security bypass, crash loop, or unusable core runtime. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. security-sensitive-changed size: XL status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: update repair self-contends at finalize:doctor while owning gateway-lifecycle

1 participant