NullPointerException in McpClientSession
還沒有人認領這個 Issue。
評估
研究方向
從 mcp-core/src/main/java/io/modelcontextprotocol/spec/McpClientSession.java 第 280 行開始,檢查與回報的 FluxHandle NPE 相關的 sendRequest 流程。以 enola-dev/enola#1862 中描述的故障和 0.14.1 環境作為背景;完成的條件是該故障不再產生資訊不足的 NPE,而是改為回報清楚的錯誤。
由索引模型根據 Issue 內容生成。
描述
Please do a quick search on GitHub issues first, there might be already a duplicate issue for the one you are about to create.
If the bug is trivial, just go ahead and create the issue. Otherwise, please take a few moments and fill in the following sections:
Bug description
In https://github.com/enola-dev/enola/issues/1862, I've run into:
java.lang.NullPointerException: data
at java.base/java.util.Objects.requireNonNull(Objects.java:259)
at reactor.core.publisher.FluxHandle$HandleSubscriber.next(FluxHandle.java:251)
at io.modelcontextprotocol.spec.McpClientSession.lambda$sendRequest$12(McpClientSession.java:280)
at reactor.core.publisher.FluxHandle$HandleSubscriber.onNext(FluxHandle.java:113)
at reactor.core.publisher.SerializedSubscriber.onNext(SerializedSubscriber.java:99)
at reactor.core.publisher.FluxTimeout$TimeoutMainSubscriber.onNext(FluxTimeout.java:181)
at reactor.core.publisher.MonoCreate$DefaultMonoSink.success(MonoCreate.java:176)
I guess that this means that this is null?
Environment
0.14.1
Steps to reproduce
Unfortunately I'm unable to reproduce it locally even myself, but I am consistently seeing this on a failing CI build.
Expected behavior
Clear error message instead of NPE.
Minimal Complete Reproducible example
N/A
- 主要語言
- Java
- 星號
- 3.7k
- 分支
- 1.1k
- 平均合併
- 1 天 15 小時
- 30 天內合併 PR
- 9
貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
modelcontextprotocol/java-sdk 的其他 Issue
-
area/transport bug P2
難度 2/5 1-3 小時 新手友好度 88/100
modelcontextprotocol/java-sdk#1136 ·
-
area/client bug P2
難度 2/5 1-3 小時 新手友好度 84/100
modelcontextprotocol/java-sdk#1124 · 1 則留言 ·
-
ServerCapabilities.logging is added unconditionally, overriding the caller's explicit capabilities 未關閉bug P2 ready for work
難度 2/5 1-3 小時 新手友好度 68/100
modelcontextprotocol/java-sdk#1086 · 1 則留言 ·
-
enhancement good first issue P3
難度 2/5 1-3 小時 新手友好度 82/100
modelcontextprotocol/java-sdk#1067 ·
-
bug P2 ready for work
難度 2/5 1-3 小時 新手友好度 74/100
modelcontextprotocol/java-sdk#898 · 1 則留言 ·
查看 modelcontextprotocol/java-sdk 的全部 Issue
相似的 Issue
-
area/plugin
難度 2/5 1-3 小時 新手友好度 75/100
kestra-io/plugin-kestra#190 ·
-
難度 2/5 1-3 小時 新手友好度 70/100
google-ai-edge/LiteRT-LM#3739 ·
-
bug
難度 2/5 1-3 小時 新手友好度 75/100
-
難度 2/5 1-3 小時 新手友好度 75/100
integra-team-red/meet-map#249 ·
-
[Studio][Bug] Cancelled create-user dialog keeps the password and admin switch for the next attempt 未關閉
難度 2/5 1-3 小時 新手友好度 75/100
apache/rocketmq-dashboard#5064 ·