Allow latest server.json schema in assisted NuGet MCP install flow#1268
Merged
connor4312 merged 7 commits intomicrosoft:mainfrom Oct 13, 2025
Merged
Allow latest server.json schema in assisted NuGet MCP install flow#1268connor4312 merged 7 commits intomicrosoft:mainfrom
connor4312 merged 7 commits intomicrosoft:mainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR updates the NuGet MCP server installation flow to support multiple versions of the server.json schema format. The changes allow the extension to handle both legacy and current schema versions when processing NuGet package manifests.
- Refactored package reference fixing logic to support multiple schema formats
- Added comprehensive test coverage for different schema versions
- Improved error handling and validation for server.json parsing
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/extension/mcp/vscode-node/nuget.ts | Refactored readServerManifest method to extract package reference fixing logic and support multiple schema formats (registry_name, registry_type, registryType) |
| src/extension/mcp/test/vscode-node/nuget.stub.spec.ts | Added unit tests to verify handling of different schema versions (2025-07-29 original, latest, and 2025-09-29) |
Co-authored-by: Copilot <[email protected]>
connor4312
reviewed
Oct 8, 2025
| } | ||
|
|
||
| const json = await fs.readFile(serverJsonPath, 'utf8'); | ||
| const manifest = JSON.parse(json); |
Member
There was a problem hiding this comment.
JSON.parse will throw if it's invalid, we should probably catch that here too
…/new-schema # Conflicts: # src/extension/mcp/vscode-node/nuget.ts
|
knkl |
connor4312
approved these changes
Oct 13, 2025
TylerLeonhardt
approved these changes
Oct 13, 2025
dileepyavan
pushed a commit
that referenced
this pull request
Oct 14, 2025
…1268) * Align to latest schema * Handle more schema differences * Add tests * Update src/extension/mcp/vscode-node/nuget.ts Co-authored-by: Copilot <[email protected]> * Prepare the manifest for VS Code integration --------- Co-authored-by: Copilot <[email protected]> Co-authored-by: Connor Peet <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolve microsoft/vscode#266097