* Agents tunnels: auto-reconnect with backoff and wake-triggered retry
Tunnel-backed remote agent hosts previously had no auto-reconnect
behavior — on laptop sleep / network drop the tunnel would flip to
Disconnected and stay there until the user manually retried.
This adds a reconnect loop inside TunnelAgentHostContribution:
- Detect Connected→Disconnected transitions for still-cached tunnels
and schedule an immediate reconnect. Only fires when the entry is
explicitly Disconnected — if the entry has been removed (e.g. user
clicked "Remove Remote"), we honour the removal and do not reconnect.
- Exponential backoff on consecutive failures: 1s → 30s cap, up to
10 attempts, then pause.
- Wake-triggered retry: on browser `online` or tab
`visibilitychange` → visible, resume any paused reconnects.
Rate-limited to one resume per 10s so rapid tab toggling can't
hammer a permanently broken endpoint with unbounded attempt bursts.
- Prune all reconnect state when a tunnel is uncached or the
contribution is disposed.
* Review comment
Co-authored-by: Copilot <copilot@github.com>
* Telemetry
Co-authored-by: Copilot <copilot@github.com>
* Clean up
Co-authored-by: Copilot <copilot@github.com>
---------
Co-authored-by: Copilot <copilot@github.com>
* agentHost: fix bugs around message handling
- Fix a bug where a sessions were not restored correctly because they
had in-progress data (that is the move of the `providedSession.isCompleteObs?.get()`)
- Fix a bug where sessions that supported progress streaming would not
have sendable messages if they were already complete (that is the
addition of `this._pendingRequests.deleteAndDispose(model.sessionResource);`)
- Fix a bug in the agent host where we didn't provide `onDidStartServerRequest`
consistently which often prevented multi-client messaging from working
- DRY up some logic and add tests
* comments
* Add back button to AI customization section screens
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Move back button to left of search box
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Align editor/detail back button position with section back arrow
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Top-align section back arrow with editor header back button
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Add fixtures for editor/detail views to verify back-button alignment
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Top-align editor/detail back button to match section arrow
The .editor-header has align-items: center and contains a multi-line title
(name + filename), causing the 26px back button to drift down when centered
in the taller row. Pin it to flex-start so it sits at top of the padding
box, exactly where the section back arrow sits.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Follow-up to #310871: the sidebar entrypoint actions (Agents, Skills,
Instructions, Hooks, MCP Servers, Plugins) still called
selectSectionById after opening the editor, which deep-linked into
the section instead of showing the overview.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Adds a pure helper shouldKickOffBackgroundSummarization that gates the
post-render background compaction trigger based on prompt-cache warmth:
- inline + warm cache (toolCallRounds.length > 0): jittered threshold in
[0.78, 0.82) straddling the historical 0.80 edge.
- inline + cold cache: emergency kick-off at >= 0.90 to keep long-running
sessions from hitting sync foreground compaction.
- non-inline: unchanged >= 0.80.
The rng is injected via a private field so tests are deterministic and
the warm-only jitter path is exercised without touching Math.random.
Block the MCP servers and Plugins tabs in the chat customizations editor
when their respective access settings are disabled, including via
enterprise policy.
- McpListWidget watches `chat.mcp.access`; shows splash when value is
`none`. If `policyValue === 'none'`, shows policy-locked message and
hides the "Open Setting" button.
- PluginListWidget watches `chat.plugins.enabled` with the same
user/policy distinction.
- Reuse `.mcp-list-widget` root class so the new `.mcp-disabled-state`
CSS applies to both widgets via a single `.access-disabled` modifier.
- Add Dark/Light fixtures for both widgets in user-disabled and
policy-locked states (8 new screenshots).
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
sessions: add subtle account avatar border
Use the existing command center border tokens for the GitHub profile image so the avatar reads cleanly against active and inactive titlebar chrome.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: fix client-provided tool weirdness
There was a few weird stuff with client-provided tools still, especially
those that needed confirmations. These would generally just hang.
Now they don't.
* tests
The invocation message for shell tools (e.g. 'Running `command`') was
returned as a plain string, so backtick formatting was not rendered in the
chat UI. The past-tense 'Ran `command`' message already used the md()
wrapper and rendered correctly.
Wrap the shell invocation message with md() so the renderer treats it as
Markdown, matching the past-tense case.
(Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* chat: have register*Actions return DisposableStore
Allows tests to register and dispose chat actions per suite, avoiding "Cannot register two commands with the same id" errors when multiple test files contribute the same actions.
Also adds inlineChatZoneMenus.test.ts as a snapshot guard for the four MenuIds the inline chat zone widget hosts.
* feat(chat): add inline chat zone widget fixture and menu item registrations