Repository navigation
fix(doctor): report refused config repairs as incomplete - #125282
Merged
Merged
Conversation
Contributor
|
🦞👀 Pull request received. I will update this pull request when review starts. |
Contributor
Author
|
Merged via squash.
|
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Aug 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What Problem This Solves
Fixes an issue where users running
openclaw doctor --fix(or accepting an interactive repair) could seeDoctor complete.and receive exit code 0 after cron-ownership safety refused the requested config write. The refusal also stops remaining diagnostics, so automation could treat an unconverged and partially unchecked installation as healthy.Why This Change Was Made
Doctor now records every atomic config-write refusal in one closed outcome shared by validation and cron-ownership safety. Later contributions still stop rather than consuming an unpersisted candidate, while finalization reports the run as incomplete and exits 1. A config persistence failure also takes precedence over the updater's recoverable post-install advisory when both outcomes coexist; the unsafe write remains refused.
Production LOC: +21/-33 (net -12). The change replaces two parallel booleans with one discriminated outcome and removes duplicate terminal/short-circuit policy.
User Impact
Operators and scripts now get a truthful nonzero result when Doctor could not apply accepted repairs. Existing actionable refusal guidance remains unchanged, and no unsafe cron-owner write is forced.
Evidence
node scripts/run-vitest.mjs src/flows/doctor-health.test.ts src/flows/doctor-health-contributions.test.ts src/commands/doctor-config-flow.validation-refusal.test.ts src/infra/package-update-steps.test.ts— 143 tests passed.Doctor complete.is absent, and no advisory result is published.node scripts/check-changed.mjs— all production checks and core production typecheck passed. The broad core-test typecheck is blocked by unrelatedui/src/pages/chat/route-loader.ts(712,38): TS2339; this branch does not touch that file, and the same baseline was independently reproduced at frozen exact7810edca33f866df373b32e1779f7ecd51fbf78e.