fix(setup): gate Local AI on WSL readiness - #1203
Conversation
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: d327db5c-ee84-43f8-a425-060407f117c1
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 21, 2026, 7:49 PM ET / 23:49 UTC. ClawSweeper reviewWhat this changesThe branch makes WSL readiness a Welcome-page prerequisite for local gateway setup and keeps Local AI availability messaging limited to hardware and networking conditions. Merge readiness✅ Ready for maintainer review Keep open. This active collaborator PR fixes a current-main setup ordering gap by stopping blocked WSL environments before the capability and Local AI decision UI. Priority: P2 Review scores
Verification
Live VerificationCommand: Result: FAIL (failed) — execution before step 1 Assertions:
How this fits togetherThe Windows onboarding wizard takes users from a local-gateway choice through capabilities and then the setup pipeline. WSL readiness determines whether local setup may proceed, while the capability page collects choices and the pipeline performs the installation. flowchart LR
A[User selects local gateway] --> B[Welcome screen]
B --> C[Read-only WSL readiness]
C -->|Blocked| D[WSL remediation dialog]
C -->|Ready or installable| E[Capabilities and Local AI choices]
E --> F[Setup pipeline]
F --> G[WSL platform and local gateway]
F --> H[Optional Local AI download]
Before mergeNone. Agent review detailsSecurityNone. Review metrics
Technical reviewBest possible solution: Keep WSL readiness as the shared early gate for local setup while retaining the pipeline's later platform verification before installation or Local AI acquisition. Do we have a high-confidence way to reproduce the issue? No live disabled-virtualization path is safely available on the stated healthy host. The failing ordering and the blocked-Windows classification are high-confidence source-reproducible through the changed Welcome flow and synthetic WSL command tests. Is this the best way to solve the issue? Yes. Moving the read-only readiness check to Welcome prevents capability presentation before the prerequisite is known, without removing the pipeline's authoritative WSL verification. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against ccd64bbb7d68. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
Summary
Adapted from the ordering intent in joelagnel#4 for the post-#1178 setup architecture.
Validation
dotnet test .\tests\OpenClaw.SetupEngine.Tests\OpenClaw.SetupEngine.Tests.csproj --no-restore- passed, 948/948.\build.ps1- passed, all projects including WinUIdotnet test .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj --no-restore- passed, 3,812 passed and 32 skippeddotnet test .\tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj --no-restore- passed, 2,704/2,704git diff --check- passedReal behavior proof
Current-head automated proof covers the unavailable-host path with synthetic
wsl --statusoutput:PreflightWsl_FailsTerminalWhenVirtualizationDisabledInFirmwareproves the result isEnvironmentBlocked, begins withWindows cannot currently start WSL2., contains virtualization remediation, and contains noLocal AIcopy.PreflightWsl_VirtualizationFailureBlocksWhenLocalAiIsDisabledproves the WSL gate remains terminal when Local AI is disabled.SetupWelcome_BlocksOnWslReadinessBeforeLocalAiDecisionUiproves Welcome checks WSL, stops on a blocking result, and only then permits existing-config inspection and navigation to Capabilities. The Local AI hardware hint is also gated behind WSL readiness.BuildDefaultSteps_IncludesCurrentSetupFlowandSetupProgress_PreparesWslBeforeLocalAiDownloadsprove WSL preflight/platform readiness precede the runtime and model download stages.Live disabled-virtualization UI proof is Not verified / blocked. This Windows ARM64 host reports healthy WSL 2.9.3 with a running WSL2 configuration. Disabling firmware virtualization is unavailable and unsafe for the validation host, so the blocking dialog cannot be exercised without changing host firmware state.
Rubber-duck review
Completed with no blocking findings. The one actionable observation was a stale contract-test name implying Capabilities still aggregated WSL failures; the test was renamed and strengthened to assert that
WslViabilityis absent from Capabilities.