Skip to content

sessions: register native IPluginGitService for desktop#312346

Merged
ulugbekna merged 1 commit intomainfrom
ulugbekna/agents/support-plugins-in-agents-app
Apr 24, 2026
Merged

sessions: register native IPluginGitService for desktop#312346
ulugbekna merged 1 commit intomainfrom
ulugbekna/agents/support-plugins-in-agents-app

Conversation

@ulugbekna
Copy link
Copy Markdown
Contributor

@ulugbekna ulugbekna commented Apr 24, 2026

Verified in OSS the fix works.

Problem

The sessions desktop app was falling through to BrowserPluginGitCommandService — a stub that throws "Agent plugins are not available in this environment" on every method call. This broke marketplace plugin operations (install, update) which require git operations (clone, pull, fetch).

The workbench desktop app overrides this stub with NativePluginGitCommandService via workbench/contrib/chat/electron-browser/chat.contribution.ts, but the sessions desktop app never imported that override.

Fix

Register NativePluginGitCommandService and its ILocalGitService shared-process dependency in sessions.desktop.main.ts, mirroring the existing pattern in workbench.desktop.main.ts.

We intentionally don't import the full chat/electron-browser/chat.contribution.ts because it bundles unrelated desktop-workbench features (voice chat, CLI handler, lifecycle handler, OpenAgentsWindowAction, etc.) that may conflict with sessions-specific implementations.

What works after this fix

  • Marketplace plugin install (git clone) ✅
  • Plugin updates (git pull/fetch) ✅
  • Locally-configured plugins (already worked) ✅
  • Extension-contributed plugins (already worked) ✅

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

Registers the desktop-native git-backed implementation of the agent plugin git service in the Sessions desktop entrypoint, aligning it with the desktop Workbench so marketplace plugin install/update flows can perform git operations instead of hitting the browser stub.

Changes:

  • Register NativePluginGitCommandService as the desktop IPluginGitService implementation in sessions.desktop.main.ts.
  • Register the shared-process remote proxy for ILocalGitService on the localGit channel so git runs locally via the shared process.
Show a summary per file
File Description
src/vs/sessions/sessions.desktop.main.ts Adds desktop DI registrations for native plugin git operations (and shared-process localGit proxy) to prevent falling back to the browser stub.

Copilot's findings

  • Files reviewed: 1/1 changed files
  • Comments generated: 0

The sessions desktop app was falling through to BrowserPluginGitCommandService
(a stub that throws on every call) because the native override was never
registered. This broke marketplace plugin install/update which require git
operations (clone, pull, fetch).

Register NativePluginGitCommandService and its ILocalGitService dependency
in sessions.desktop.main.ts, mirroring the existing pattern in
workbench.desktop.main.ts.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@ulugbekna ulugbekna force-pushed the ulugbekna/agents/support-plugins-in-agents-app branch from 8ad83e1 to b79ca1e Compare April 24, 2026 13:54
@ulugbekna ulugbekna merged commit aa05d1f into main Apr 24, 2026
40 of 41 checks passed
@ulugbekna ulugbekna deleted the ulugbekna/agents/support-plugins-in-agents-app branch April 24, 2026 15:37
@vs-code-engineering vs-code-engineering Bot added this to the 1.118.0 milestone Apr 24, 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