Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 11, 2026

The Copilot log parser was not detecting MCP server connection failures, allowing workflows to continue running with unavailable tools instead of failing fast with actionable error messages.

Changes

  • Modified parseDebugLogFormat(): Scans debug logs for MCP connection errors using pattern [ERROR] Failed to start MCP client for remote server <name>: TypeError: fetch failed, extracts server names, and immediately calls core.setFailed() to fail the step when failures are detected

  • Updated parseCopilotLog(): Propagates MCP failures from debug log parsing into result object for consistency

  • Added test coverage: 5 test cases covering single/multiple failures, successful connections, deduplication, and verification that core.setFailed() is called with the correct error message

Behavior

// Debug log contains:
// [ERROR] Failed to start MCP client for remote server github: TypeError: fetch failed

// parseDebugLogFormat immediately calls:
core.setFailed("MCP server(s) failed to launch: github")

// Also returns:
result.mcpFailures = ['github']

Without MCP failures, mcpFailures is undefined and execution continues normally. The step fails immediately during log parsing rather than later in the bootstrap layer, providing faster feedback about MCP connection issues.

Original prompt

Update the copilot parser log javascript handler to detect when MCP server fail to connect. The error messages look like this:

2026-01-11T07:21:35.050Z [ERROR] Failed to start MCP client for remote server <server-name>: TypeError: fetch failed

When detecting these errors, fail the step.


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 2 commits January 11, 2026 07:36
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Update MCP server connection error handling in log handler Detect MCP server connection failures in Copilot debug logs Jan 11, 2026
Copilot AI requested a review from pelikhan January 11, 2026 07:43
@pelikhan
Copy link
Contributor

@copilot when you detect a mcp failure, you should fail the step in parseDebugLogFormat

…bugLogFormat

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Jan 11, 2026

@copilot when you detect a mcp failure, you should fail the step in parseDebugLogFormat

Done. Now calling core.setFailed() immediately in parseDebugLogFormat when MCP connection failures are detected. Updated tests verify the call is made with the correct error message. (151e8bf)

@github-actions
Copy link
Contributor

github-actions bot commented Jan 11, 2026

💀 Blimey! Changeset Generator failed and walked the plank! No treasure today, matey! ☠️

@github-actions
Copy link
Contributor

github-actions bot commented Jan 11, 2026

🎬 THE ENDSmoke Claude MISSION: ACCOMPLISHED! The hero saves the day! ✨

@github-actions
Copy link
Contributor

github-actions bot commented Jan 11, 2026

✨ The prophecy is fulfilled... Smoke Codex has completed its mystical journey. The stars align. 🌟

@github-actions
Copy link
Contributor

github-actions bot commented Jan 11, 2026

📰 VERDICT: Smoke Copilot has concluded. All systems operational. This is a developing story. 🎤

@github-actions
Copy link
Contributor

Smoke Test Results (Claude)

Last 2 merged PRs:

Test Results:

  • ✅ GitHub MCP: Retrieved PRs successfully
  • ❌ Serena Go: Tool not available in environment
  • ✅ Playwright: Navigated to GitHub, title verified
  • ❌ Safe Input gh: Tool not available in environment
  • ✅ File Writing: Created test file successfully
  • ✅ Bash Tool: File verification successful

Overall Status: PARTIAL PASS (4/6 tests passed)

AI generated by Smoke Claude

@pelikhan pelikhan closed this Jan 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants