Skip to content

feat: enable CLI agents by default - #139459

Merged
steipete merged 1 commit into
mainfrom
codex/cli-agents-default-enabled
Sep 5, 2026
Merged

steipete merged 1 commit into
mainfrom
codex/cli-agents-default-enabled

Conversation

@steipete

@steipete steipete commented Sep 5, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Users selecting a native CLI from the Control UI new-session page are blocked by an enablement notice on an otherwise default Gateway. Terminals already default to enabled, but CLI agents require a separate opt-in.

Why This Change Was Made

Default gateway.cliAgents.enabled to enabled consistently in the Control UI bootstrap, catalog terminal-start admission, and post-await launch checks. Preserve explicit false, terminal availability, operator permissions, sandbox restrictions, and node dispatch authority. Update the Labs toggle, config help, and documentation to reflect the same default.

User Impact

Default installations can discover and start available CLI agents without first changing Gateway settings. Existing explicit opt-outs remain disabled; operators can disable the feature in Labs or configuration.

Evidence

  • 251 focused tests passed across Gateway bootstrap, catalog terminal start, node dispatch authority, and Labs settings.
  • Before the runtime change, the same Gateway tests produced 14 expected failures for omitted CLI-agent configuration; 179 other checks passed.
  • Independent review found no actionable P0–P2 findings.
  • Formatting, config documentation baseline, dependency/plugin boundary guards, and UI i18n validation passed. check:changed stopped at core typecheck because this worktree uses a shared dependency install, which the declaration-input guard rejects. Remaining local checks after that step were not run. Hosted CI subsequently passed on the same commit; the initial unrelated dashboard A2UI event and test-report subprocess-cleanup failures passed on a failed-job rerun.

The change affects the configuration default, not the page layout. No live Gateway configuration was changed, and no live browser launch was performed.

Hosted validation: successful CI run. Native preparation validated hosted gates for commit 496cad819a7f2b7aaac1cf2c6cc7c57ef3287db3.

@clawsweeper

clawsweeper Bot commented Sep 5, 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 app: web-ui App: web-ui gateway Gateway runtime size: S maintainer Maintainer-authored PR labels Sep 5, 2026
@steipete
steipete marked this pull request as ready for review September 5, 2026 22:25
@steipete
steipete requested a review from a team as a code owner September 5, 2026 22:25
@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 Sep 5, 2026
@clawsweeper

clawsweeper Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

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

ClawSweeper review

What this changes

Enable available CLI agents by default in the Control UI and Gateway terminal-start path, while preserving explicit opt-outs and updating Labs settings, documentation, and tests.

Merge readiness

⛔ Blocked before merge - 1 item remains

This PR remains useful: inspected current main still requires CLI-agent opt-in. No actionable introduced defect was found, and the maintainer-authored default change preserves explicit opt-outs and existing launch restrictions.

Priority: P2
Reviewed head: 496cad819a7f2b7aaac1cf2c6cc7c57ef3287db3

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused, consistent default change with meaningful boundary coverage and no identified blocking defect.
Proof confidence 🌊 off-meta tidepool Not applicable: The maintainer-authored PR is exempt from ordinary contributor proof. Its reported tests exercise Gateway bootstrap, terminal admission, dispatch revocation, and Labs opt-outs; no live launch is claimed, and no unresolved introduced authority violation warrants an exceptional proof gate.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The maintainer-authored PR is exempt from ordinary contributor proof. Its reported tests exercise Gateway bootstrap, terminal admission, dispatch revocation, and Labs opt-outs; no live launch is claimed, and no unresolved introduced authority violation warrants an exceptional proof gate.
Evidence reviewed 8 items Verified introduced changes: The local merge-base-to-head production diff matches the supplied introduction evidence: existing enablement predicates change to explicit-false opt-outs, with corresponding Labs and help updates. No provider implementation, dependency, protocol, or permission descriptor changes are introduced.
Current main still requires opt-in: Inspected the fetched main version of catalogStartHandler: an omitted gateway.cliAgents.enabled still rejects terminal creation. No merged fixing PR was established. Inspection of the supplied latest-release source blob failed because it was unavailable locally and the remote could not resolve; release inclusion remains unknown.
Permissions and final dispatch remain enforced: The method descriptor still requires operator.admin, and Gateway authorization precedes handler execution. Terminal creation retains sandbox and connection checks; the node relay carries the live dispatch callback, including the updated explicit-false gate, into the registry transport handoff.
Findings None None.
Security None None.

How this fits together

The Control UI discovers installed CLI agents through the Gateway session catalog. Starting one passes through Gateway permission and terminal checks before opening a local process or dispatching to a paired node.

flowchart TD
  A[Gateway configuration] --> B[Control UI and Labs]
  B --> C[CLI session catalog]
  C --> D[Terminal start request]
  D --> E[Permissions and live launch checks]
  E --> F[Local CLI terminal]
  E --> G[Paired node terminal]
Loading

Before merge

  • Review config compatibility - Confirm compatibility and upgrade impact for the changed config or default surface before merge.
Agent review details

Security

None.

PR surface

Source +3, Tests +57, Docs 0, Generated 0. Total +60 across 12 files.

View PR surface stats
Area Files Added Removed Net
Source 6 11 8 +3
Tests 4 115 58 +57
Docs 1 2 2 0
Config 0 0 0 0
Generated 1 2 2 0
Other 0 0 0 0
Total 12 130 70 +60

Review metrics

Metric Value Why it matters
Configuration default 1 existing default changes; 0 new settings Omitted configuration enables CLI agents after upgrade, while explicitly stored false remains disabled.

Technical review

Best possible solution:

Use the existing CLI-agent setting consistently across discovery and launch, keeping explicit opt-outs and all terminal authorization checks intact.

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

Not applicable as a bug reproduction: this intentionally changes an existing default. Current-main source confirms that omitted configuration presently blocks native terminal starts.

Is this the best way to solve the issue?

Yes. Updating the existing configuration predicates and Labs default is a focused solution; it introduces no competing launch path or plugin API and preserves explicit settings.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 40ebdadcafa6.

Labels

Label changes:

  • add P2: This is a bounded improvement to an existing optional CLI-session workflow with an available Labs enablement path.
  • 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: The maintainer-authored PR is exempt from ordinary contributor proof. Its reported tests exercise Gateway bootstrap, terminal admission, dispatch revocation, and Labs opt-outs; no live launch is claimed, and no unresolved introduced authority violation warrants an exceptional proof gate.

Label justifications:

  • P2: This is a bounded improvement to an existing optional CLI-session workflow with an available Labs enablement path.
  • 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: The maintainer-authored PR is exempt from ordinary contributor proof. Its reported tests exercise Gateway bootstrap, terminal admission, dispatch revocation, and Labs opt-outs; no live launch is claimed, and no unresolved introduced authority violation warrants an exceptional proof gate.

Evidence

What I checked:

  • Verified introduced changes: The local merge-base-to-head production diff matches the supplied introduction evidence: existing enablement predicates change to explicit-false opt-outs, with corresponding Labs and help updates. No provider implementation, dependency, protocol, or permission descriptor changes are introduced. (src/gateway/server-methods/terminal.ts:319, 496cad819a7f)
  • Current main still requires opt-in: Inspected the fetched main version of catalogStartHandler: an omitted gateway.cliAgents.enabled still rejects terminal creation. No merged fixing PR was established. Inspection of the supplied latest-release source blob failed because it was unavailable locally and the remote could not resolve; release inclusion remains unknown. (src/gateway/server-methods/session-catalog-terminal-start.ts:35, 40ebdadcafa6)
  • Permissions and final dispatch remain enforced: The method descriptor still requires operator.admin, and Gateway authorization precedes handler execution. Terminal creation retains sandbox and connection checks; the node relay carries the live dispatch callback, including the updated explicit-false gate, into the registry transport handoff. (src/gateway/server-methods/terminal.ts:408, 496cad819a7f)
  • Default and opt-out coverage: Bootstrap tests cover omitted, true, and false settings. Labs tests cover omitted settings, an empty object, explicit true, explicit false, and writing an explicit opt-out. Catalog-start coverage exercises omitted configuration and rejects explicit false before provider invocation. (ui/src/pages/labs/labs-page.test.ts:378, 496cad819a7f)
  • Revocation coverage at node dispatch: The existing dispatch-authority suite now starts without a CLI-agent override and checks that disabling CLI starts during pairing resolution prevents a start request from reaching the transport. Terminal disabling, connection closure, command removal, and sandbox changes remain covered; transport capture is a test double. (src/gateway/server-methods/terminal.dispatch-authority.test.ts:97, 496cad819a7f)
  • Generic catalog boundary: The documented plugin contract returns a terminal plan, while the Gateway owns configuration admission and terminal execution. The changed tests use stub catalog providers; they do not establish or change a Codex dependency contract, so sibling Codex inspection is not required for this default change. Public docs: docs/plugins/sdk-entrypoints.md. (docs/plugins/sdk-entrypoints.md:297, 496cad819a7f)

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

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 commented Sep 5, 2026

Copy link
Copy Markdown
Contributor Author

Compatibility and upgrade impact reviewed: this intentionally enables CLI agents when gateway.cliAgents.enabled is omitted. Explicit true and false remain authoritative, and no existing configuration becomes invalid or needs migration. Terminal availability, operator permissions, sandbox restrictions, and live dispatch checks remain enforced. This addresses the config-compatibility item in the review.

The two initial CI failures are outside this change: dashboard A2UI event delivery and native test-report subprocess cleanup. The failed jobs are being rerun on the same head; required CI must pass before landing.

@steipete
steipete merged commit 977d0b5 into main Sep 5, 2026
394 of 397 checks passed
@steipete
steipete deleted the codex/cli-agents-default-enabled branch September 5, 2026 23:52
@steipete

steipete commented Sep 5, 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 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui docs Improvements or additions to documentation gateway Gateway runtime 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.

1 participant