Agent Host issue - keeps asking to sign in to Github although signed in
- Dominant language
- TypeScript
- Stars
- 193k
- Forks
- 42.4k
- PR merge metrics
- PR metrics pending
Description
Type: Bug
### Describe the bug
VS Code's Agent Host repeatedly re-prompts for GitHub sign-in on every window
launch when Copilot is configured to use a GitHub Enterprise Server (GHES)
auth provider, even when a valid, persisted session already exists and was
just re-confirmed via a full sign-out + fresh browser re-authorization.
### Steps to Reproduce
1. Configure Copilot to use a GitHub Enterprise Server instance:
- "github-enterprise.uri": "https://"
- "github.copilot.advanced": { "authProvider": "github-enterprise" }
2. Sign in to GitHub Enterprise via the Accounts menu.
3. Restart/launch VS Code.
### Actual behavior
Two identical "GitHub Sign in" dialogs appear on every launch. Enabling the
Authentication trace log (Developer: Set Log Level > Authentication > Trace)
shows Agent Host requesting tokens for two separate resources on the same
GHES host on every launch:
[AgentHost] No token resolved for resource: https://api.
[AgentHost] No token resolved for resource: https://api./repos
[AgentHost] Authenticating for resource: https://api.
[AgentHost] Authenticating for resource: https://api./repos
This repeats every launch, even immediately after a clean sign-out and fresh
sign-in granting full authorization.
### Things ruled out
- Not a proxy/network issue: the GHES API host is directly reachable with and
without a proxy configured (both return HTTP 401, i.e. reachable).
- `chat.agentHost.enabled` has no effect (doesn't appear to be a real
registered setting in 1.133.0).
- No per-provider toggle exists to disable just the Copilot side of Agent
Host (chat.agentHost.claudeAgent.enabled / codexAgent.enabled exist, but no
copilotAgent.enabled equivalent).
- `chat.agentHost.allowSignedOutWhenUsable` doesn't apply (Claude-only
currently, per its description).
- Confirmed on latest stable (1.133.0), no newer patch available.
### Expected behavior
Agent Host should reuse the already-authenticated GHES session (used
successfully by regular Copilot Chat) instead of independently and
repeatedly failing to resolve/cache tokens for its own resource set on every
launch.
### Environment
- VS Code version: 1.133.0
- OS: Windows
- Copilot auth provider: github-enterprise (self-hosted GHES)
VS Code version: Code 1.133.0 (a5b500951314efd502d07465bd138dfbd714a960, 2026-08-11T22:14:08Z)
OS version: Windows_NT x64 10.0.26200
Modes:
System Info
|Item|Value|
|---|---|
|CPUs|Intel(R) Core(TM) Ultra 7 365 (8 x 3418)|
|GPU Status|2d_canvas: enabled
GPU0: VENDOR= 0x8086, DEVICE=0xb090 [Intel(R) Graphics], DRIVER_VENDOR=Intel, DRIVER_VERSION=32.0.101.8826 *ACTIVE*
GPU1: VENDOR= 0x1414, DEVICE=0x008c [Microsoft Basic Render Driver], DRIVER_VERSION=10.0.26100.9267
Machine model name:
Machine model version:
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_graphite: disabled_off
trees_in_viz: disabled_off
video_decode: enabled
video_encode: enabled
webgl: enabled
webgpu: enabled
webnn: disabled_off|
|Load (avg)|undefined|
|Memory (System)|31.51GB (7.25GB free)|
|Process Argv|--crash-reporter-id 76288974-ad21-453e-b813-4e703abd7d79|
|Screen Reader|no|
|VM|0%|
Extensions (23)
Name|Identifier|Author|Version
---|---|---|---
markdownlint|davidanson.vscode-markdownlint|DavidAnson|0.62.1
Forge Store Artifacts|intel-innersource.forge-store-vscode|intel-innersource|0.9.71
Rainbow CSV|mechatroner.rainbow-csv|mechatroner|3.24.1
Container Tools|ms-azuretools.vscode-containers|ms-azuretools|2.4.5
.NET Install Tool|ms-dotnettools.vscode-dotnet-runtime|ms-dotnettools|3.1.0
Data Workspace|ms-mssql.data-workspace-vscode|ms-mssql|0.6.3
SQL Server (mssql)|ms-mssql.mssql|ms-mssql|1.44.1
SQL Bindings|ms-mssql.sql-bindings-vscode|ms-mssql|0.4.1
SQL Database Projects|ms-mssql.sql-database-projects-vscode|ms-mssql|1.6.2
Python Debugger|ms-python.debugpy|ms-python|2026.6.0
Python|ms-python.python|ms-python|2026.4.0
Pylance|ms-python.vscode-pylance|ms-python|2026.3.1
Python Environments|ms-python.vscode-python-envs|ms-python|1.36.0
Remote - SSH|ms-vscode-remote.remote-ssh|ms-vscode-remote|0.124.0
Remote - SSH: Editing Configuration Files|ms-vscode-remote.remote-ssh-edit|ms-vscode-remote|0.87.0
Azure Repos|ms-vscode.azure-repos|ms-vscode|0.40.0
PowerShell|ms-vscode.powershell|ms-vscode|2026.1.2
Remote Explorer|ms-vscode.remote-explorer|ms-vscode|0.5.0
Remote Repositories|ms-vscode.remote-repositories|ms-vscode|0.42.0
Chat Customizations Evaluations|ms-vscode.vscode-chat-customizations-evaluations|ms-vscode|1.0.8
otak-proxy|odangoo.otak-proxy|odangoo|3.2.6
Markdown Preview Enhanced|shd101wyy.markdown-preview-enhanced|shd101wyy|0.8.30
Svelte for VS Code|svelte.svelte-vscode|svelte|110.3.1
A/B Experiments
```
vsliv368:30146709
vswsl492:30256859
binariesv615:30325510
nativeloc1:31344060
dwcopilot:31170013
dwoutputs:31242946
copilot_t_ci:31333650
e5gg6876:31282496
pythonrdcb7:31342333
6518g693:31463988
aj953862:31281341
envsactivate1:31551504
cloudbuttont:31379625
3efgi100_wstrepl:31403338
839jf696:31457053
ec5jj548:31422691
cp_cls_t_966_ss:31526232
4je02754:31466945
c3h7c220:31478652
ge8j1254_inline_auto_hint_haiku:31490510
cp_cls_c_1081:31454833
conptydll_true:31498968
e9c30283:31461165
test_control1:31471004
c9b86496:31447327
ei9d7968:31496641
nes-extended-on:31455476
chat:31457767
8hig5102:31480529
89g7j272:31518289
i2gc6536:31499202
52612955:31516516
ghj88844:31499326
ddid_c:31478207
hmra_i5g22:31518061
7df3h592:31512476
cp_cls_t_1082:31535311
logging_enabled_new:31498466
db5d2638:31499441
jb_cp_cls_t_632:31543129
56dj4588:31512888
32d76977:31512328
ha629193:31508444
a1ije391_t:31540920
jbcp_cls_pctr_t:31531130
61138546:31518536
cp_intellij_t_nes:31548657
jf4hg949:31526829
ahp-both-windows:31556933
session_8:31532895
ihg5j128:31534457
f412h606:31551416
7g2b5551:31542111
enable_editor_pane_layout:31567814
allow-none:31555437
6i51c363:31551401
36h42362:31564511
c7c27ce7:31554789
1h923230:31564177
1532g621_copy:31554320
treatment-23-1:31555779
unuse_dynamic_mcp:31555281
0d8dfbc3:31566037
a1hcc538:31559322
0c1h4866:31566224
vrbsty_fls:31561059
session-archive:31558132
be7id924_c:31563078
5b8j3302:31564601
mangle-name-treatment:31568060
```
Contributor guide
Assessment
This issue has not been assessed yet.