-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Description
Describe the bug
The Copilot CLI UI incorrectly displays MCP servers as successfully loaded even when they fail to initialize. This creates a confusing user experience where users believe tools are available when they are not.
In this case, the Playwright MCP server failed to start due to an npm authentication error, but the UI did not reflect this failure state to the user.
Affected version
0.0.395
Steps to reproduce the behavior
- Configure the Playwright MCP server in your MCP settings with the following command
{
"mcpServers": {
"playwright": {
"command": "npx",
"args": ["@playwright/mcp@latest", "--extension", "--browser", "msedge"]
}
}
}
- Ensure npm authentication will fail (e.g., expired credentials, private registry misconfiguration, or network issues)
- Start Copilot CLI with debug logging enabled
copilot --log-dir ./logs --log-level debug - Observe the UI shows the Playwright MCP server as loaded/available
- Show MCP servers
/mcp show - See the logs in
./logsdirectory
Expected behavior
- The UI should accurately reflect the connection status of each MCP server
- Failed MCP servers should be clearly marked as failed/unavailable in the UI
- Users should see an error indicator or message when an MCP server fails to initialize
- Ideally, show a brief reason for the failure (e.g., "npm authentication error" or "Connection closed")
Additional context
2026-01-26T22:06:22.361Z [ERROR] Starting MCP client for playwright with
command: npx
args: @playwright/mcp@latest --extension --browser msedge
cwd: undefined
2026-01-26T22:06:24.155Z [ERROR] [mcp server playwright stderr] npm error code E401
2026-01-26T22:06:24.156Z [ERROR] [mcp server playwright stderr] npm error Incorrect or missing password.
npm error If you were trying to login, change your password, create an
npm error authentication token or enable two-factor authentication then
npm error that means you likely typed your password in incorrectly.
npm error Please try again, or recover your password at:
npm error https://www.npmjs.com/forgot
2026-01-26T22:06:24.177Z [ERROR] MCP transport for playwright closed
2026-01-26T22:06:24.178Z [ERROR] Failed to start MCP client for playwright: McpError: MCP error -32000: Connection closed
Copilot CLI Version: 0.0.395
Node.js Version: v24.11.1
OS: Windows
MCP Command: npx @playwright/mcp@latest --extension --browser msedge