Skip to content

fix(update): preserve original state before direct updates - #161044

Merged
steipete merged 8 commits into
mainfrom
codex/original-update-capture-integration
Sep 29, 2026
Merged

steipete merged 8 commits into
mainfrom
codex/original-update-capture-integration

Conversation

@steipete

@steipete steipete commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor

Related: #144005 and #145169; both remain open. Follow-up to merged #160614, whose changes are excluded from this PR.

What Problem This Solves

Direct updates and Doctor repairs can change configuration or relocate state before retaining the originals needed to investigate a failed upgrade. Taking that capture before normal update admission must also preserve existing refusal history and diagnostics.

User Impact

The installed CLI attempts to retain original configuration/includes, SQLite databases, and declared plugin/Workshop resources before direct update initialization or standalone Doctor repair. Doctor continuations preserve the original reference across relocation. Update status distinguishes manual and incomplete captures and requires matching restoration evidence before reporting an original capture restored.

Early refusals retain their history, structured failure facts, and correct managed-installation context. If pre-admission ownership cannot be released, the command reports a pending error without writing the ledger. Configured updater-local HTTP tracing stays deferred. Fresh updates and dry runs report that deferral; dry-run notices go to stderr so JSON output remains parseable. Doctor may enable its own capture after schema readiness.

Captures are manual recovery evidence, not an atomic snapshot across active stores or an automatic legacy/full-state rollback. Capture failures can remain warnings. Older installed updaters and inherited update paths retain their stated limitations.

Why This Change Was Made

Reuse the existing v2 manifest, raw database backup, inventory, executor, maintenance, and update-ledger owners. Capture does not invent ownership for legacy registry entries, and delayed admission does not discard preflight diagnostics. No new restoration controller or tracing owner is introduced.

Thanks to Jason (Json), @fuller-stack-dev, for the original recovery work.

Follow-up #161292 landed as f70c61dba0c1fa82b75fe46609cd2fcba345bd0e, resolving the remaining status-guidance finding. Unresolved captures now name the retained manifest, ask operators to preserve current state, and link the existing manual recovery documentation. This finding concerned guidance; no data, recovery, or authority defect was identified. The follow-up records its focused proof and the independently attributed pre-existing CI fixture failures.

Evidence

The published refusal repair at 1904ffc8543f4b840e37b8808944bc7ce0535abe passed 171/171 tests across six full files in 387.724 s, with no filtered cases, and fresh independent P2 review was scoped-clean. Earlier complete selected checks passed in 778.396 s; the later delta separately passed production/CLI types, scoped lint, line-cap, assertion-safety, and whitespace checks in 86.664 s. These separate receipts are not presented as one final full-check run. The successor dd1f009d230ca437e734c91af592a02e8390c053 moves only the shared admission type: both cycle checks, core/CLI types and scoped lint passed in 81.018 s, with fresh scoped-clean review. Exact hashes bind those three checked files to the published successor; runtime statements are unchanged.

Causal tests exposed missing refusal history, the redirected capture's wrong installation root, and incorrect repair classification of nonmutating capture diagnostics before the owning fixes. The fresh installed metadata-refusal cell passed on that source (run). The unmodified installed CLI returned the expected exit 1 with target-registry-metadata; status exited 0 and identified the same finished, failed run with no active update. The sealed capture retained the exact prior history row, while live history contained that unchanged row plus one new failed row. Original configuration, resource bytes and raw application/plugin rows remained exact; no candidate or Doctor update steps ran. The refusal took 13.194 s, status 4.455 s, and the full package/proof wrapper 803.192 s. Independent raw audits verified the package, manifest and all five payloads. The capture listing remained ambiguous because setup Doctor had also retained a manual capture; no restoration was claimed.

The executed package was built from 1904ffc8543f4b840e37b8808944bc7ce0535abe, SHA-256 fe6005a71cd4c2e9aec05ce1023007fedf1966078923ab47c4fc9019d380e11a. This is applicable runtime evidence for the type-only dd1f009d successor, not a package execution of that later head. The final notice correction adds dry-run stderr output; applicability of this installed proof is limited to the unchanged mutation, refusal, and upgrade paths. The new dry-run behavior has separate owner-test evidence below. Its lease is stopped.

The prior 1904ffc8 CI was cancelled after its Madge type-import cycle failure; that cycle is now repaired. The previous-head CI run for dd1f009d was cancelled after a queued-registration test failure. The affected group recorded 58 failed tests and 34 unhandled errors, including a missing mocked read-context export. The first failure was the unchanged queued-registration fixture omitting captureOpenClawStateReadContext. All 11 relevant source inputs match the tested main baseline, and a separate main-only reproduction established the same defect. The fixture-only repair is on main at 9e4f20185d77a9ac3e054a4ed22f21f9ed490cc1; it independently passed 62/62 cases and its 30-file, 515-case group. Those results are not a rerun of this PR’s 29-file Linux job, and the 77 cancelled jobs are not passing coverage. That exact-head failure evidence is retained, but it is not a CI exception for the new e00db124 commit. Current-head CI run, attempt 1 for e00db124, was cancelled after one failure in config-model-validation.runtime.test.ts: preparing the uncataloged fixture provider reached Shared-state admission requires the host broker. Its CLI group recorded 2,029 passed, 1 failed, 23 skipped across 103 files in 187.61 s. The run has 40 successful, 101 cancelled, 17 skipped, and 2 failed jobs, including the downstream aggregate. Compared with the tested main baseline, the failing test and production inputs are unchanged. Independent source/routing inspection attributes the failure to main’s async-metadata migration in #161201, which omitted this test from the host-broker inventory. This PR’s two unrelated inventory additions do not change its membership. The canonical fixture repair is on main at 313f6211d406aeda2b8b1108883713e1e5f97d5e. Native verification of the exact pre-existing failure and live authority/security/review gates passed; the 101 cancelled jobs remain unrun coverage. The native workflow retired the auto-merge request and merged the same reviewed head as e47d0ce4 through the explicitly authorized pre-existing CI exception. Failed and cancelled CI remains recorded as such; no current-head CI success is claimed. The separate earlier session-retirement main regression was fixed by 28885d3f8745f51e39ecb54389283dc391c15381.

The final notice correction is published at e00db124b77c4266c35a9b487279d2278c51bb3c. The regression first failed both configured-tracing JSON and text previews while the disabled row passed (103.212 s). The complete preview owner now passes 10/10 cases in 49.477 s, with no filtered or skipped cases. The four-file delta adds four production lines, extends existing preview assertions, documents tracing deferral, and corrects a stale capacity-refusal history expectation. The initial already-current run retained 31 passing / 1 failing cases: the stale assertion expected no new row after the earlier refusal-history repair. Its replacement requires exactly one finished, failed snapshot-capacity-insufficient row, the matching JSON run ID, unchanged prior history, and the existing no-staging assertions. The corrected complete already-current owner passed 32/32 cases in 112.277 s, with no filtered or skipped cases. Core and CLI test types, scoped lint, four-file formatting, runtime cycles, line limits, assertion safety, and whitespace checks all passed in 124.680 s with unchanged source hashes. Fresh independent P2 review was scoped-clean with no findings; its sandbox lacked unchanged repository files, which the maintainer inspected directly. The four committed file blobs match the proof and review freeze. Existing-profile dry-runs can record diagnostic ledger history; fresh-state previews still avoid creating the database.

Qualified installed evidence

A published 2026.9.6 updater driving candidate source a4a9e950 passed on Crabbox/Blacksmith Testbox (run): 13/13 core steps succeeded, two genuine Cron histories and their transcripts survived, approvals remained exact, and Doctor reported 37 checks run, 30 skipped, zero findings. Update wall time was 209.644 s; the single scenario took 497 s, and the full wrapper including package/registry preparation took 1,164.892 s. Independent raw-artifact audits qualified that source and candidate tarball SHA-256 950b27751cc39cc9cac0ea475604dc58cf1f491f286afc3cfb632621ded73821. This is historical execution, not an execution of the later refusal repair.

That cell used a mock provider and isolated service-manager fixture with actual process replacement. It does not establish live-provider behavior or host-native service deployment. Backup restoration was a separate operation into staging, not automatic failure rollback. Its lease is stopped.

The earlier direct-capture matrix at source f31ac629 also passed (run and environment):

Installed case Observed result Command wall
Shared database initially absent, tracing configured Absence captured before bootstrap; successful update and original reference forwarded to Doctor 249.373 s
Existing shared state and genuine update history Original configuration/includes, resources, raw SQLite values and pre-command history preserved 211.774 s
Standalone Doctor/plugin migration Capture verified before writes; originals retained; status distinguishes manual and incomplete evidence 16.534 s

Audits checked hashes, large rowids, opaque text, BLOB/NULL values, and real history created by an installed dry-run. These were synthetic same-schema package targets with a read-only Doctor observer. Automatic artifact collection failed after product assertions passed; required evidence was recovered and audited separately, so the linked run is not described as green CI. No inherited/helper capture, installed default-directory relocation, inference, or automatic full-state recovery claim is made. Raw diagnostics remain private.

Earlier failed and interrupted runs remain distinct from passing evidence: an incomplete installation fixture, wrapper inventory omission, strict diagnostic-step assertions, refusal-history loss, and the separate main regression were investigated rather than rerun to obtain green.

Other measured focused proof

Single-worker wall time includes runtime preparation. These earlier groups retain their original scope and source bindings.

Run Result Wall
Wrapper inventory and invalid-config assertion repair 23 passed 117.254 s
Selected checks for that two-file repair Passed 625.283 s
Capture/update composition 109 passed 175.295 s
Selected checks for that composition Passed 1,025.764 s
Earlier capture/Doctor/status/CLI/build-contract group 196 passed 372.274 s
Earlier selected checks Passed 1,486.806 s
Contention fixture correction 6 passed 53.725 s

steipete and others added 2 commits September 28, 2026 20:51
Retain manual recovery evidence before direct update initialization and
Doctor state relocation, and carry the original reference through delegated
Doctor calls. Reuse the existing capture format, maintenance custody and
configuration reader, while deferring debug persistence until admission.

Distinguish manual and incomplete captures, and report restoration only
from evidence bound to the same manifest. Published legacy and inherited
updaters retain their existing limits; this does not add automatic restore.

Co-authored-by: Jason (Json) <[email protected]>
Keep fresh original-state capture out of self-contained recovery helpers,
which consume retained evidence. Preserve the normal CLI and Doctor capture
checks and forwarded references while integrating the landed history repair.

Co-authored-by: Jason (Json) <[email protected]>
@clawsweeper

clawsweeper Bot commented Sep 29, 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 labels Sep 29, 2026
@clawsweeper clawsweeper Bot added P1 High-priority user-facing bug, regression, or broken workflow. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Sep 29, 2026
@clawsweeper

clawsweeper Bot commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge. Reviewed September 29, 2026, 12:07 PM ET / 16:07 UTC (Revision 12).

ClawSweeper review

What this changes

Direct updates and standalone Doctor repairs retain original configuration, SQLite databases, and declared resources, then report capture status and deferred HTTP tracing through the CLI.

Merge readiness

⛔ Blocked before merge - 3 items remain

Keep open: current main lacks the direct original-state capture path, and this branch has evidence of the intended update behavior. One confirmed recovery-status guidance defect remains before merge.

Priority: P1
Reviewed head: e00db124b77c4266c35a9b487279d2278c51bb3c

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The central behavior has substantial installed-path evidence, but the confirmed status-guidance defect keeps the patch below merge-ready quality.
Proof confidence 🦞 diamond lobster (5/6) Sufficient (live_output): The installed CLI scenarios described in the PR body exercise the production update and Doctor capture path and report retained original bytes, history, and status after a refusal. Their source identities precede the final head; the final dry-run notice has focused CLI-test evidence rather than another installed run. No stored-data format change requires migration.
Patch quality 🦐 gold shrimp (3/6) 1 actionable review finding remain.

Verification

Check Result Evidence
Real behavior Verified Sufficient (live_output): The installed CLI scenarios described in the PR body exercise the production update and Doctor capture path and report retained original bytes, history, and status after a refusal. Their source identities precede the final head; the final dry-run notice has focused CLI-test evidence rather than another installed run. No stored-data format change requires migration.
Evidence reviewed 8 items Current main lacks the direct capture entry point: The current-main update command enters initialization only when state needs initialization; the PR adds a separate direct-update capture path. A search of current-main update and Doctor sources found no new baseline-capture entry point.
Introduced capture path: The PR-head command selects direct invocations for original capture and passes that decision to initialization before the admitted update runs.
Prior finding remains on this head: For an unresolved sealed capture, the inspector sets nextAction to the same status command that renders the row; the existing recovery test asserts this value. The prior completed ClawSweeper review identified the same defect at this exact head.
Findings 1 actionable finding [P2] Give unresolved captures a useful recovery action
Security None None.

How this fits together

The installed updater and Doctor receive the selected installation, configuration, and state directories. They retain recovery evidence before repair or update work, record the outcome, and present it through update status.

flowchart LR
A[Direct update or Doctor repair] --> B[Maintenance admission]
B --> C[Original state capture]
C --> D[Private manifest and payloads]
B --> E[Update or repair]
D --> F[Run ledger and status]
E --> F
F --> G[Manual recovery guidance]
Loading

Before merge

  • Give unresolved captures a useful recovery action (P2) - When a failed run has one sealed unresolved capture, this sets nextAction to openclaw update status --json. Text and JSON status then direct the user back to the command that produced the same row, without a recovery step. Provide safe guidance for preserving current state and inspecting the retained capture, and assert both outputs.
  • Complete next step (P2) - Replace the self-referential action for unresolved captures with safe manual recovery guidance, and assert text and JSON status output.
  • Add data-model compatibility proof - Confirm migration or upgrade compatibility proof before merge.

Findings

  • [P2] Give unresolved captures a useful recovery action — src/infra/update-recovery-backup-status.ts:98
Agent review details

Security

None.

PR surface

Source +1433, Tests +1114, Docs +36, Other +1. Total +2584 across 63 files.

View PR surface stats
Area Files Added Removed Net
Source 40 2237 804 +1433
Tests 21 1291 177 +1114
Docs 1 36 0 +36
Config 0 0 0 0
Generated 0 0 0 0
Other 1 1 0 +1
Total 63 3565 981 +2584

Review metrics

Metric Value Why it matters
Production and test LOC production +2571/-827; tests +957/-154; other +37 The stated capture and reader ownership work explains the substantial production growth, which merits focused boundary review.

Stored data model

Persistent data-model change detected: migration/backfill/repair: src/cli/update-cli/update-command-fresh-doctor.ts, migration/backfill/repair: src/cli/update-cli/update-command-initialization-types.ts, migration/backfill/repair: src/cli/update-cli/update-command-run.ts, migration/backfill/repair: src/commands/doctor-maintenance-admission.ts, migration/backfill/repair: src/commands/doctor-maintenance-inspection.ts, migration/backfill/repair: src/commands/doctor-maintenance-state.ts, and 5 more. Confirm migration or upgrade compatibility proof before merge.

Technical review

Best possible solution:

Keep the private capture and existing recovery owner, and give unresolved sets a safe manual path to preserve current state and inspect the retained manifest and payloads.

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

Yes. On this PR head, a failed run with one sealed unresolved capture deterministically emits the same status command as its next action; the existing test asserts that value. This read-only review did not execute the test.

Is this the best way to solve the issue?

No. The capture boundary is appropriate, but unresolved recovery status needs safe inspection guidance rather than a command that repeats the same output.

Full review comments:

  • [P2] Give unresolved captures a useful recovery action — src/infra/update-recovery-backup-status.ts:98
    When a failed run has one sealed unresolved capture, this sets nextAction to openclaw update status --json. Text and JSON status then direct the user back to the command that produced the same row, without a recovery step. Provide safe guidance for preserving current state and inspecting the retained capture, and assert both outputs.
    Confidence: 0.96

Overall correctness: patch is incorrect
Overall confidence: 0.92

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 42700f9d92dc.

Labels

Label changes:

No label changes.

Label justifications:

  • P1: Preserving recoverable state during real update failures is an urgent existing user workflow.
  • merge-risk: 🚨 compatibility: Configured HTTP tracing remains disabled in the updater process; the discussion explicitly accepts that limitation with a visible notice.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦞 diamond lobster and patch quality is 🦐 gold shrimp.
  • status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action. Sufficient (live_output): The installed CLI scenarios described in the PR body exercise the production update and Doctor capture path and report retained original bytes, history, and status after a refusal. Their source identities precede the final head; the final dry-run notice has focused CLI-test evidence rather than another installed run. No stored-data format change requires migration.
  • proof: sufficient: Contributor real behavior proof is sufficient. The installed CLI scenarios described in the PR body exercise the production update and Doctor capture path and report retained original bytes, history, and status after a refusal. Their source identities precede the final head; the final dry-run notice has focused CLI-test evidence rather than another installed run. No stored-data format change requires migration.

Evidence

Acceptance criteria:

  • [P1] node scripts/run-vitest.mjs src/cli/update-cli/status.recovery.test.ts --maxWorkers=1.
  • [P1] node scripts/check-changed.mjs --dry-run -- src/infra/update-recovery-backup-status.ts src/cli/update-cli/status.recovery.test.ts.
  • [P1] git diff --check.

What I checked:

  • Current main lacks the direct capture entry point: The current-main update command enters initialization only when state needs initialization; the PR adds a separate direct-update capture path. A search of current-main update and Doctor sources found no new baseline-capture entry point. (src/cli/update-cli/update-command.ts:105, 42700f9d92dc)
  • Introduced capture path: The PR-head command selects direct invocations for original capture and passes that decision to initialization before the admitted update runs. (src/cli/update-cli/update-command.ts:115, e00db124b77c)
  • Prior finding remains on this head: For an unresolved sealed capture, the inspector sets nextAction to the same status command that renders the row; the existing recovery test asserts this value. The prior completed ClawSweeper review identified the same defect at this exact head. (src/infra/update-recovery-backup-status.ts:98, e00db124b77c)
  • Status renders the repeated action: Text output prints each recovery set's nextAction; JSON output includes that same field. (src/cli/update-cli/status.ts:423, e00db124b77c)
  • Qualified installed behavior evidence: The PR body records an installed-CLI metadata-refusal scenario built from 1904ffc: the prior history row and original payloads were retained, the failed run was recorded, and status reported it. The linked Testbox workflow is cancelled and exposes no artifact through the available read, so its overall conclusion is not a passing CI claim. Later head changes are described separately in the body. (1904ffc8543f)
  • Accepted tracing tradeoff: The PR discussion explicitly retains updater-parent HTTP tracing deferral with a visible notice; the head documents that limitation and reports it during dry runs. Public docs: docs/cli/update/repair-and-recovery.md. (docs/cli/update/repair-and-recovery.md:118, e00db124b77c)

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • fuller-stack-dev: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Replace the unresolved-set action with safe recovery guidance and assert the emitted text and JSON.

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 (11 earlier review cycles; latest 8 shown)
  • reviewed 2026-09-29T10:02:46.595Z sha a4a9e95 :: blocked before merge. :: none
  • reviewed 2026-09-29T10:43:59.269Z sha 3f94b66 :: blocked before merge. :: none
  • reviewed 2026-09-29T11:02:49.764Z sha 3f94b66 :: needs changes before merge. :: [P1] [P1] Preserve history for refusals before capture starts | [P2] [P2] Accept successful preflight steps in metadata assertions
  • reviewed 2026-09-29T12:40:16.090Z sha 1904ffc :: blocked before merge. :: none
  • reviewed 2026-09-29T13:01:55.723Z sha dd1f009 :: blocked before merge. :: [P2] Report disabled HTTP tracing for dry-run updates
  • reviewed 2026-09-29T13:49:44.016Z sha dd1f009 :: blocked before merge. :: [P2] Report tracing deferral on dry-run updates | [P2] Give unresolved recovery sets an actionable next step
  • reviewed 2026-09-29T15:35:20.811Z sha e00db12 :: needs changes before merge. :: [P2] Give unresolved captures a useful recovery action
  • reviewed 2026-09-29T15:51:28.343Z sha e00db12 :: needs changes before merge. :: [P2] Give unresolved captures a useful recovery action

@steipete steipete self-assigned this Sep 29, 2026
@steipete
steipete marked this pull request as ready for review September 29, 2026 07:10
@steipete

steipete commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor Author

The revision-3 visibility concern is addressed in 3f94b667dfa63bcc8a33ece886cd61f6f4717e0d. After the original capture attempt, the updater now uses its existing warning path to report when configured HTTP tracing is disabled in that process (source). The existing successful no-Doctor cases require exactly one notice when tracing is enabled and none when disabled (tests). The missing-notice regression failed with the warning omitted; both cases passed in the 109-test composed runtime group.

Maintainer disposition: retain the documented updater-parent tracing limitation with that visible notice. The earlier proposal to resume immediately after a snapshot remains rejected: additive update-ledger admission permits legacy schemas and does not establish current-schema admission for debug-store writes. Doctor retains responsibility for resuming capture only after maintenance readiness succeeds and schema publication is not deferred. A separate Doctor process cannot release the parent's asynchronous scope.

The original findings and their distinct dispositions remain visible. The tracing concern is resolved; current CI's separate history/refusal and session-retirement failures remain under repair and are not waived by this decision.

Preserve the real SQLite contention and history assertions by supplying package-manager ownership in the existing fixture mock. Clarify why updater debug persistence remains deferred until Doctor has admitted the schema.
@clawsweeper clawsweeper Bot added the proof: sufficient ClawSweeper judged the real behavior proof convincing. label Sep 29, 2026
Carry preflight diagnostics through original-state capture and ledger
admission, and retain structured capacity details when admission refuses.
Use the existing database inventory for legacy path-only registrations
without inventing ownership. Report configured updater tracing suppression
through the existing warning path.

Integrate current main's publication and predecessor-cleanup contracts,
and align the affected CLI fixtures with the actual admission boundary.

Co-authored-by: Jason (Json) <[email protected]>
@clawsweeper clawsweeper Bot added status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Sep 29, 2026
@openclaw-barnacle openclaw-barnacle Bot added the scripts Repository scripts label Sep 29, 2026
@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Sep 29, 2026
Capture originals before admitting refused updates to history. Preserve managed installation context and structured pending diagnostics without finalizing an uncertain run. Keep JSON refusals and ledger-only repair consistent with the recorded outcome.
@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. labels Sep 29, 2026
steipete added a commit that referenced this pull request Sep 29, 2026
Tell operators to preserve current state, inspect the retained manifest,
and consult the manual recovery guide instead of repeating update status.
Extend the existing status regression without changing classification or
recovery behavior.

Follow-up to #161044.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 30, 2026
…161044)

* fix(update): preserve original state before direct updates

Retain manual recovery evidence before direct update initialization and
Doctor state relocation, and carry the original reference through delegated
Doctor calls. Reuse the existing capture format, maintenance custody and
configuration reader, while deferring debug persistence until admission.

Distinguish manual and incomplete captures, and report restoration only
from evidence bound to the same manifest. Published legacy and inherited
updaters retain their existing limits; this does not add automatic restore.

Co-authored-by: Jason (Json) <[email protected]>

* test(update): admit contention fixture as an npm install

Preserve the real SQLite contention and history assertions by supplying package-manager ownership in the existing fixture mock. Clarify why updater debug persistence remains deferred until Doctor has admitted the schema.

* fix(tooling): include debug deferral in PR wrappers

* fix(update): preserve early refusal history and diagnostics

Capture originals before admitting refused updates to history. Preserve managed installation context and structured pending diagnostics without finalizing an uncertain run. Keep JSON refusals and ledger-only repair consistent with the recorded outcome.

* refactor(update): isolate initialization admission types

* fix(update): report tracing deferral during dry runs

Warn on stderr when the selected update environment enables HTTP capture,
while preserving tracing deferral and machine-readable JSON output. Extend
the existing preview controls and align the capacity refusal assertion
with the recorded failed-run contract.

---------

Co-authored-by: Jason (Json) <[email protected]>
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 30, 2026
Tell operators to preserve current state, inspect the retained manifest,
and consult the manual recovery guide instead of repeating update status.
Extend the existing status regression without changing classification or
recovery behavior.

Follow-up to openclaw#161044.
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 merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. P1 High-priority user-facing bug, regression, or broken workflow. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. scripts Repository scripts size: XL status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant