Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

stdio transport: a request over the maximum line length gets no answer

未关闭
#1,395 1 条评论 0 个 reaction 已指派 1 人 在 GitHub 查看

维护者通常 3 天内回复

@gocamille 已经在做这个了。

开始于 2026年10月26日。

评估

这个 Issue 还没有评估数据。

描述

bug P1 ready for work T-transport

Since #1049 (rmcp 3.6.0) AsyncRwTransport drops a line that is longer than the maximum line length (16 MiB by default). It only writes a log entry. When that line is a request, the peer never gets an answer and waits until its own timeout. From the client side this looks like a server that hangs.

I found this while writing an MCP server that takes large inline files. A tools/call with a large base64 file in the arguments is enough.

To reproduce:

  1. Start any stdio server built on rmcp 3.7.0.
  2. Send initialize and notifications/initialized.
  3. Send one tools/call request whose line is larger than 16 MiB, for example with a 17 MiB string in arguments.
  4. The server logs "Incoming message exceeded the maximum line length, discarding it". The client gets nothing for this id.

Expected: an error answer for the request id, like the -32600 Invalid Request answer rmcp already sends for valid JSON with the wrong shape.

Lines without an id, responses and input that is not JSON should stay unanswered, so this does not bring back the error storm from #938.

I have a fix ready that builds on #1370. I can open it after that PR is merged.

主要语言
Rust
星标
4.1k
派生
680
平均合并
3 天 15 小时
30 天内合并 PR
34

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

modelcontextprotocol/rust-sdk 的其他 Issue

查看 modelcontextprotocol/rust-sdk 的全部 Issue

相似的 Issue

更多 Rust Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。