Skip to content

fix(deps): update mcp-go to v1.1.1 so fly mcp server stops hanging - #5308

Merged
dangra merged 1 commit into
superfly:masterfrom
everm1nd:bump-mcp-go-v1.1.1
Oct 15, 2026
Merged

dangra merged 1 commit into
superfly:masterfrom
everm1nd:bump-mcp-go-v1.1.1

Conversation

@everm1nd

Copy link
Copy Markdown
Contributor

Change Summary

What and Why:

fly mcp server stops answering requests once an MCP client opens a subscriptions/listen stream. Clients that negotiate protocol 2026-07-28 do this right after server/discover, because flyctl advertises tools.listChanged. After that, tools/list never returns, so the client loads no Fly tools and times out on every retry. The process also doesn't exit when stdin closes, so stale fly mcp server processes pile up. Details and a repro are in #5307.

The bug is in mcp-go v1.1.0. Its stdio server handles subscriptions/listen inline on the read loop and blocks there until shutdown (mark3labs/mcp-go#976). It was fixed in mark3labs/mcp-go#977 and released in v1.1.1. fly mcp proxy uses the same ServeStdio path, and its relayed tools also advertise listChanged, so it gets the same fix.

How:

  • Bump github.com/mark3labs/mcp-go from v1.1.0 to v1.1.1 (go get + go mod tidy). Only go.mod and go.sum change.
  • v1.1.1 is a patch release with five bug fixes. It adds no exported declarations and changes no signatures.
  • One of those fixes (fix(server): validate x-mcp-header annotations on every tool registration path mark3labs/mcp-go#986) extends the existing x-mcp-header validation to AddTaskTools, SetTools and AddSessionTools. flyctl only calls AddTool, which v1.1.0 already validated, so its behavior doesn't change.

Tested locally on macOS arm64 with Go 1.27.2:

fly v0.4.116 (mcp-go v1.1.0)        id=1, subscriptions/acknowledged; no tools/list response; still running after stdin EOF
this branch  (mcp-go v1.1.1)        id=1, id=2, id=3 (60 tools); exits on stdin EOF
  • The older initialize handshake (2025-11-25) still returns all 60 tools on this branch.
  • I didn't test fly mcp proxy end to end. It gets the fix through the same ServeStdio code path.

Related to: Fixes #5307


Documentation

  • Fresh Produce
  • In superfly/docs, or asked for help from docs team
  • n/a

mcp-go v1.1.0 handles subscriptions/listen inline on the stdio read
loop and blocks there until shutdown. Clients that negotiate MCP
protocol 2026-07-28 open that subscription right after
server/discover (flyctl advertises tools.listChanged), so every
later request, including tools/list, goes unanswered and the
process no longer exits when stdin closes. This affects both
`fly mcp server` and `fly mcp proxy`.

v1.1.1 serves requests off the read loop (mark3labs/mcp-go#977,
fixing mark3labs/mcp-go#976). It is a patch release with five
bug fixes and no API changes.

Fixes superfly#5307

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI balanced review requested due to automatic review settings October 15, 2026 20:08

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The targeted dependency update addresses the reported hang, with no blocking issues identified.

0 open findings

What changed in this PR

Updates mcp-go to resolve the stdio subscription hang reported in #5307, covering both fly mcp server and fly mcp proxy.

Changes:

  • Bumps mcp-go from v1.1.0 to v1.1.1.
  • Updates dependency checksums without changing application code.
File Description
go.sum Updates checksums for mcp-go v1.1.1.
go.mod Selects the patch release containing the stdio fix.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@everm1nd everm1nd changed the title Bump mcp-go to v1.1.1 so fly mcp server stops hanging fix(deps): update mcp-go to v1.1.1 so fly mcp server stops hanging Oct 15, 2026
@dangra
dangra merged commit 6a07c61 into superfly:master Oct 15, 2026
@dangra

dangra commented Oct 15, 2026

Copy link
Copy Markdown
Member

thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fly mcp server hangs after subscriptions/listen (stdio deadlock from mcp-go v1.1.0; fixed in v1.1.1)

3 participants