Skip to content

fix(onboarding): remote retry hint omits required risk acknowledgment - #130174

Merged
steipete merged 2 commits into
mainfrom
codex/onboarding-remote-risk-hint-130169
Aug 26, 2026
Merged

steipete merged 2 commits into
mainfrom
codex/onboarding-remote-risk-hint-130169

Conversation

@steipete

Copy link
Copy Markdown
Contributor

Closes #130169

What Problem This Solves

Fixes an issue where users running noninteractive remote onboarding without --remote-url received a suggested retry command that immediately failed again because it omitted mandatory --accept-risk.

Why This Change Was Made

Include the already-required risk acknowledgment flag in the canonical missing-remote-URL validation example. Keep the existing validation owner, real risk-enforcement behavior, profile/container formatting, and side-effect-free preflight path unchanged.

User Impact

Operators can copy the remote-onboarding recovery command and continue setup immediately instead of hitting a second risk-acknowledgment error. Human-readable and JSON onboarding errors now provide the same usable guidance.

Evidence

  • Both new human and JSON owner regressions failed on unchanged production because the suggested command omitted --accept-risk.
  • All 91 onboarding command tests pass after the change.
  • The real Commander CLI now emits the corrected retry command; actual parsing accepts that command for both onboard and setup.
  • Real named-profile and container contexts preserve their existing correctly scoped command formatting.
  • Validation remains side-effect free: no Gateway, user configuration, or state was created.
  • Formatting, independent source review, and Codex autoreview passed without findings.
  • Production change: +1/-1 line, net zero. Regression tests extend the existing preflight table by 17 lines.

AI-assisted and independently validated through actual CLI registration and execution.

@clawsweeper

clawsweeper Bot commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

@openclaw-barnacle openclaw-barnacle Bot added commands Command implementations size: XS labels Aug 26, 2026
@steipete
steipete marked this pull request as ready for review August 26, 2026 14:37
@openclaw-barnacle openclaw-barnacle Bot added the maintainer Maintainer-authored PR label Aug 26, 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 Aug 26, 2026
@clawsweeper

clawsweeper Bot commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 26, 2026, 11:05 AM ET / 15:05 UTC.

ClawSweeper review

What this changes

The PR adds the required --accept-risk flag to the remote-onboarding missing-URL recovery command and covers human and JSON error output.

Regression provenance

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

Merge readiness

⚠️ Ready for maintainer review - 2 items remain

Keep open: current main still emits the unusable retry command, while this focused patch fixes the validation owner and preserves the existing risk gate. No blocking code or security findings; exact-head checks are still running.

Priority: P2
Reviewed head: d4d180a32d90d83c3b0e0da840ecb7976a56466e

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused owner-boundary repair with behavior-level regression coverage and no actionable review findings.
Proof confidence 🌊 off-meta tidepool Not applicable: This maintainer-labeled PR is outside the external-contributor real-behavior-proof gate.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This maintainer-labeled PR is outside the external-contributor real-behavior-proof gate.
Evidence reviewed 6 items Current-main defect: Current main’s missing-remote-URL example omits --accept-risk, although the same command later requires that flag for every noninteractive run.
Existing enforcement contract: The owner rejects noninteractive onboarding without explicit risk acknowledgment after preflight, establishing why the prior suggested command failed on retry.
Patch at the owner boundary: The PR changes only the preflight recovery example to include the already-required flag; it does not alter parsing, enforcement, or setup dispatch.
Findings None None.
Security None None.

Live Verification

Command: pnpm openclaw onboard --non-interactive --accept-risk --mode remote --json

Result: FAIL (failed) — step 1 run pnpm openclaw onboard --non-interactive --accept-risk --mode remote --json: previous terminal command was still running after 30 seconds: "pnpm openclaw onboard --non-interactive --accept-risk --mode remote --json"

$ node scripts/run-node.mjs onboard --non-interactive --accept-risk --mode remote --json
[openclaw] Building TypeScript (dist is stale: missing_build_stamp - build stamp missing).
[openclaw] Building bundled plugin assets.
[canvas] build: node scripts/bundle-a2ui.mjs
[log] ‹DIR›/a2ui.bundle.js  chunk │ size: 399.96 kB
[log] ‹DIR›/a2ui-v0.9.bundle.js  chunk │ size: 615.66 kB
[log]
[success] rolldown v1.2.0 Finished in 97.86 ms
[diffs] build: node --import tsx ../../scripts/build-diffs-viewer-runtime.mts curated
[diffs-language-pack] build: node --import tsx ../../scripts/build-diffs-viewer-runtime.mts full
[discord] build: node --import tsx ../../scripts/build-discord-activity-sdk.mts
[tsdown-build] invocation 1/2 finished in 0.6s
node_modules/playwright-core/lib/coreBundle.js (65821:28) [EVAL] Use of direct ˋevalˋ function is strongly discouraged as it poses security risks and may cause
issues with minification.
       ╭─[ node_modules/playwright-core/lib/coreBundle.js:65821:29 ]
       │
 65821 │               const value = eval(ˋ(${expr})ˋ);
       │                             ──┬─
       │                               ╰─── Use of direct ˋevalˋ here.
       │
       │ Help: Consider using indirect eval. For more information, check the documentation: https://rolldown.rs/guide/troubleshooting#avoiding-direct-eval
───────╯

node_modules/playwright-core/lib/coreBundle.js (65828:28) [EVAL] Use of direct ˋevalˋ function is strongly discouraged as it poses security risks and may cause
issues with minification.
       ╭─[ node_modules/playwright-core/lib/coreBundle.js:65828:29 ]
       │
 65828 │               const value = eval(ˋ(${expr})ˋ);
       │                             ──┬─
       │                               ╰─── Use of direct ˋevalˋ here.
       │
       │ Help: Consider using indirect eval. For more information, check the documentation: https://rolldown.rs/guide/troubleshooting#avoiding-direct-eval
───────╯

node_modules/web-tree-sitter/web-tree-sitter.js (2343:30) [EVAL] Use of direct ˋevalˋ function is strongly discouraged as it poses security risks and may cause
issues with minification.
      ╭─[ node_modules/web-tree-sitter/web-tree-sitter.js:2343:31 ]
      │
 2343 │           ASM_CONSTS[start] = eval(func);
      │                               ──┬─
      │                                 ╰─── Use of direct ˋevalˋ here.
      │
      │ Help: Consider using indirect eval. For more information, check the documentation: https://rolldown.rs/guide/troubleshooting#avoiding-direct-eval
──────╯

node_modules/web-tree-sitter/web-tree-sitter.js (2366:32) [EVAL] Use of direct ˋevalˋ function is strongly discouraged as it poses security risks and may cause
issues with minification.
      ╭─[ node_modules/web-tree-sitter/web-tree-sitter.js:2366:33 ]
      │
 2366 │           moduleExports[name] = eval(func);
      │                                 ──┬─
      │                                   ╰─── Use of direct ˋevalˋ here.
      │
      │ Help: Consider using indirect eval. For more information, check the documentation: https://rolldown.rs/guide/troubleshooting#avoiding-direct-eval
──────╯

[tsdown-build] invocation 2/2 finished in 11.0s
[plugin-control-plane-loads] verified 35 built modules with native require and checked doctor closures
runtime-postbuild: 11 phases completed in 3023ms (slowest: built plugin control-plane loads 2494ms)
{
  "ok": false,
  "phase": "options",
  "message": "Missing --remote-url for remote mode. Example: openclaw onboard --non-interactive --accept-risk --mode remote --remote-url ws://127.0.0.1:3000."
}
Missing --remote-url for remote mode. Example: openclaw onboard --non-interactive --accept-risk --mode remote --remote-url ws://127.0.0.1:3000.
[ELIFECYCLE] Command failed with exit code 1.

Assertions:

  • FAIL expect_output: Missing --remote-url for remote mode.
  • FAIL expect_output: --accept-risk --mode remote --remote-url

How this fits together

The CLI registers onboard and setup options, then sends normalized options to onboarding preflight validation. A missing remote URL stops before configuration or Gateway work and returns a recovery command in human and JSON error output.

flowchart LR
A[CLI command] --> B[Option registration]
B --> C[Onboarding preflight]
C --> D{Remote URL present?}
D -->|No| E[Copyable recovery error]
D -->|Yes| F[Continue setup]
E --> G[Operator retry]
Loading

Before merge

  • Resolve merge risk (P1) - Exact-head CI remains in progress, so landing should wait for the required checks to finish successfully.
  • Complete next step (P2) - This is already a focused maintainer-owned implementation; wait for normal exact-head CI and landing review rather than opening a repair lane.
Agent review details

Security

None.

PR surface

Source 0, Tests 0. Total 0 across 2 files.

View PR surface stats
Area Files Added Removed Net
Source 1 1 1 0
Tests 1 58 58 0
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 2 59 59 0

Review metrics

Metric Value Why it matters
Production versus test delta production +1/-1 (net 0); tests +58/-58 (net 0) The production change is a one-token recovery-text correction; the test reshaping adds human and JSON regression cases without production growth.

Root-cause cluster

Relationship: fixed_by_candidate
Canonical: #130169
Summary: This PR changes the exact recovery command described by the linked issue.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Merge-risk options

Maintainer options:

  1. Decide the mitigation before merge
    Land the owner-boundary text correction once exact-head CI is green, keeping the existing risk acknowledgment requirement unchanged.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Technical review

Best possible solution:

Land the owner-boundary text correction once exact-head CI is green, keeping the existing risk acknowledgment requirement unchanged.

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

Yes: current main emits the incomplete example before its later noninteractive risk-acknowledgment guard, so copying the displayed command reaches the documented rejection path.

Is this the best way to solve the issue?

Yes: fixing the preflight message at its producer is the narrowest maintainable repair; changing enforcement or adding a parallel recovery path would be unnecessary.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 60e3d5f19429.

Labels

Label changes:

  • add P2: This fixes a deterministic but bounded onboarding recovery loop for noninteractive remote setup.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This maintainer-labeled PR is outside the external-contributor real-behavior-proof gate.

Label justifications:

  • P2: This fixes a deterministic but bounded onboarding recovery loop for noninteractive remote setup.
  • 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: This maintainer-labeled PR is outside the external-contributor real-behavior-proof gate.

Evidence

What I checked:

  • Current-main defect: Current main’s missing-remote-URL example omits --accept-risk, although the same command later requires that flag for every noninteractive run. (src/commands/onboard.ts:207, 60e3d5f19429)
  • Existing enforcement contract: The owner rejects noninteractive onboarding without explicit risk acknowledgment after preflight, establishing why the prior suggested command failed on retry. (src/commands/onboard.ts:629, d4d180a32d90)
  • Patch at the owner boundary: The PR changes only the preflight recovery example to include the already-required flag; it does not alter parsing, enforcement, or setup dispatch. (src/commands/onboard.ts:207, d4d180a32d90)
  • Regression coverage: The revised preflight table checks the corrected command in both ordinary and JSON error paths, while retaining assertions that no setup side effects occur. (src/commands/onboard.test.ts:523, d4d180a32d90)
  • Documented contract and caller path: The public onboarding documentation says --non-interactive requires --accept-risk; both command aliases route options to the same onboarding command. Public docs: docs/cli/onboard.md. (docs/cli/onboard.md:242, d4d180a32d90)
  • Reviewed-head provenance: Local blame attributes the changed recovery example to the reviewed head. The checkout is shallow, so earlier feature-history attribution could not be expanded beyond this head. (src/commands/onboard.ts:207, d4d180a32d90)

Likely related people:

  • steipete: Local blame attributes the relevant recovery-command lines to the reviewed head; broader path history is unavailable in the shallow checkout. (role: reviewed-head author; confidence: low; commits: d4d180a32d90; files: src/commands/onboard.ts, src/commands/onboard.test.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.

@steipete
steipete merged commit a2d5431 into main Aug 26, 2026
305 of 309 checks passed
@steipete
steipete deleted the codex/onboarding-remote-risk-hint-130169 branch August 26, 2026 16:44
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 27, 2026
…openclaw#130174)

* fix(onboarding): include risk acknowledgment in remote retry hint

* test(onboarding): keep remote retry coverage within lint budget
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

commands Command implementations 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.

[Bug]: remote onboarding retry command omits mandatory --accept-risk

1 participant