VSCode extension MCP panel shows "X Failed" for github server that is actually connected
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
VSCode extension MCP panel shows "Failed" for github server that is actually connected
Environment
Platform: Windows 11 (German locale)
Claude Code version: 2.1.80 (npm-global)
Node.js: C:\Program Files\nodejs\node.exe
VS Code: latest stable
Terminal: PowerShell 5.1
Bug Description
The Claude Code VS Code extension's MCP status panel shows X Failed with MCP error -32000: Connection closed for the github MCP server — but the server is actually connected and functional.
Evidence that the server works
/doctor output (clean, no warnings):
Diagnostics
└ Currently running: npm-global (2.1.80)
└ Config install method: global
└ Search: OK (vendor)
Version Locks
└ No active version locks
claude mcp list from VS Code integrated terminal:
context7: https://mcp.context7.com/mcp (HTTP) - ✓ Connected
github: cmd /c npx -y @modelcontextprotocol/server-github - ✓ Connected
Both commands run from within VS Code's integrated terminal confirm the server is healthy and connected.
"github": {
"type": "stdio",
"command": "cmd",
"args": ["/c", "npx", "-y", "@modelcontextprotocol/server-github"],
"env": {
"GITHUB_TOKEN": "<redacted>"
}
}
What Should Happen?
Expected behavior
The VS Code extension MCP panel should show the github server as connected, matching the actual connection status reported by claude mcp list and /doctor.
Actual behavior
The VS Code extension MCP panel shows X Failed with error -32000: Connection closed, even though the server is connected and functional. This appears to be a display/initialization timing issue specific to the VS Code extension — the CLI works correctly.
Error Messages/Logs
MCP error -32000: Connection closed for the github MCP server
Steps to Reproduce
Configure a github MCP server with cmd /c npx wrapper on Windows (as recommended by /doctor)
Set GITHUB_TOKEN as a system/user environment variable
Open VS Code, start Claude Code
Observe the MCP status panel — github shows X Failed
Run claude mcp list in the integrated terminal — github shows ✓ Connected
Run /doctor — no MCP warnings
Claude Model
Sonnet (default)
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
2.1.80
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
VS Code integrated terminal
Additional Information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗