mcp: fix add-mcp command errors out on insiders (#252705)

Fixes #252512
This commit is contained in:
Connor Peet
2025-06-27 23:48:41 +02:00
committed by GitHub
parent 202f02381b
commit d33c40d6bb
2 changed files with 13 additions and 6 deletions
+7
View File
@@ -68,6 +68,9 @@ import { AllowedExtensionsService } from '../../platform/extensionManagement/com
import { McpManagementCli } from '../../platform/mcp/common/mcpManagementCli.js';
import { IExtensionGalleryManifestService } from '../../platform/extensionManagement/common/extensionGalleryManifest.js';
import { ExtensionGalleryManifestService } from '../../platform/extensionManagement/common/extensionGalleryManifestService.js';
import { IMcpManagementService } from '../../platform/mcp/common/mcpManagement.js';
import { McpManagementService } from '../../platform/mcp/common/mcpManagementService.js';
import { IMcpResourceScannerService, McpResourceScannerService } from '../../platform/mcp/common/mcpResourceScannerService.js';
class CliMain extends Disposable {
@@ -224,6 +227,10 @@ class CliMain extends Disposable {
// Localizations
services.set(ILanguagePackService, new SyncDescriptor(NativeLanguagePackService, undefined, false));
// MCP
services.set(IMcpResourceScannerService, new SyncDescriptor(McpResourceScannerService, undefined, true));
services.set(IMcpManagementService, new SyncDescriptor(McpManagementService, undefined, true));
// Telemetry
const appenders: ITelemetryAppender[] = [];
const isInternal = isInternalTelemetry(productService, configurationService);