Skip to content

fix: release validation misses interrupted package upgrades - #167377

Merged
RomneyDa merged 6 commits into
mainfrom
fix/package-recovery-release-validation
Oct 8, 2026
Merged

RomneyDa merged 6 commits into
mainfrom
fix/package-recovery-release-validation

Conversation

@RomneyDa

@RomneyDa RomneyDa commented Oct 8, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

Fixes a release-validation gap: successful upgrades and same-version crash tests did not prove that a new package can recover a shipped updater’s interrupted publication and then update again.

User Impact

No direct runtime change. The standard reported-issues release plan now retains five recovery cells for the shipped strict readers, even after latest/previous release aliases advance. Runtime fixes are in #167330 and #167358, building on Scott’s merged repair.

Why This Change Was Made

Use the existing upgrade-survivor harness with actual published packages:

  • 9.8 and 9.9 write their own journal/helper, then SIGKILL immediately after committed publication; introduce metadata-only drift in the retained package.
  • 9.8 and 9.9 reach a real post-publication Doctor failure after retained-package bytes change.
  • The installed candidate must repair twice, preserve retained and live package bytes plus authored settings, then install a distinct-version tarball through the real updater.
  • A separate 9.7→9.8 interruption proves unchanged, already-stranded 9.8 refuses before opening a deliberately absent candidate. This is a negative control, not a claim that candidate-only code rescues that old updater.

Faults are external observers in disposable test processes, not production bypass flags or fabricated recovery journals. Live packages/journals use native runtime storage; diagnostic outputs use the artifact mount.

Evidence

  • Real published 9.8→9.9 probe reached publication-complete, SIGKILL exit 137, and metadata-only drift.
  • Full maintained negative-control cell passed: authentic 9.7 writer → interrupted 9.8 install → unchanged 9.8 update-recovery-pending before candidate access.
  • Planner, fault/oracle and sibling tests passed; the final integration run passed 11 tests in 9.45 s through the single-worker wrapper. Earlier 64 planner tests passed.
  • Typechecking, formatting, repository/dead-export guards and full script lint passed. The changed-file gate initially found two intentional unbound-method captures in the test observer; scoped receiver-preserving exceptions and their allowlist test resolved those findings, and script lint was rerun successfully.
  • Independent P0–P2 reviews of the harness and final behavioral integration delta found no actionable findings.
  • CI integration findings are corrected: exact-row grouping schedules each pinned recovery cell once; baseline preflight recognizes those rows; published/historical candidate soak inventory stays unchanged; frozen-target omissions account for the same pinned cells; copied diagnostics fixtures include the new helper.
  • The planner/contract/preflight correction passed 159 tests, plus 23 targeted boundary cases (six overlap), full changed-file gates and workflow validation. Independent P0–P2 review found no actionable findings.
  • ClawSweeper’s repeat-run finding is fixed: setup clears both cut and Doctor markers before arming this invocation. Regression reproduced red and the nine-case focused suite passed; full changed-file gates and independent P0–P2 review passed.
  • Final composed harness run passed 48 tests across fault/oracle, exact-row grouping, and baseline admission in 21.64 seconds.
  • The final scheduler suite passed 54 tests in 24.24 seconds after updating its two omission totals from 14 to 19 (the five pinned cells are now reported).
  • Resolved the main conflict at 9324ed61ca56 without dropping pinned cells or main scheduling priorities. Final conflict proof: 186 tests passed (Vitest 63.53 s; wrapper 68.81 s), shell syntax passed, and independent P0–P2 review found no actionable findings. Selected guards, formatting, root typechecks, script lint and test lint passed. The full changed-file gate has an inherited Knip failure for ClientVoiceToolEffect in src/talk/client-voice-session-store.ts; source, Knip inputs and symbol references match the incorporated main revision. That check is not claimed green.

The inspected 9.7→9.8 release qualification exercised successful upgrade paths. This adds the missing composition of a released writer, interruption/error, newer repair, and a subsequent update; it does not relabel previous happy-path runs as fault coverage.

Completed packed-candidate qualification (2026-10-08)

All five maintained Docker cells passed on their first attempt, with no timeout; final scheduler status is passed and cleanup joined. The parent independently reran assertPackageRecoveryEvidence on all five structured receipts.

Released writer / scenario Result Cell time
2026.9.8 / publication interruption Passed 930 s
2026.9.9 / publication interruption Passed 752 s
2026.9.8 / post-publication Doctor failure Passed 827 s
2026.9.9 / post-publication Doctor failure Passed 659 s
2026.9.7 → unchanged 2026.9.8 / stranded first hop Passed negative control 322 s

Positive cells used the exact composed candidate 1aa57206f693d5e2fbce607289d0bbeefbff32d1, tarball SHA-256 20f5375db04391e3155d1a1386843e8aeb80cade377193b71e7221e5b7d490f7. This is a local qualification package labeled 2026.9.9, not a published release. Runtime owners match #167330 at 2c6986b123f8ce44bbeb9c714ab20a3515a73a30 and #167358 at d3932c61a3517bb171d4c1242a2699897bae1ee8.

Each authentic released writer created its own journal and helper and reached publication-complete. Installed-candidate public repair and repeated repair exited 0. Full retained-tree inventory, identity and original helper digest, unchanged candidate bytes, and authored settings were preserved. Every positive cell then installed the distinct expected package/build identity 2026.9.10-first-hop.0 through the updater, with retained evidence and settings still preserved. This supplies the requested shipped-writer compatibility/repair/next-update proof; focused unfinished-restoration refusal regressions remain separate supporting evidence.

The negative control confirms unchanged 9.8 blocks before staging/accessing the deliberately absent candidate: update-recovery-pending, candidateCodeInvoked:false. It does not claim candidate-only rescue of a stranded old updater. Old-reader → external-new-repair → old-reader remains uncovered, and no full release upgrade or release publication is claimed.

Frozen trusted harness: ec0a4e67d8a3ae45e0311cb27a62f4e00b745820. At final harness head 6c05dc5bfebacd61b25333d5b07a3a3913c52f80, recovery-specific modules, policy and Docker planner remain byte-identical; shared main phase-logging/restart-fixture changes are covered by focused conflict tests, not claimed byte-identical. Aggregate cell time is 3,490 s (58m10s), excluding setup. These are local Docker measurements, not CI seconds.

Current-head required CI is green on all three PRs. Exact-head ClawSweeper reviews completed with no code findings; their outstanding qualification requests are addressed by these results. Existing independent source-review dispositions and the harness's inherited local Knip failure remain recorded, not relabeled as clean checks.

@clawsweeper

clawsweeper Bot commented Oct 8, 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 scripts Repository scripts docker Docker and sandbox tooling size: L labels Oct 8, 2026
@RomneyDa
RomneyDa marked this pull request as ready for review October 8, 2026 18:07
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. 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 Oct 8, 2026
@clawsweeper

clawsweeper Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge. Reviewed October 8, 2026, 4:01 PM ET / 20:01 UTC (Revision 4).

ClawSweeper review

What this changes

This PR adds release checks for interrupted published-package upgrades, repeated candidate repair, package and settings preservation, and a subsequent update.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) Useful, coherent qualification work now has completed real updater proof and no identified code findings.
Proof confidence 🦞 diamond lobster (5/6) Sufficient (live_output): The completed Docker results exercise published writers through real update, public repair twice, and a distinct subsequent update, with package bytes and authored settings preserved; the old-reader negative control rejects before candidate access. Recovery-specific harness code matches the reviewed head. This PR changes disposable fixtures and artifacts rather than an installed stored-data contract.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Test only · Worth it: Yes · Fix scope: Complete
User problem: Release checks can pass successful upgrades while missing interrupted recovery that blocks the next update.
Reason: Authentic published-writer fault coverage addresses a demonstrated validation gap using the existing harness. Prior merged work establishes the author’s involvement in this qualification area.

Merge readiness

⛔ Blocked before merge - 1 item remains

This PR provides useful qualification coverage absent from current main. Earlier findings are resolved, and the completed five-cell qualification addresses the previous review’s evidence request; no new patch defect was identified.

Priority: P2
Reviewed head: 6c05dc5bfebacd61b25333d5b07a3a3913c52f80

Before merge

Findings

None.

Agent review details

How this fits together

Release validation installs published OpenClaw packages in disposable Docker environments and exercises their updater against a candidate package. The scenario planner selects cases, while the harness checks outcomes and publishes diagnostic receipts.

flowchart TD
  A[Release validation request] --> B[Baseline and scenario planner]
  B --> C[Published package in Docker]
  C --> D[Publication interruption or Doctor failure]
  D --> E[Candidate repair twice]
  E --> F[Distinct subsequent update]
  F --> G[Package and settings preservation checks]
  G --> H[Diagnostic receipts]
Loading

Technical review

Best possible solution:

Maintain released-writer fault coverage in the existing survivor harness alongside the complementary runtime recovery fixes.

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

Not applicable to a runtime patch: current main’s scenario catalog establishes the qualification gap, and the recorded Docker runs exercise the added fault scenarios.

Is this the best way to solve the issue?

Yes, extending the existing published-upgrade harness preserves one qualification owner and its planning, omission, and diagnostic contracts.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 4f33fe7402bf.

Merge-risk options

Maintainer options:

  1. Land the runtime companion first (recommended)
    Merge the recovery-history repair before activating this qualification coverage so release candidates include the behavior exercised by the passing composed package.

Provenance checked

Testing

Proof path: shipped entry point.

Security

None.

Evidence

What I checked:

  • Current-main necessity: The fetched main catalog lacks all three package-recovery scenarios. Its existing recovery checks do not replace the released-writer interruption, newer repair, and distinct next-update composition. (scripts/lib/upgrade-survivor-scenarios.json:3, 4f33fe7402bf)
  • Completed real qualification: The fully read live PR body reports four passing positive Docker cells using published 2026.9.8 and 2026.9.9 writers, plus the passing 2026.9.7→unchanged 2026.9.8 negative control. Candidate 1aa57206f693d5e2fbce607289d0bbeefbff32d1 had tarball SHA-256 20f5375db04391e3155d1a1386843e8aeb80cade377193b71e7221e5b7d490f7. Public repair and repeated repair exited 0; every positive cell installed 2026.9.10-first-hop.0 with retained evidence and authored settings preserved. Captured body source identity: 9958bb0c91b318551cf9ff1ff9c356c39a99dcb99e70c1177a7a30889fa1c3dc. (6c05dc5bfeba)
  • Proof applies to reviewed harness: The fault observer, recovery oracle, recovery shell, policy, and Docker planner have no differences between the qualification harness revision and the reviewed head. The body separately records focused validation of shared main changes. (scripts/e2e/lib/upgrade-survivor/package-activation-recovery.sh:49, 6c05dc5bfeba)
  • Prior findings resolved: Setup removes both fault markers before arming each invocation. Supported and omitted scenarios now use the same pinned-cell expansion, preserving all five recovery cells in scheduler accounting. (scripts/e2e/lib/upgrade-survivor/package-activation-recovery.mjs:128, 6c05dc5bfeba)
  • Companion runtime dependency: The successful qualification candidate includes fix: completed recovery history blocks future updates #167358, which remains open. Fetched main still strictly decodes every historical recovery record during update admission; the companion changes admission to validated inspection so completed legacy history does not block the next update. fix(update): make completed recovery evidence best effort #167330 is already merged. (src/infra/update-run-recovery.ts:29, 4f33fe7402bf)
  • No stored-data migration: The introduced delta changes qualification fixtures, scheduling, and diagnostic artifacts, with no installed database schema, operator-state codec, or runtime migration change. Faults observe authentic released journals rather than manufacturing recovery records. (scripts/e2e/lib/upgrade-survivor/package-activation-fault.mjs:9, 6c05dc5bfeba)

PR surface

Tests +415, Config +3, Other +596. Total +1014 across 24 files. Added test files: 1.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 10 422 7 +415
Docs 0 0 0 0
Config 1 4 1 +3
Generated 0 0 0 0
Other 13 634 38 +596
Total 24 1060 46 +1014

Review metrics

Metric Value Why it matters
Pinned recovery coverage 4 positive cells and 1 negative control These historical writer cases remain selected after latest and previous release aliases advance.

Stored data model

Persistent data-model change detected: migration/backfill/repair: scripts/e2e/lib/upgrade-survivor/diagnostics.mjs, migration/backfill/repair: scripts/e2e/lib/upgrade-survivor/package-activation-fault.mjs, migration/backfill/repair: scripts/e2e/lib/upgrade-survivor/package-activation-recovery.mjs, migration/backfill/repair: scripts/e2e/lib/upgrade-survivor/package-activation-recovery.sh, migration/backfill/repair: scripts/e2e/lib/upgrade-survivor/run.sh, migration/backfill/repair: scripts/e2e/upgrade-survivor-docker.sh, and 7 more. Migration or upgrade compatibility proof is recorded; maintainers should verify it before merge.

Labels

Label changes:

  • add merge-risk: 🚨 automation: Activating the new positive cells before the open runtime companion lands can make release qualification fail at the subsequent-update step.
  • add proof: sufficient: Contributor real behavior proof is sufficient.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • remove rating: 🦐 gold shrimp: Current PR rating is rating: 🐚 platinum hermit, so this older rating label is no longer current.

Label justifications:

  • P2: This closes a bounded release-validation gap without changing installed runtime behavior.
  • merge-risk: 🚨 automation: Activating the new positive cells before the open runtime companion lands can make release qualification fail at the subsequent-update step.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.
  • proof: sufficient: Contributor real behavior proof is sufficient.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only; repair and merge need explicit maintainer commands such as @clawsweeper autofix or @clawsweeper automerge.

History

Review history (3 earlier review cycles)
  • reviewed 2026-10-08T18:15:21.702Z sha 03fd479 :: blocked before merge. :: [P2] Account for pinned baselines when reporting unsupported scenarios | [P2] Clear fault markers before reusing the artifact directory
  • reviewed 2026-10-08T18:51:35.684Z sha ec0a4e6 :: blocked before merge. :: none
  • reviewed 2026-10-08T19:13:21.139Z sha 6c05dc5 :: needs changes before merge. :: none

@clawsweeper clawsweeper Bot added status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Oct 8, 2026
@clawsweeper clawsweeper Bot added merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. proof: sufficient ClawSweeper judged the real behavior proof convincing. 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 Oct 8, 2026
@RomneyDa
RomneyDa merged commit bc860ad into main Oct 8, 2026
133 checks passed
@RomneyDa
RomneyDa deleted the fix/package-recovery-release-validation branch October 8, 2026 20:04
RomneyDa added a commit that referenced this pull request Oct 8, 2026
Backport all required recovery fixes to 2026.10.1: #167302, #167330,
#167358, and #167377. Include their missing settlement prerequisites
#164997, #165238, and #165607.

Close obsolete recovery custody durably before best-effort evidence archival;
keep unfinished rollback and current mutation authority strict. Completed
history cannot block subsequent updates. Qualify authentic interruptions
from pinned 9.8/9.9 updaters plus the unchanged 9.7-to-9.8 negative control.

Adapt donor APIs to the release-owned publication and lease database owners.
No version, dependency, budget, permission, or publication changes.

Proof:619 focused tests passed, including14 release-profile cases;
fresh complete69-file P0-P2 review clean. Complete changed gate passed.
Exact combined release build and stable/all/soak qualification remain pending.

Sources:
3ed1e21 (#167302)
4821885 (#167330)
8879e5e (#167358)
bc860ad (#167377)
9497527 (#164997)
5ae6497 (#165238)
fb84dd5 (#165607)

Co-authored-by: Scott Hanselman <[email protected]>
Co-authored-by: Peter Steinberger <[email protected]>
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 9, 2026
…#167377)

* test(update): validate pinned released package recovery

* test(update): qualify recovery on native storage and preserve settings

* fix(test): preserve pinned package recovery qualification cells

* test(update): reset recovery fault markers for each invocation

* test(update): count pinned recovery omissions in scheduler results
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docker Docker and sandbox tooling merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. P2 Normal backlog priority with limited blast radius. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. scripts Repository scripts 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.

1 participant