mcpManagementService.ts ×10

Frontier kind: Code frontier

unlabeled · c_0fb09fae5ec5

35 tests · 14869 LOC · 69 files · introduces 0 tests · 19 LOC · 1 file

Introduces — evidence that enters the hierarchy at this concept

Code
10 ranges19 lines · 1 files
Tests
0 tests

Contains — complete concept membership

All code (extent)
1898 ranges14869 lines · 69 files · Browse complete extent
All tests (intent)
35 testsBrowse complete intent

Neighbourhood graph

The orange circle is the focus. Violet and green circles are every ancestor and descendant, broader and narrower, at any distance; blue squares and pink diamonds are the introduced files and exact introduced tests of every visible concept, not only the focus's. Arrows point from broader to narrower concepts and bridge only concepts omitted from this view. Undirected links show source or test introduction. Concept and file size follows LOC; exact test nodes use test-count units.

Introduced files, introduced tests, and structurally relevant concept specialization

In the embedded map, ordinary wheel input scrolls the page; use the visible controls to zoom and drag to pan. Open the full-screen map for canvas navigation: wheel pans, Ctrl/Command plus wheel zooms, and arrow keys pan when this region is focused. On touch screens, open the full-screen map to pan or pinch. If JavaScript or WebGL is unavailable, use the native relationship evidence on this page.

Graph controls are ready.

Interactive rendering requires JavaScript and WebGL. Use the native relationship evidence on this page while the interactive map is unavailable.

Native relationship evidence

Every exact file and test below is linked only from the concept that introduces it.

Introduced tests

Every collected test enters the hierarchy at exactly one concept.

No tests are introduced at this concept. Its intent tests are introduced by other concepts.

Introduced code

Every collected source range enters the hierarchy at exactly one concept.

1 file ranked by introduced lines: 19 introduced LOC across 10 ranges. Expand a file to inspect source; the > gutter marks introduced lines.

src/vs/platform/mcp/common/mcpManagementService.ts 19 introduced LOC · 10 ranges

Open complete file

71
72 getMcpServerConfigurationFromManifest(manifest: IGalleryMcpServerConfiguration, packageType: RegistryType): McpServerConfigurationParseResult {
74 > // remote
75 > if (packageType === RegistryType.REMOTE && manifest.remotes?.length) {
76 const url = manifest.remotes[0].url;
77 const headers = manifest.remotes[0].headers ?? [];
91
92 // local
93 > const serverPackage = manifest.packages?.find(p => p.registryType === packageType) ?? manifest.packages?.[0]; mcpManagementService.ts
94 > if (!serverPackage) {
95 throw new Error(`No server package found`);
96 }
107 }
108
109 > if (serverPackage.runtimeArguments?.length) { mcpManagementService.ts
110 const result = this.processArguments(serverPackage.runtimeArguments ?? []);
111 args.push(...result.args);
114 }
115
116 > if (serverPackage.environmentVariables?.length) { mcpManagementService.ts
117 const { inputs: envInputs, variables: envVariables, notices: envNotices } = this.processKeyValueInputs(serverPackage.environmentVariables ?? []);
118 inputs.push(...envVariables);
134 args.push(serverPackage.version ? `${serverPackage.identifier}@${serverPackage.version}` : serverPackage.identifier);
135 break;
136 > case RegistryType.PYTHON: mcpManagementService.ts
137 if (serverPackage.registryBaseUrl) {
138 args.push('--index-url', serverPackage.registryBaseUrl);
140 args.push(serverPackage.version ? `${serverPackage.identifier}@${serverPackage.version}` : serverPackage.identifier);
141 break;
142 > case RegistryType.DOCKER: mcpManagementService.ts
143 {
144 const dockerIdentifier = serverPackage.registryBaseUrl
148 break;
149 }
150 > case RegistryType.NUGET: mcpManagementService.ts
151 args.push(serverPackage.version ? `${serverPackage.identifier}@${serverPackage.version}` : serverPackage.identifier);
152 args.push('--yes'); // installation is confirmed by the UI, so --yes is appropriate here
158 }
159 break;
161
162 > if (serverPackage.packageArguments?.length) { mcpManagementService.ts
163 const result = this.processArguments(serverPackage.packageArguments);
164 args.push(...result.args);
173 type: McpServerType.LOCAL,
174 command: this.getCommandName(serverPackage.registryType),
175 > args: args.length ? args : undefined, mcpManagementService.ts
176 > env: Object.keys(env).length ? env : undefined,
177 > },
178 > inputs: inputs.length ? inputs : undefined,
179 > }
180 > };
181 > }
182
183 protected getCommandName(packageType: RegistryType): string {