Repository navigation
Add agent config readiness and gateway start guidance - #79
Conversation
Classify the isolated agent's default OpenClaw config without starting Node or the OpenClaw runner. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 3cc6aa7d-1710-48a9-804d-3e5f496d8a34
After successful interactive OpenClaw calls, check agent config readiness and managed gateway liveness before suggesting clawctl gateway-service start. Suppress later checks for the current Windows logon after a manual start or an observed running gateway. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 3cc6aa7d-1710-48a9-804d-3e5f496d8a34
Render the post-OpenClaw gateway suggestion with Spectre.Console, using warning and accent colors while preserving plain and redirected output. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 3cc6aa7d-1710-48a9-804d-3e5f496d8a34
Add file-only config readiness to both clawctl status surfaces when the gateway is not running, gate start guidance on startup eligibility, and preserve the additive state in JSON. Fix post-OpenClaw crab and color rendering through app-alias stderr proxies while retaining native VT setup and plain redirected output. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 3cc6aa7d-1710-48a9-804d-3e5f496d8a34
Mark production console writers explicitly so UTF-8 initialization cannot make the app-alias stderr proxy look redirected before rendering the crab-branded gateway hint. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 3cc6aa7d-1710-48a9-804d-3e5f496d8a34
Keep manual start acknowledgement advisory under lock contention and recheck acknowledgement under the lifecycle lock before emitting a postflight hint. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 3cc6aa7d-1710-48a9-804d-3e5f496d8a34
|
🦞👀 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 September 18, 2026, 5:34 PM ET / 21:34 UTC (Revision 3). ClawSweeper reviewWhat this changesAdds file-only configuration readiness to Windows gateway status, conditional startup hints after OpenClaw commands, and per-logon hint suppression. Merge readiness✅ Ready for maintainer review The three prior findings are resolved, and no remaining blocking defect was found. This collaborator-authored PR adds useful behavior absent from current main and the latest release. Likely related people: paulcam206 — high-confidence routing candidate based on prior merged gateway and session work. Priority: P2 Review scores
Verification
How this fits togetherThe Windows launcher runs OpenClaw inside an isolated agent session. A session helper reads the agent’s default configuration, and the launcher combines that classification with managed gateway status to display guidance. flowchart TD
A[OpenClaw command or status request] --> B[Windows launcher]
B --> C[Isolated session helper]
D[Default agent configuration] --> C
C --> E[Readiness classification]
F[Gateway state and logon acknowledgment] --> G[Guidance decision]
E --> G
G --> H[Status output or startup hint]
Before mergeNone. Agent review detailsSecurityNone. Review metrics
Technical reviewBest possible solution: Keep readiness advisory and narrowly scoped to the default configuration, preserving child results, structured diagnostics, and existing recovery behavior. Do we have a high-confidence way to reproduce the issue? Not applicable to the feature request; the previous defects now have focused regression coverage, inspected but not executed during this read-only review. Is this the best way to solve the issue? Yes. The file-only helper supplies narrowly defined guidance without starting OpenClaw to inspect configuration, and the current head contains the necessary failure isolation and retained-script compatibility handling. AGENTS.md: not found in the target repository. Codex review notes: model internal, reasoning medium; reviewed against a99bb66d2162. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (2 earlier review cycles)
|
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 3cc6aa7d-1710-48a9-804d-3e5f496d8a34
What Problem This Solves
The packaged
openclaw.exelauncher cannot currently distinguish an unconfigured agent from one whose default config is eligible to start the managed gateway, so status output and successful commands cannot give timely, accurate startup guidance.User Impact
User impact: users can see whether a stopped gateway is unconfigured, not ready, or startup eligible, and successful interactive OpenClaw commands gently suggest
clawctl gateway-service startonly when that action is appropriate.The readiness result is intentionally a file-only heuristic for the isolated agent's default
openclaw.json; it does not claim that the gateway will remain healthy. Guidance is suppressed for the current Windows logon after a manual start or after the launcher observes the gateway running.Why This Change Was Made
The isolated agent owns the relevant OpenClaw config, while invoking the supported OpenClaw CLI just to inspect it starts the launcher, session, Node.js, and OpenClaw stack. This change adds a NativeAOT-safe session-host helper that reads only the default config and classifies it as absent, not ready, or startup eligible.
Both
clawctl statussurfaces use that result only when the gateway is not confirmed running. Successful interactive OpenClaw calls combine startup eligibility with a managed-gateway liveness probe before showing the crab-branded hint. The acknowledgment state is scoped to the current Windows logon, and the final hint decision is serialized with acknowledgment so concurrent invocations cannot emit stale guidance.Evidence
Validated locally on Windows at head
41041dbd3621e8113edb38197c8b8dd6a34d6243:.\scripts\Test-DotNetQuality.ps1— passed with zero warnings or errors and clean whitespace/code-style checks.dotnet test .\OpenClaw.Gateway.MSIX.slnx --configuration Release --no-restore— 778 passed..\scripts\Test-NativeAotCli.Tests.ps1— passed, including NativeAOT readiness JSON and capability-aware colored crab-hint scenarios.6d11e42and found three compatibility defects. This head contains regression coverage proving that MXC advisory failures preserve successful and nonzero child exit codes, MXC and malformed-protocol readiness failures retain both structured status documents asunknown, exact retained recovery scripts upgrade to--recovery, and modified scripts remain untouched.Gateway MSIX workflow run 35397086105 and CodeQL run 35397080151 validate this exact head. Change classification passed; the analyzers, CodeQL, OpenClaw npm package build, Gateway MSIX host tests, and x64/ARM64 unsigned package composition were pending when this evidence was recorded.
Live Developer Mode evidence was collected on ancestor
f9f27ec:Absent / ConfigFileMissing; successful and failedopenclawcalls preserved their exit codes, skipped gateway liveness, emitted no hint, and cleaned their request files;clawctl gateway-service starthint;runningon recorded port18789, omitted readiness, and the dashboard returned HTTP 200;openclaw --versionreturned 0 without adding a readiness probe after the current-logon acknowledgment.The final console-writer provenance and acknowledgment-serialization commits were not redeployed because loose-package deployment would replace that newly configured running agent session. Those commits are covered by the full xUnit, static-analysis, and NativeAOT lanes above. Official signing was not run because PR builds intentionally produce unsigned packages and the workflow rejects official signing outside
main.