You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: forward GitHub token to headless server for Keychain-inaccessible environments
Root cause: when copilot login stores credentials in macOS Keychain,
the headless server spawned by PolyPilot may not have Keychain access
(ACL dialog can't be shown for background processes). The server starts
without auth, causing 'session was not created with authentication info'.
Fix: ResolveGitHubTokenForServer() checks COPILOT_GITHUB_TOKEN,
GH_TOKEN, GITHUB_TOKEN env vars, then falls back to 'gh auth token'
CLI. The resolved token is passed to StartServerAsync() which sets
GITHUB_TOKEN on the headless server process environment.
- Add githubToken parameter to IServerManager.StartServerAsync
- Resolve token once at init, cache in _resolvedGitHubToken
- Re-resolve on ReauthenticateAsync (user may have just logged in)
- Forward to all 7 StartServerAsync call sites
- Add 3 tests for token resolution and parameter forwarding
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
0 commit comments