python-sdk icon indicating copy to clipboard operation
python-sdk copied to clipboard

Add Automated Tests for src/mcp/client/sse.py and src/mcp/server/sse.py

Open apappascs opened this issue 11 months ago • 0 comments

The files src/mcp/client/sse.py and src/mcp/server/sse.py implement the client and server functionalities for SSE transport, but there are no tests in the repository to verify their behavior.

Relevant Links: PR: https://github.com/modelcontextprotocol/python-sdk/pull/83 Related Discussion: https://github.com/jlowin/fastmcp/issues/69 Related Issue: https://github.com/modelcontextprotocol/python-sdk/issues/101

apappascs avatar Dec 21 '24 18:12 apappascs

Please help me!

windcandle avatar Oct 12 '24 09:10 windcandle

Can I work on this issue?

Harsimran-19 avatar Oct 12 '24 15:10 Harsimran-19

@Harsimran-19 you can?

windcandle avatar Oct 14 '24 05:10 windcandle

I'm having the same problem. Did you solve it? @windcandle

Pan-Binghong avatar Oct 28 '24 06:10 Pan-Binghong

similar question! The error messages as followed:

pydantic_core._pydantic_core.ValidationError: 1 validation error for Xinference
client
  Field required [type=missing, input_value={'server_url': 'http://0....Tl', 'model_kwargs': {}}, input_type=dict]
    For further information visit https://errors.pydantic.dev/2.9/v/missing

how to solve it?

AI-Surfing avatar Oct 29 '24 04:10 AI-Surfing

same problem here!

spark-ws avatar Oct 31 '24 10:10 spark-ws

pip install langchain_community==0.2 problem solved

fz5400 avatar Nov 05 '24 09:11 fz5400

In package 'lanchain_community.llms.xinference', make client: Optional[Any] = None optional, then ok. langchain-community==0.3.9 @spark-ws @AI-Surfing @windcandle @Pan-Binghong

jsli avatar Dec 06 '24 07:12 jsli

In package 'lanchain_community.llms.xinference', make client: Optional[Any] = None optional, then ok. langchain-community==0.3.9 @spark-ws @AI-Surfing @windcandle @Pan-Binghong

can you show me the code?thanks

bigfool avatar Dec 19 '24 06:12 bigfool

In package 'lanchain_community.llms.xinference', make client: Optional[Any] = None optional, then ok. langchain-community==0.3.9 @spark-ws @AI-Surfing @windcandle @Pan-Binghong

can you show me the code?thanks

截图 2025-01-02 17-09-47

same problem. It works for me.

leo-liu-83 avatar Jan 02 '25 09:01 leo-liu-83

Hi, @windcandle. I'm Dosu, and I'm helping the LangChain team manage their backlog. I'm marking this issue as stale.

Issue Summary

  • The issue involves a ValidationError when initializing Xinference due to a missing "client" field.
  • Several users, including @Pan-Binghong, @AI-Surfing, and @spark-ws, reported the same problem.
  • @jsli suggested making the client field optional, which resolved the issue, confirmed by @leo-liu-83.
  • A temporary workaround was downgrading to langchain_community==0.2, as suggested by @fz5400.

Next Steps

  • Please confirm if this issue is still relevant to the latest version of the LangChain repository by commenting here.
  • If there is no further activity, this issue will be automatically closed in 7 days.

Thank you for your understanding and contribution!

dosubot[bot] avatar Apr 03 '25 16:04 dosubot[bot]