Skip to content

fix(update): avoid stale retry advice after a newer update - #146982

Merged
vincentkoc merged 1 commit into
mainfrom
fix/update-historical-expiry-notice-20260913
Sep 15, 2026
Merged

vincentkoc merged 1 commit into
mainfrom
fix/update-historical-expiry-notice-20260913

Conversation

@vincentkoc

@vincentkoc vincentkoc commented Sep 13, 2026 •

Copy link
Copy Markdown
Member

Related: #143774
Related audit context: #144739, #144742

Additional instructions

This branch is in the upstream repository and is editable by maintainers.

What Problem This Solves

Fixes an issue where users checking update status would still be told to retry an expired 2026.9.2-era attempt after a newer update had succeeded or while another update was active. The old attempt's advisory was displayed alongside the current run without distinguishing history from current recovery guidance.

Why This Change Was Made

The shared status projection now compares the expired attempt's ID with the active or latest run. It labels an older attempt as historical and offers retry guidance when the expired attempt is current. This applies consistently to openclaw update status, its JSON output, and the update rows in openclaw status.

The abandonment record and detailed per-run recovery guidance remain intact. The existing 24-hour expiry rules and recovery protections are unchanged. This follow-up corrects status wording; the separate schema-owner and retained-handoff incidents linked above remain outside its scope.

User Impact

Operators can distinguish an old abandoned attempt from the update they are currently inspecting. A later successful update no longer carries an unnecessary retry prompt, while the historical outcome remains visible.

Evidence

Source: 0d71e62899b512f14e1791f4fbaf8ade5229cf65.

  • Baseline owner control: 9 expected failures, 3 passing current-run controls, and 23 unrelated tests filtered out. The same misleading advice exists in the v2026.9.4 source.
  • Candidate: 57 focused tests passed (35 CLI status, 20 run-report, 2 status-JSON). The 12-case regression matrix covers no newer run, success before expiry, success after expiry, and an active newer run across JSON, text, and general status. Repeated reads preserve the expired record and the selected current run.
  • All 30 selected changed-file checks passed across the initial run and an exact-source continuation. The first run stopped at dead-code analysis after 20 passes; the continuation ran the remaining 10 checks with the existing timeout unchanged.
  • Full normal pnpm build passed in 289.556 seconds, including declarations, SDK, UI, bootstrap, and postbuild steps. The continuation finished on September 13, 2026 at 11:30:26 UTC; all 41,618 source files matched the original manifest afterward.
  • Independent source review and a fresh native source review completed with no actionable findings. The native review completed one pass on this exact head with source and input verification. Production LOC: +5/-1 (net +4) for the current-versus-historical distinction; tests: +37/-12; docs: +3/-2.

Proof used an isolated source capsule through the local fallback after remote backend failures. It covers status/reporting and the normal build, not a published-driver upgrade or the separate recovery incidents. The retained 57 local tests, 30 selected checks, and 289.556-second normal build remain the qualification evidence for this change.

Keep legacy admission history visible after another update succeeds or becomes active. Only the selected expired run keeps retry instructions; historical notices describe the recorded outcome without prescribing another update.

Related: #144739
@vincentkoc vincentkoc self-assigned this Sep 13, 2026
@clawsweeper

clawsweeper Bot commented Sep 13, 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 size: S maintainer Maintainer-authored PR labels Sep 13, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. 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. labels Sep 13, 2026
@clawsweeper

clawsweeper Bot commented Sep 13, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 15, 2026, 4:24 AM ET / 08:24 UTC (Revision 5).

ClawSweeper review

What this changes

The PR distinguishes historical abandoned updates from the current run in CLI status advice, with matching documentation and regression coverage.

Merge readiness

✅ Ready for maintainer review

This remains a useful, focused fix: current main and v2026.9.4 still emit unconditional retry advice for historical expired runs. No actionable patch defects were found; the linked recovery incidents concern separate behavior.

Priority: P2
Reviewed head: 0d71e62899b512f14e1791f4fbaf8ade5229cf65

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused owner-level correction with meaningful regression coverage and no actionable correctness or security findings.
Proof confidence 🌊 off-meta tidepool Not applicable: The MEMBER-authored PR is exempt from the external-contributor proof gate. Its evidence covers the status projection through focused tests and build checks; the earlier reconciliation screenshots do not demonstrate this wording change, and no published-driver upgrade claim is made.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The MEMBER-authored PR is exempt from the external-contributor proof gate. Its evidence covers the status projection through focused tests and build checks; the earlier reconciliation screenshots do not demonstrate this wording change, and no published-driver upgrade claim is made.
Evidence reviewed 7 items Introduced change verified: The merge-base-to-head diff matches the supplied introduction evidence. The production change only selects advisory text by comparing the expired run ID with activeRun or lastRun; reconciliation, persistence, and recovery authority remain unchanged.
Current main still needs the fix: Reading the complete status projection at fetched main showed unconditional LEGACY_UPDATE_RUN_ADVISORY assignment. Comparing this file against the pinned merge base produced no changes.
Latest release retains the behavior: The v2026.9.4 version of the status projection also assigns retry advice unconditionally. The inspected release tag resolves to the supplied release commit.
Findings None None.
Security None None.

How this fits together

Update status reads the durable update ledger and selects the active or latest run. Its shared projection supplies human-readable and JSON status output while retaining notices about older expired attempts.

flowchart TD
  A[Update run history] --> B[Existing legacy expiry reconciliation]
  B --> C[Select active or latest run]
  C --> D{Expired attempt is current?}
  D -->|Yes| E[Retry guidance]
  D -->|No| F[Historical notice]
  E --> G[CLI status and JSON output]
  F --> G
Loading

Before merge

None.

Agent review details

Security

None.

PR surface

Source +4, Tests +25, Docs +1. Total +30 across 3 files.

View PR surface stats
Area Files Added Removed Net
Source 1 5 1 +4
Tests 1 37 12 +25
Docs 1 3 2 +1
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 3 45 15 +30

Review metrics

Metric Value Why it matters
Regression scenarios 4 history states × 3 output surfaces The matrix checks both expiry/update orderings and preserves retry guidance when the expired run remains current.

Technical review

Best possible solution:

Keep historical outcomes visible while reserving retry advice for the selected expired run, using the existing shared status projection.

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

Yes, from source: an expired legacy record plus a newer successful or active run still produces retry advice on current main. Runtime reproduction was not executed in this read-only review.

Is this the best way to solve the issue?

Yes. Changing the shared advisory projection addresses all affected status outputs without changing stored history, expiry eligibility, or detailed per-run recovery guidance.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 04400e289e10.

Labels

Label justifications:

  • P2: Misleading retry advice is a bounded operator-facing defect; this patch does not change update execution or availability.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: The MEMBER-authored PR is exempt from the external-contributor proof gate. Its evidence covers the status projection through focused tests and build checks; the earlier reconciliation screenshots do not demonstrate this wording change, and no published-driver upgrade claim is made.

Evidence

What I checked:

  • Introduced change verified: The merge-base-to-head diff matches the supplied introduction evidence. The production change only selects advisory text by comparing the expired run ID with activeRun or lastRun; reconciliation, persistence, and recovery authority remain unchanged. (src/infra/update-run-status.ts:43, 0d71e62899b5)
  • Current main still needs the fix: Reading the complete status projection at fetched main showed unconditional LEGACY_UPDATE_RUN_ADVISORY assignment. Comparing this file against the pinned merge base produced no changes. (src/infra/update-run-status.ts:43, 04400e289e10)
  • Latest release retains the behavior: The v2026.9.4 version of the status projection also assigns retry advice unconditionally. The inspected release tag resolves to the supplied release commit. (src/infra/update-run-status.ts:43, 3a9d69db306c)
  • Shared output and recovery boundaries: CLI text prints historical advisories separately from the selected run report; CLI JSON and general status consume the same projection. The unchanged per-run report retains recovery guidance, and the reader orders runs by creation time rather than reconciliation time. (src/cli/update-cli/status.ts:148, 0d71e62899b5)
  • Meaningful regression coverage: The complete test module was inspected. Its 12-case matrix covers current expired history, success before expiry, success after expiry, and another active run across three output surfaces; repeated reads preserve the record and selected run. The body reports 57 focused passing tests and a successful build; these were not rerun during this read-only review. git diff --check passed. (src/cli/update-cli/status.test.ts:334, 0d71e62899b5)
  • Feature-history routing: Blame and file history connect this projection to ac266cd. Its raw commit records parent 1e3a22b; comparison against that parent confirms the projection was added there. Nearby history also includes the shared run-report and status-availability work. (src/infra/update-run-status.ts:26, ac266cd34ee0)

Likely related people:

  • Peter Steinberger: Raw commit ac266cd adds src/infra/update-run-status.ts:26 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: ac266cd34ee0; files: src/infra/update-run-status.ts)

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 (4 earlier review cycles)
  • reviewed 2026-09-13T11:38:57.545Z sha 0d71e62 :: needs maintainer review before merge. :: none
  • reviewed 2026-09-13T15:49:50.632Z sha 0d71e62 :: needs maintainer review before merge. :: none
  • reviewed 2026-09-15T03:33:26.828Z sha 0d71e62 :: needs maintainer review before merge. :: none
  • reviewed 2026-09-15T08:04:25.402Z sha 0d71e62 :: needs maintainer review before merge. :: none

@vincentkoc
vincentkoc marked this pull request as ready for review September 15, 2026 03:25
@vincentkoc
vincentkoc merged commit ebe2fd5 into main Sep 15, 2026
285 checks passed
@vincentkoc
vincentkoc deleted the fix/update-historical-expiry-notice-20260913 branch September 15, 2026 08:57
@vincentkoc

Copy link
Copy Markdown
Member Author

Merged via squash.

vincentkoc added a commit that referenced this pull request Sep 15, 2026
* commit '0cd944c01416c4f9c1f6dc9d1dea9670c5b99cab':
  improve: speed up session search for restricted operators (#148826)
  fix(update): avoid retry guidance for historical abandoned runs (#146982)
  fix(android): reduce queued-message send overhead (#148899)
  refactor(slack): count table cells only for native output (#148872)
  fix: correct update status and apply saved model keys (#148830)
  refactor(nostr): share doctor state migration flow (#148647)
  refactor(gateway): centralize device token denial responses (#148644)
  test: make kitchen sink assertions runtime portable (#148891)
  refactor(agents): share preferred block chunk boundaries (#148391)
  fix(ui): use the selected timezone for Usage date shortcuts (#148277)
  test: probe active Node in release preflight (#148892)
  fix(test): restore services typecheck shard headroom (#148889)
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 16, 2026
…claw#146982)

Keep legacy admission history visible after another update succeeds or becomes active. Only the selected expired run keeps retry instructions; historical notices describe the recorded outcome without prescribing another update.

Related: openclaw#144739
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli CLI command changes docs Improvements or additions to documentation maintainer Maintainer-authored PR P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: S 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.

1 participant