Skip to content

feat: add getWorkingDirectory method to agent host session providers and related services for distiguishing local from user customizations + several bug fixes#319047

Merged
aeschli merged 2 commits into
mainfrom
aeschli/ltd-bass-504
May 29, 2026
Merged

feat: add getWorkingDirectory method to agent host session providers and related services for distiguishing local from user customizations + several bug fixes#319047
aeschli merged 2 commits into
mainfrom
aeschli/ltd-bass-504

Conversation

@aeschli
Copy link
Copy Markdown
Contributor

@aeschli aeschli commented May 29, 2026

No description provided.

…and related services for distiguishing local from user customizations + several bug fixes
Copilot AI review requested due to automatic review settings May 29, 2026 19:32
@aeschli aeschli enabled auto-merge (squash) May 29, 2026 19:32
@aeschli aeschli self-assigned this May 29, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds working-directory awareness to agent-host customization services so directory-discovered customizations can be categorized as workspace-local or user-level, while also adjusting customization sync behavior.

Changes:

  • Adds getWorkingDirectory(...) through agent-host provider and customization service interfaces.
  • Uses working-directory information when building AI customization items from directory customizations.
  • Removes user storage from local customization auto-sync and updates related test stubs.
Show a summary per file
File Description
src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostLocalCustomizations.ts Removes user prompt storage from syncable customization sources.
src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostCustomizationService.ts Adds working-directory lookup to the workbench customization service contract and implementation.
src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentCustomizationItemProvider.ts Classifies directory customization children as local or user based on session working directory.
src/vs/sessions/services/agentHost/browser/agentHostCustomizationService.ts Refactors session/provider lookup, adds working-directory delegation, and wires customization change events.
src/vs/sessions/contrib/providers/remoteAgentHost/test/browser/remoteAgentHostCustomizationHarness.test.ts Updates the test customization service stub for the new interface method.
src/vs/sessions/contrib/providers/agentHost/browser/baseAgentHostSessionsProvider.ts Exposes the session working directory from cached session state.
src/vs/sessions/common/agentHostSessionsProvider.ts Extends agent-host session providers with getWorkingDirectory.

Copilot's findings

  • Files reviewed: 7/7 changed files
  • Comments generated: 2

Comment on lines +96 to +102
this._providerListeners.set(provider, provider.onDidChangeCustomAgents(() => {
this._onDidChangeCustomAgents.fire();
}));

this._providerListeners.set(provider, provider.onDidChangeCustomizations(() => {
this._onDidChangeCustomizations.fire();
}));
for (const sessionCustomization of directoryCustomizations) {
const source = AICustomizationSources.local; // TODO
const groupKey = undefined; //sessionCustomization.clientId ? REMOTE_CLIENT_GROUP : REMOTE_HOST_GROUP;
const source = workingDirectory && sessionCustomization.uri.startsWith(workingDirectory) ? AICustomizationSources.local : AICustomizationSources.user;
@aeschli aeschli merged commit a733226 into main May 29, 2026
25 checks passed
@aeschli aeschli deleted the aeschli/ltd-bass-504 branch May 29, 2026 23:25
@vs-code-engineering vs-code-engineering Bot added this to the 1.123.0 milestone May 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants