Skip to content

feat(update): repair installations with configured inference - #138673

Merged
steipete merged 3 commits into
mainfrom
steipete/update-repair-loop
Sep 4, 2026
Merged

steipete merged 3 commits into
mainfrom
steipete/update-repair-loop

Conversation

@steipete

@steipete steipete commented Sep 4, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Installation repair needs a bounded execution path that uses the operator's configured inference and checks whether the target actually improved. Previously, embedded triage --run ran an agent turn without a tool-call budget or a post-repair validation result.

Related: #124396 (transactional update validation and recovery) and #137580 (extended Gateway downtime during update finalization). This is the repair-loop slice of that work; unattended updater integration follows separately.

Why This Change Was Made

Share one repair loop with caller-owned validation, cancellation, time limits, tool-call limits, progress events, and structured outcomes. It tries the system-agent owner's primary and configured fallback models before other agents' authenticated routes. A fresh isolated native turn runs against the captured installation; host-side admission counts tool calls after approval checks and drains owned processes before removing temporary state. The validation oracle determines success and stops the loop on regression or lack of improvement.

The recut also adapts the moved inference probe and current auth-preference API, preserves primary-model precedence when a CLI runtime alias differs from the model provider, preserves configured auth rotation, and redacts complete summaries before truncating them. Removed the no-op unattended wrapper and duplicate wrapper test, narrowed exports to current consumers, and shared repeated tool-policy construction. Activation, service lifecycle, snapshots, and rollback remain with the caller.

User Impact

openclaw triage --run still requires an interactive terminal and now allows one repair turn, with a ten-minute overall limit, five-minute turn limit, and 40 tool calls. Doctor lint runs before and after repair; a clean initial check returns without inference. Incomplete repairs return nonzero even if the model claims success. External coding-agent handoffs retain their existing behavior.

The operator-owned update or explicit triage --run request permits prompt-free host exec in a temporary configuration. Explicit exec or repair-tool denies return unavailable with exec-denied-by-policy before the repair agent runs; the CLI explains the policy and points to openclaw triage for an external handoff. The workspace is pinned to the installation or staged candidate root, filesystem tools enforce workspaceOnly: true, and safe-bin, allow/deny, and provider policies are preserved while capabilities are capped to exec, process, read, write, edit, and apply_patch. Every fallback model must pass the same repair-tool gate before execution. Configured sandbox and non-gateway execution remain refused.

Host commands follow the repair prompt's root-only scope; filesystem containment is not an OS sandbox for shell commands. The prompt preserves credentials and state and forbids service lifecycle changes. The saved config is not edited, and there are no new configuration keys, database schemas, or protocol changes. Unattended updater integration follows in PR E.

Evidence

Maintainer decision implemented: ClawSweeper's execution-policy finding identified the old snapshot's policy override. The maintainer approved prompt-free repair for an already operator-owned operation, with three boundaries: never override explicit denies; retain installation/candidate workspace containment and existing policy restrictions; document the contract at the config producer and in the CLI/docs. Both Rank-up moves are addressed by that decision and regression proof. The data-model flag does not apply: existing ephemeral-run storage is reused without schema, migration, projection, or retention changes.

Local proof on the corrected candidate:

  • Thirteen new policy/scope regression cases failed on the prior head. The corrected nine-file repair/triage/agent-exec/inference selection passed all 153 tests. It covers global and agent exec denies, legacy security denies, each denied mutation tool, group and provider restrictions, explicit allowlists, prompt-free ask policies, both target roots, safe bins, auth rotation, and the external-handoff refusal message.
  • Independent Codex autoreview found an additional fallback policy gap. Two regressions reproduced denied provider/model refs reaching agent exec; the same gate now filters those fallbacks while retaining the primary and allowed fallback order. A fresh full-candidate autoreview at high reasoning/P1 returned scoped-clean.
  • pnpm build passed in 10m 18.6s, including all 90 plugins, 152 public SDK subpaths, UI size gates, and 53 native module-load checks, with zero ineffective dynamic-import warnings. The strengthened localhost-provider smoke passed against that build: an ask-mode repair executed a real host command in the target and an attempted filesystem write outside the workspace was blocked. Total: 154 tests across 10 files. The full pnpm check:changed plan passed, including core/test types, lint, all three zero-unused-export scans, storage/import guards, and authorization guards.

Regression evidence: real route resolution tried fixture/backup before a healthy configured primary on the pre-fix code; the corrected code preserves primary/fallback order. The auth-order regression failed before removal of the temporary override and passed afterward. The summary regression exposed a synthetic credential suffix before redaction-before-truncation and passed afterward.

Production LOC: +1,124/−62 (net +1,062); tests: +1,623/−248 (net +1,375); docs: +28/−3. The policy correction adds 49 net production lines for canonical policy preflight, permitted fallback selection, and an explicit refusal result, while removing the policy-clearing path. Remaining branch growth implements the new reusable bounded repair capability.

Campaign-branch evidence (not rerun on this recut): AWS run 9 on source 8a4db45aff48f6fc7b44add16e5756505450e26f, September 4, 2026, passed 90/90 assertions.

Scenario Campaign outcome
Successful update Succeeded; 32.626 seconds downtime
Webchat update Succeeded; 32.074 seconds downtime
No-op update Skipped, already-current
Poisoned package Failed, global-install-failed
Candidate canary failure Failed, runtime-verification-failed; one failed repair attempt
Rollback Rolled back, restart-unhealthy; 32.369 seconds downtime

The B-relevant canary run, 8b94b8ab-92d0-47ce-9ca3-f9c2bf73b627, recorded one 13.891-second failed repair attempt with a synthetic provider. The serving Gateway stayed healthy with unchanged PID, invocation, and start timestamp. This proves the campaign integration invokes repair and preserves failure without restarting the healthy Gateway; it does not prove successful repair or real-provider repair quality.

Share installation repair between triage --run and the unattended updater
entry point. Select the system-agent owner's authenticated primary and
fallback models before other configured agents, and require tool support.

Run isolated native embedded turns with local exec, source-level tool
budgets, cancellation and process cleanup. Validate before and after turns;
stop on success, regression, no improvement or exhausted budgets. Keep
activation, service lifecycle, snapshots and rollback with the orchestrator.
Preserve triage's interactive terminal requirement and external handoffs.

Validation: focused repair, route, agent-exec, triage and target-isolation
tests; a real embedded turn against a localhost synthetic provider executed
one host command and returned a parsed REPAIR_RESULT after oracle validation.
Full build passed without ineffective dynamic-import warnings. Document the
repair scope, default budgets and structured result contract.

Integration follow-up: Knip reports the unattended entry point and exported
event/validation types as unused until the updater worker consumes them.
Updater phase-ordering files are intentionally outside this worker's scope.

(cherry picked from commit edc432e6492d25db54823214ee96b41eee3024a3)
Adapt the repair probe to its current owner and auth-preference API. Expand
logical model references before selecting native execution so a CLI alias
cannot skip the operator's primary model, and retain configured auth rotation.
Redact complete repair summaries before enforcing their byte budget.

Remove the unused unattended wrapper and duplicate test, narrow exported
interfaces to current consumers, and share the temporary tool policy. Keep
triage documentation scoped to the integration provided by this PR.

Cover logical primary/fallback ordering with the real route resolver, auth
rotation at the repair execution boundary, and truncated credential redaction.
Related to #124396 and #137580; updater activation integration follows separately.
@clawsweeper

clawsweeper Bot commented Sep 4, 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 commands Command implementations agents Agent runtime and tooling size: XL maintainer Maintainer-authored PR labels Sep 4, 2026
@steipete
steipete marked this pull request as ready for review September 4, 2026 22:29
@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. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. 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 4, 2026
@clawsweeper

clawsweeper Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge. Reviewed September 4, 2026, 6:37 PM ET / 22:37 UTC.

ClawSweeper review

What this changes

The PR adds a bounded, Doctor-validated embedded repair loop for openclaw triage --run, including configured inference fallback, tool-call/time limits, and cleanup.

Regression provenance

Possible regression — probable (reviewed change; known regression link). No predecessor PR is attributed.

Merge readiness

⛔ Blocked before merge - 6 items remain

Keep open. This changes an existing explicit triage --run contract so the repair snapshot ignores configured exec approvals and filesystem scope; that security/compatibility change needs correction or an explicit maintainer decision before merge.

Priority: P1
Reviewed head: 87245232b6a59f884c495015a42d78558f2fdb73
Owner decision: Required. See Decision needed.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The bounded repair-loop implementation has meaningful source and test coverage, but a P1 execution-policy regression blocks confidence in the patch.
Proof confidence 🌊 off-meta tidepool Not applicable: This MEMBER-authored PR is exempt from the ordinary external-contributor proof gate; the included localhost-provider test is useful supplemental evidence, but it does not prove the changed approval-policy boundary is safe.
Patch quality 🦐 gold shrimp (3/6) Security review found an item that needs attention.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This MEMBER-authored PR is exempt from the ordinary external-contributor proof gate; the included localhost-provider test is useful supplemental evidence, but it does not prove the changed approval-policy boundary is safe.
Evidence reviewed 5 items Introduced permission override: The new disposable repair configuration forces full gateway host execution, removes security and ask, and disables workspace-only filesystem scope before runUpdateRepairTurn supplies it to the embedded agent.
Previous triage contract: The pre-PR Triage documentation said launched agents use their existing authentication, sandbox, and approval settings; the new path changes that behavior only for embedded repair.
Existing test coverage gap: The target-isolation tests cover auth rotation and refusal of sandbox/node routes, but do not exercise a configured exec approval or filesystem restriction surviving the repair snapshot.
Findings 1 actionable finding [P1] Preserve the operator's exec approval policy
Security Needs attention Repair snapshot bypasses configured execution controls: The embedded repair configuration removes exec security and approval settings and sets workspaceOnly: false; prompt instructions do not enforce that boundary at the final command or filesystem effect.

How this fits together

Triage gathers diagnostics for a selected OpenClaw installation and can invoke an embedded repair agent. The new loop chooses an authenticated model route, runs a bounded repair against that installation, then uses Doctor lint to determine the outcome.

flowchart LR
A[Selected installation] --> B[Doctor lint]
B --> C{Errors found?}
C -->|No| D[Successful triage]
C -->|Yes| E[Configured inference route]
E --> F[Bounded repair agent]
F --> G[Doctor validation]
G --> H[Reported repair outcome]
Loading

Decision needed

Question Recommendation
Should openclaw triage --run be allowed to override an operator's configured exec approvals and filesystem scope for autonomous repair? Preserve configured boundaries: Keep the selected agent's existing exec approval and filesystem policies in the repair snapshot, using the external handoff when unattended host access is unavailable.

Why: The PR intentionally changes an established safety contract; choosing between preserving the setting and introducing an elevated mode is product and security policy, not a mechanical repair decision.

Before merge

  • Preserve the operator's exec approval policy (P1) - repairRunConfig clears both security and ask, sets full host execution, and disables workspace-only filesystem access before the embedded agent is invoked. This changes the prior triage contract that honored the agent's existing sandbox and approval settings, so a setup requiring confirmation can now execute model-directed host commands without it. Preserve that policy or add a separately confirmed elevated mode with coverage.
  • Resolve security concern: Repair snapshot bypasses configured execution controls - The embedded repair configuration removes exec security and approval settings and sets workspaceOnly: false; prompt instructions do not enforce that boundary at the final command or filesystem effect.
  • Resolve merge risk (P1) - Merging would make an existing user's configured exec approval and filesystem-scope policy inoperative for embedded repair, allowing the selected model to issue unrestricted host commands during triage --run.
  • Complete next step (P2) - Resolve whether embedded repair must preserve configured exec approvals and filesystem scope, then address the P1 finding before merge.
  • Resolve maintainer decision - Resolve the maintainer decision shown above before merge.
  • Add data-model compatibility proof - Confirm migration or upgrade compatibility proof before merge.

Findings

  • [P1] Preserve the operator's exec approval policy — src/infra/update-repair-agent.runtime.ts:76-101
  • [high] Repair snapshot bypasses configured execution controls — src/infra/update-repair-agent.runtime.ts:80
Agent review details

Security

Needs attention: The diff creates a new no-approval, unrestricted-filesystem host-command path that overrides an operator's saved safety policy.

PR surface

Source +1013, Tests +1227, Docs +22. Total +2262 across 18 files.

View PR surface stats
Area Files Added Removed Net
Source 8 1075 62 +1013
Tests 8 1475 248 +1227
Docs 2 25 3 +22
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 18 2575 313 +2262

Review metrics

Metric Value Why it matters
Production versus test delta production +1,075/-62; tests +1,475/-248; docs +25/-3 The substantial new repair-loop surface includes an intentional execution-policy override, so its operator-facing boundary needs explicit review.

Stored data model

Persistent data-model change detected: migration/backfill/repair: src/commands/triage.ts, migration/backfill/repair: src/infra/update-repair-agent.runtime.ts. Confirm migration or upgrade compatibility proof before merge.

Merge-risk options

Maintainer options:

  1. Restore operator policy (recommended)
    Keep configured exec approvals and filesystem scope when composing the repair run, then add coverage for a restricted existing setup.
  2. Approve elevated repair explicitly
    If unattended full-host repair is required, define and test a distinct confirmation boundary rather than silently changing existing --run behavior.

Technical review

Best possible solution:

Preserve the operator's configured approval and filesystem boundary for embedded repair, or introduce a separately confirmed, maintainer-approved elevated repair mode with focused upgrade and final-effect coverage.

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

Yes, from source: configure an agent with an exec approval or workspace-only policy, invoke embedded repair, and the new repair snapshot clears those restrictions before the agent run.

Is this the best way to solve the issue?

No. The bounded loop is a coherent repair owner, but silently discarding the configured execution policy conflicts with the prior triage contract; preserve it or make elevation separately explicit.

Full review comments:

  • [P1] Preserve the operator's exec approval policy — src/infra/update-repair-agent.runtime.ts:76-101
    repairRunConfig clears both security and ask, sets full host execution, and disables workspace-only filesystem access before the embedded agent is invoked. This changes the prior triage contract that honored the agent's existing sandbox and approval settings, so a setup requiring confirmation can now execute model-directed host commands without it. Preserve that policy or add a separately confirmed elevated mode with coverage.
    Confidence: 0.98

Overall correctness: patch is incorrect
Overall confidence: 0.98

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 4b9954e37d70.

Labels

Label changes:

  • add P1: The patch can bypass safety settings for an existing interactive repair workflow before arbitrary host command execution.
  • add merge-risk: 🚨 compatibility: Existing triage --run users with configured approval or filesystem restrictions receive different execution behavior after upgrade.
  • add merge-risk: 🚨 security-boundary: The repair snapshot removes configured exec approvals and broadens filesystem access for model-directed host actions.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🌊 off-meta tidepool and patch quality is 🦐 gold shrimp.
  • add status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action. Not applicable: This MEMBER-authored PR is exempt from the ordinary external-contributor proof gate; the included localhost-provider test is useful supplemental evidence, but it does not prove the changed approval-policy boundary is safe.

Label justifications:

  • P1: The patch can bypass safety settings for an existing interactive repair workflow before arbitrary host command execution.
  • merge-risk: 🚨 compatibility: Existing triage --run users with configured approval or filesystem restrictions receive different execution behavior after upgrade.
  • merge-risk: 🚨 security-boundary: The repair snapshot removes configured exec approvals and broadens filesystem access for model-directed host actions.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🌊 off-meta tidepool and patch quality is 🦐 gold shrimp.
  • status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action. Not applicable: This MEMBER-authored PR is exempt from the ordinary external-contributor proof gate; the included localhost-provider test is useful supplemental evidence, but it does not prove the changed approval-policy boundary is safe.

Evidence

Security concerns:

  • [high] Repair snapshot bypasses configured execution controls — src/infra/update-repair-agent.runtime.ts:80
    The embedded repair configuration removes exec security and approval settings and sets workspaceOnly: false; prompt instructions do not enforce that boundary at the final command or filesystem effect.
    Confidence: 0.98

What I checked:

  • Introduced permission override: The new disposable repair configuration forces full gateway host execution, removes security and ask, and disables workspace-only filesystem scope before runUpdateRepairTurn supplies it to the embedded agent. (src/infra/update-repair-agent.runtime.ts:76, 87245232b6a5)
  • Previous triage contract: The pre-PR Triage documentation said launched agents use their existing authentication, sandbox, and approval settings; the new path changes that behavior only for embedded repair. Public docs: docs/cli/triage.md. (docs/cli/triage.md:18, d3672052d2c1)
  • Existing test coverage gap: The target-isolation tests cover auth rotation and refusal of sandbox/node routes, but do not exercise a configured exec approval or filesystem restriction surviving the repair snapshot. (src/commands/triage-target.test.ts:91, 87245232b6a5)
  • Pinned PR identity: The reviewed head has the recorded parent 9e1ddc3, matching the supplied introduction evidence. (87245232b6a5)
  • Current-main limitation: The fetched main commit was identifiable, but sparse blob retrieval for further current-main source inspection failed because the configured promisor remote could not resolve; no claim that main already contains this PR is made. (4b9954e37d70)

Likely related people:

  • steipete: 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.

  • Preserve the configured exec approval and filesystem policy, or obtain approval for a distinct elevated mode.
  • Add focused coverage showing restricted existing settings remain effective, or that an approved elevation is explicitly confirmed before host I/O.

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.

Honor explicit exec and repair-tool denies before starting an embedded repair.
Keep operator-authorized runs prompt-free with installation/candidate workspace
containment, preserving safe bins and layered tool restrictions. Apply the same
gate to fallback models before giving them host execution.

Explain policy refusals and external triage handoff in the CLI and docs. Cover
policy, target, and fallback boundaries plus real host execution and a blocked
filesystem escape through the localhost-provider smoke.

Addresses the maintainer policy decision in PR #138673. Update activation and
unattended integration remain with the caller in the follow-up campaign work.
@steipete

steipete commented Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

Follow-up to the execution-policy finding and Rank-up moves: the maintainer decision is implemented in df31959f1d9.

  1. Never override an explicit deny. The selected agent's effective exec mode/legacy security and layered global, agent, provider, model, and profile tool policies are checked before repair execution. Denied exec/write/edit/apply_patch returns unavailable with exec-denied-by-policy, without an agent turn. triage --run explains that the operator's policy denies unattended repair and points to openclaw triage for an external handoff. Sandbox and non-gateway host refusals remain. Fallback models pass the same gate; denied fallbacks are excluded before execution.
  2. Replace approval prompts with the approved scope. The initiating update or explicit --run request is already operator-owned. Its disposable repair snapshot uses prompt-free exec with the installation/candidate root as the workspace and fs.workspaceOnly: true. Safe bins and allow/deny/provider restrictions are preserved, and both allow and additive alsoAllow are capped to permitted repair tools. Filesystem tools enforce containment; shell commands follow the root-only prompt contract, not an OS sandbox. The saved policy is unchanged.
  3. State the contract at its owner. repairRunConfig, the repair prompt, triage docs, and updating docs now describe the same boundary.

Both Rank-up moves are addressed by the explicit maintainer decision and boundary regressions. Thirteen policy/scope cases failed on the prior head. Autoreview then found the fallback gap; two regressions reproduced it before correction. The final nine-file selection passed 153 tests, including both root choices, safe-bin/auth preservation, and denied provider/model fallbacks. The strengthened localhost-provider smoke also passed: ask-mode host exec created the target marker while a filesystem write outside the workspace was blocked (154 tests across 10 files total). Full build passed with zero ineffective dynamic-import warnings. Fresh full-candidate Codex autoreview is P1-clean. The full pnpm check:changed plan passed, including core/test types, lint, all three zero-unused-export scans, storage/import guards, and authorization guards.

The data-model compatibility flag does not apply: this change adds no schema, migration, projection, retention, or storage representation; the existing ephemeral-run owner is reused. The correction adds 49 net production lines for the policy gate and refusal result; the full PR remains the new bounded-repair capability.

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Sep 4, 2026 •

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event exact_review_queue).
Result: when the review finishes, ClawSweeper will create the durable review comment if needed or update the existing comment in place.

Re-review progress:

@steipete
steipete merged commit d12357e into main Sep 4, 2026
179 of 181 checks passed
@steipete
steipete deleted the steipete/update-repair-loop branch September 4, 2026 23:48
@steipete

steipete commented Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 5, 2026
…w#138673)

* feat(update): add a bounded embedded installation repair loop

Share installation repair between triage --run and the unattended updater
entry point. Select the system-agent owner's authenticated primary and
fallback models before other configured agents, and require tool support.

Run isolated native embedded turns with local exec, source-level tool
budgets, cancellation and process cleanup. Validate before and after turns;
stop on success, regression, no improvement or exhausted budgets. Keep
activation, service lifecycle, snapshots and rollback with the orchestrator.
Preserve triage's interactive terminal requirement and external handoffs.

Validation: focused repair, route, agent-exec, triage and target-isolation
tests; a real embedded turn against a localhost synthetic provider executed
one host command and returned a parsed REPAIR_RESULT after oracle validation.
Full build passed without ineffective dynamic-import warnings. Document the
repair scope, default budgets and structured result contract.

Integration follow-up: Knip reports the unattended entry point and exported
event/validation types as unused until the updater worker consumes them.
Updater phase-ordering files are intentionally outside this worker's scope.

(cherry picked from commit edc432e6492d25db54823214ee96b41eee3024a3)

* fix(update): preserve configured repair routing and bounded diagnostics

Adapt the repair probe to its current owner and auth-preference API. Expand
logical model references before selecting native execution so a CLI alias
cannot skip the operator's primary model, and retain configured auth rotation.
Redact complete repair summaries before enforcing their byte budget.

Remove the unused unattended wrapper and duplicate test, narrow exported
interfaces to current consumers, and share the temporary tool policy. Keep
triage documentation scoped to the integration provided by this PR.

Cover logical primary/fallback ordering with the real route resolver, auth
rotation at the repair execution boundary, and truncated credential redaction.
Related to openclaw#124396 and openclaw#137580; updater activation integration follows separately.

* fix(update): respect repair execution boundaries

Honor explicit exec and repair-tool denies before starting an embedded repair.
Keep operator-authorized runs prompt-free with installation/candidate workspace
containment, preserving safe bins and layered tool restrictions. Apply the same
gate to fallback models before giving them host execution.

Explain policy refusals and external triage handoff in the CLI and docs. Cover
policy, target, and fallback boundaries plus real host execution and a blocked
filesystem escape through the localhost-provider smoke.

Addresses the maintainer policy decision in PR openclaw#138673. Update activation and
unattended integration remain with the caller in the follow-up campaign work.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling commands Command implementations docs Improvements or additions to documentation maintainer Maintainer-authored PR merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. P1 High-priority user-facing bug, regression, or broken workflow. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. 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