Repository navigation
Store native-gateway onboarding cannot complete GitHub Copilot setup despite a working saved sign-in #1870
Description
Summary
The Microsoft Store Windows companion could not complete Connect your AI using GitHub Copilot. Browser device authorization completed, but onboarding continued to fail after multiple attempts.
At least two saved sign-ins subsequently passed inference verification through the OpenClaw CLI without another device login. Explicitly selecting a working profile allowed real Copilot chat requests to succeed, including after a gateway restart. The companion's onboarding flow still failed when trying to use the configured model.
This appears to be an onboarding/credential-activation problem rather than simply a missing Copilot subscription. The exact root cause and whether the fix belongs in Companion or the upstream Gateway are not established.
Environment at time of failure
- Windows build:
10.0.28651.1004 - Microsoft Store companion:
OpenClawFoundation.OpenClaw, version2026.10.502.0 - Microsoft Store gateway:
OpenClawFoundation.OpenClawGateway, version2026.10.600.0 - Bundled OpenClaw:
2026.10.6, commitfe06181dc5ecc01cf8904abbfc26925925efefbc - Gateway type: native Windows isolated session, not WSL
- Provider: GitHub Copilot on
github.com - Model used for successful recovery:
github-copilot/claude-sonnet-5 - Observed on October 23, 2026
Observed flow
This describes the affected instance; it has not been reduced to a clean-install reproduction.
- Install the Windows companion and native Gateway from Microsoft Store.
- Use the companion's setup UI to configure the local native Gateway.
- Choose GitHub Copilot and complete browser device authorization.
- Attempt to finish model setup. Retry device authorization when setup does not complete.
- Setup remains blocked despite saved Copilot sign-ins.
- After CLI recovery establishes a working Copilot model, return to Connect your AI and select Current model / Use this model.
- The wizard fails with a saved-secret runtime-loading error rather than completing onboarding.
Expected behavior
A successfully authorized, usable Copilot sign-in should be verified, activated for the selected agent/model, and carried through to a saved companion connection.
If verification fails, setup should identify whether the failure is GitHub authorization, local credential loading, provider/plugin readiness, or gateway pairing. Retrying should allow a working saved sign-in to be used without unnecessarily repeating device authorization.
Actual behavior and diagnostic evidence
-
Several Copilot profiles existed after the repeated attempts. Two usable profiles were initially reported as inactive with
reasonCode: setup_inactive. -
Automatic model discovery selected another saved profile and reported
auth-rejected. An explicit activation attempt for that profile returnedCopilot authentication failed: HTTP 401. -
Other setup attempts reported:
Update or enable the selected provider plugin in Plugins, then retry this saved sign-in. Your current connection is unchanged.However,
openclaw plugins list --jsonshowed the bundledgithub-copilotprovider enabled and loaded. -
The companion's Current model verification reported:
The provider could not activate this model. Refresh to choose again. Secret [REDACTED] ... is configured but unavailable (secret [REDACTED] was not materialized by the active runtime). -
Before recovery, the model still resolved to the unauthenticated default
openai/gpt-6-astra; no authoredagents.defaults.modelwas set. -
The companion had not persisted a completed gateway connection. Separate connection timeouts also occurred during recovery; restarting the companion restored discovery, but did not resolve the model-activation error.
Recovery that worked
- Set the default model to
github-copilot/claude-sonnet-5and start the packaged Gateway. - Use
openclaw models auth activate <saved-profile-id>to verify existing saved sign-ins. Two previously inactive profiles passed inference verification without another browser login. - Set the main agent's Copilot auth order to the verified profiles. Model discovery then reported
ready. - Confirm a real agent response through the Gateway, then restart the Gateway and confirm another successful response.
- Bypass the first-run AI wizard: use Connection -> Setup code to pair the Windows companion with the existing local Gateway, and approve that exact companion device request.
- The companion then showed Connected, persisted its device token, and displayed the successful Copilot response in native Chat.
PC Node mode and the local MCP server remained disabled.
Possibly related upstream report
openclaw/openclaw#181686 reports account-owned SecretRef loading failures in offline models status --probe on the same OpenClaw release, 2026.10.6 (fe06181), while Gateway-based checks work.
That report includes the same "not materialized by the active runtime" error. It may be relevant to the verification path used by onboarding, but it concerns an offline CLI probe, not the Windows wizard. This report does not establish that they are the same defect.
Investigation scope
Please investigate the handoff between saved provider sign-ins, activation/eligibility, runtime secret loading, and the onboarding verification step. The CLI and wizard produced different outcomes for a configuration capable of successful Copilot inference.
The evidence does not establish why the rejected profile returned HTTP 401, whether stale in-memory state was the underlying cause, or whether all observed errors share one defect. The connection-timeout symptom may be separate.
Sanitized error excerpts are included above. No access tokens, setup codes, private device keys, account identifiers, or full credential databases are included.
Metadata
Metadata
Assignees
Labels
Type
Fields
Priority
Projects
- StatusShow more project fieldsBacklog
Activity
clawsweeper commentedon Oct 24, 2026
Codex review: this still needs some work.
Summary
Keep open: this issue documents blocked Store onboarding despite successful Copilot inference, and neither current source nor related fixes establishes that the failure is resolved.
Reproducibility: The report provides exact shipped versions, a concrete failed flow, and a successful inference control, but this review did not reproduce it and current source establishes only the RPC boundary.
Next step
Correlate the failing wizard RPC with the working profile and agent, then repair that boundary with inline saved-sign-in recovery.
Review details
Best possible solution:
Let the existing wizard verify and use a working saved sign-in, with inline recovery that completes pairing without terminal edits.
Do we have a high-confidence way to reproduce the issue?
The report provides exact shipped versions, a concrete failed flow, and a successful inference control, but this review did not reproduce it and current source establishes only the RPC boundary.
Is this the best way to solve the issue?
Trace and repair the existing setup handoff after establishing a failing regression; bypassing verification, implementing separate Companion credential storage, or assuming the offline probe fix applies would be premature.
AGENTS.md: found and applied where relevant.
Remaining risk / open question:
Codex review notes: model internal, reasoning medium; reviewed against de162ba66028.
Label changes
Label changes:
P0: The first-run Store onboarding path remained blocked after successful browser authorization and required CLI credential/model changes before pairing could complete.impact:auth-provider: Saved Copilot profile eligibility, model activation, and runtime secret loading disagree with successful inference using explicitly selected profiles.impact:ux-release-blocker: The reported successful recovery required terminal operations and setup-code pairing rather than a working in-product recovery flow.issue-rating: 🦪 silver shellfish: Current issue advisory state selects this label.clawsweeper:no-new-fix-pr: Current issue advisory state selects this label.clawsweeper:needs-maintainer-review: Current issue advisory state selects this label.Label justifications:
P0: The first-run Store onboarding path remained blocked after successful browser authorization and required CLI credential/model changes before pairing could complete.impact:ux-release-blocker: The reported successful recovery required terminal operations and setup-code pairing rather than a working in-product recovery flow.impact:auth-provider: Saved Copilot profile eligibility, model activation, and runtime secret loading disagree with successful inference using explicitly selected profiles.Evidence reviewed
Acceptance criteria:
What I checked:
src/OpenClaw.SetupEngine/GatewayAiSetupClient.cs:351, de162ba66028)src/OpenClaw.SetupEngine/GatewayAiSetupTransport.cs:108, de162ba66028)tests/OpenClaw.SetupEngine.Tests/GatewayAiSetupClientTests.cs:529, de162ba66028)src/OpenClaw.SetupEngine.UI/Pages/AiSetupPage.xaml.cs:1235, 735783459efa)How this review workflow works
@clawsweeper re-reviewcomments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.@clawsweeper re-reviewor@clawsweeper re-runon an open PR or issue to request a fresh review only.@clawsweeper reviewto request a fresh review only.@clawsweeper explainto ask for more context, or@clawsweeper stopto stop active automation.Reviewed October 24, 2026, 11:33 AM ET / 15:33 UTC.