Repository navigation
fix: repair legacy config on identical-package updates - #165242
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. Reviewed October 4, 2026, 9:47 PM ET / October 5, 2026, 01:47 UTC (Revision 2). ClawSweeper reviewWhat this changesThe updater completes supported legacy configuration repairs when the requested package is already installed and reports repairs to included files as completed maintenance. Merge readiness✅ Ready for maintainer review This remains a necessary, focused fix. The updated upgrade evidence resolves the prior review’s blocker, and no introduced correctness or security defect was found. Priority: P2 Review scores
Verification
How this fits togetherThe update CLI admits the selected package and operator configuration before performing maintenance. An unchanged package still needs eligible Doctor repairs before plugin and service finalization. flowchart TD
A[Update request] --> B[Package and config admission]
B --> C{Package already installed?}
C -->|Yes| D[Doctor repair plan]
D --> E[Guarded config writer]
E --> F[Plugin and service maintenance]
C -->|No| G[Package replacement]
G --> F
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource +22. Total +22 across 2 files. View PR surface stats
Review metricsNone. Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Technical reviewBest possible solution: Keep Doctor as the migration owner and complete supported repairs through the guarded writer while preserving the unchanged-package optimization. Do we have a high-confidence way to reproduce the issue? Yes, source establishes the failing path: identical package identity skips rehearsal, then current main loses config admission and refuses repairable legacy configuration without a channel request. The paired issue records the Docker failure; this review did not execute it. Is this the best way to solve the issue? Yes, the patch fills the missing finalization step through existing Doctor and config-write owners, preserving source identity and live authority checks. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against eded1a387b79. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
|
Fixed: identical-package updates complete supported legacy configuration repairs without replacing the package. |
Complete supported legacy configuration repairs when an update reuses the installed package. Fixes openclaw#165229.
Closes #165229.
What Problem This Solves
An update from the identical package tarball can reject supported legacy configuration after candidate admission has already accepted it as Doctor-repairable. The package updater recognizes the same version and build identity, skips candidate rehearsal, and enters already-current finalization. That branch loses the accepted config check and only prepares a legacy repair when
--channelwas supplied, so the ordinary update fails on fields such asagents.list.User Impact
The same-artifact update now completes the existing Doctor config repair and continues plugin maintenance without replacing unchanged package bytes or requiring a channel change. This repair is available once the updater containing this change is installed. Valid configuration keeps ordinary no-op behavior, and unrepairable configuration remains refused. Repairs affecting only an included config file report completed maintenance accurately.
Why This Change Was Made
Already-current finalization now preserves the candidate's config admission and obtains a fresh, source-bound plan from the existing Doctor owner when rehearsal was skipped. The repair uses the existing plugin lease and config writer, with the original update authority retained through lock waits and publication. Root and included-file identities, environment references, and the existing schema and service checks remain in force.
This keeps the identical-build optimization and corrects its missing maintenance step. It introduces no new configuration option, dependency, migration format, or package-replacement rule. The repair message also describes updates that do not change channels.
Evidence
The recorded upgrade-survivor failure accepted legacy config, then failed with
invalid-configonagents.list. The unchanged Docker scenario reached the corrected real CLI path with isolated synthetic state: update returnedstatus: ok, before/after build identities were equal, plugin maintenance completed, and subsequent config validation, HTTP health/readiness, and Gateway RPC status succeeded.Focused Linux validation passed on the candidate:
update-command-noop.test.ts,update-command-execution.test.ts, andupdate-command-config-fence.test.ts, including concurrent source changes and revoked root/include write authority.Both maintained Docker cells passed in full with exit 0 on the verified candidate tree:
[email protected]updater installed the 2026.9.8 candidate. Automatic migration and preservation assertions passed before standalone Doctor, unavailable plugin-path configuration remained intact, and subsequent Gateway startup, HTTP probes, and RPC status passed (startup 20 seconds; each probe/status check 1 second).The source tree was verified before and after each run. Hosted CI and applicable security checks passed on the PR head.