Skip to content

sessions: Add external session visibility banner - #331083

Merged
Benjamin Christopher Simmonds (benibenj) merged 4 commits into
mainfrom
benibenj/agents/external-session-banner-settings
Aug 16, 2026
Merged

Benjamin Christopher Simmonds (benibenj) merged 4 commits into
mainfrom
benibenj/agents/external-session-banner-settings

Conversation

@benibenj

@benibenj Benjamin Christopher Simmonds (benibenj) commented Aug 16, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • show a one-time banner when opening an Agent Host session created in another application
  • expose the external-session visibility setting as an External submenu below provider filters in both session lists
  • let users choose which external sessions remain visible, with confirmation when the open session would disappear
  • persist dismissal, reactively expose external provenance, and reconcile restored session publication with the setting
  • add unit coverage and themed component fixtures for the banner, filter menu, and warning dialog

Testing

  • npm run compile
  • native TypeScript source check with @typescript/native
  • node --experimental-strip-types build/hygiene.ts <changed files>
  • npm run typecheck-client
  • npm run valid-layers-check
  • targeted external session banner, filter menu, and Agent Service tests
  • ESLint and Stylelint on changed files
  • Component Explorer visual validation in dark theme

Explain when an Agent Host session came from another application and let users choose which external sessions remain visible. Confirm choices that hide the open session, persist banner dismissal, and reconcile restored session publication with the setting.

Co-authored-by: Copilot <[email protected]>
Copilot AI balanced review requested due to automatic review settings August 16, 2026 15:46
@vs-code-engineering

vs-code-engineering Bot commented Aug 16, 2026 •

Copy link
Copy Markdown
Contributor

📬 CODENOTIFY

The following users are being notified based on files changed in this PR:

Ladislau Szomoru (@lszomoru)

Matched files:

  • src/vs/sessions/services/sessions/common/session.ts

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds configurable visibility and a one-time banner for Agent Host sessions created by external applications.

Changes:

  • Adds reactive external-session provenance and visibility modes.
  • Adds the banner, confirmation workflow, accessibility help, and fixtures.
  • Reconciles published sessions when visibility settings change and adds tests.
Show a summary per file
File Description
src/vs/workbench/contrib/chat/browser/chat.shared.contribution.ts Clarifies the default visibility mode.
src/vs/sessions/services/sessions/common/session.ts Adds external-session provenance.
src/vs/sessions/contrib/providers/agentHost/browser/baseAgentHostSessionsProvider.ts Exposes provenance reactively.
src/vs/sessions/contrib/providers/agentHost/AGENT_HOST_SESSIONS_PROVIDER.md Documents visibility behavior.
src/vs/sessions/contrib/chat/test/browser/externalSessionBanner.test.ts Tests filtering and confirmation text.
src/vs/sessions/contrib/chat/test/browser/externalSessionBanner.fixture.ts Adds visual fixtures.
src/vs/sessions/contrib/chat/test/browser/externalSessionBanner.fixture.css Styles fixture content.
src/vs/sessions/contrib/chat/browser/sessionsChatAccessibilityHelp.ts Documents keyboard interaction.
src/vs/sessions/contrib/chat/browser/media/externalSessionBanner.css Styles the banner.
src/vs/sessions/contrib/chat/browser/media/chatView.css Supports banner-aware layout.
src/vs/sessions/contrib/chat/browser/externalSessionBanner.ts Implements banner behavior.
src/vs/sessions/contrib/chat/browser/chatView.ts Integrates and lays out the banner.
src/vs/platform/chat/common/chatSettings.ts Defines shared visibility modes.
src/vs/platform/agentHost/test/node/agentService.test.ts Tests visibility reconciliation.
src/vs/platform/agentHost/node/agentService.ts Filters and republishes external sessions.
src/vs/platform/agentHost/node/agentHostStateManager.ts Adds summary publication control.
src/vs/platform/agentHost/common/agentHostSchema.ts Reuses the shared visibility enum.

Review details

💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

  • Files reviewed: 17/17 changed files
  • Comments generated: 2
  • Review effort level: Balanced

@github-actions

github-actions Bot commented Aug 16, 2026 •

Copy link
Copy Markdown
Contributor

Screenshot Changes

Base: 39c97e41 Current: 2eded144

Added (6)

sessions/externalSessionBanner/externalSessionBanner/InChat/Dark

current

sessions/externalSessionBanner/externalSessionBanner/InChat/Light

current

sessions/externalSessionBanner/externalSessionBanner/OptionSelected/Dark

current

sessions/externalSessionBanner/externalSessionBanner/OptionSelected/Light

current

sessions/externalSessionBanner/externalSessionBanner/DisappearanceDialog/Dark

current

sessions/externalSessionBanner/externalSessionBanner/DisappearanceDialog/Light

current

Expose the external-session visibility setting beneath provider filters in both the regular agent sessions list and the Agents Window. Keep the checked option synchronized with effective configuration and update the user setting from either menu.

Co-authored-by: Copilot <[email protected]>
Use an overload-compatible configuration service mock so the native TypeScript compiler accepts the external-session menu setting test.

Co-authored-by: Copilot <[email protected]>
roblourens
roblourens previously approved these changes Aug 16, 2026
Make the stale metadata overlay test opt into all external sessions so it exercises overlay behavior independently from the new age-based visibility filter.

Co-authored-by: Copilot <[email protected]>
@benibenj
Benjamin Christopher Simmonds (benibenj) merged commit 125f1cb into main Aug 16, 2026
27 checks passed
@benibenj
Benjamin Christopher Simmonds (benibenj) deleted the benibenj/agents/external-session-banner-settings branch August 16, 2026 19:31
@vs-code-engineering vs-code-engineering Bot added this to the 1.134.0 milestone Aug 16, 2026
@vs-code-engineering vs-code-engineering Bot locked and limited conversation to collaborators Sep 30, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants