Henry Mao
ba184a2667
Ruff
2025-03-12 13:51:35 -07:00
Henry Mao
dec28830b9
Remove try except
2025-03-08 10:53:56 +08:00
Henry Mao
ea8a2dbd6d
Reraise exception and make websocket optional
2025-03-08 10:52:10 +08:00
Henry Mao
9d65e5ac03
Remove optional check
2025-03-07 22:02:16 +08:00
Henry Mao
fd826cc7a6
Fix Websocket Client and Add Test
2025-03-07 22:00:56 +08:00
Henry Mao
fc021eea76
Apply suggestions from code review
...
Co-authored-by: Marcelo Trylesinski <marcelotryle@gmail.com >
2025-03-06 20:12:51 +08:00
Henry Mao
f67c3ee6c0
Merge branch 'modelcontextprotocol:main' into patch-1
2025-03-06 13:24:01 +08:00
David Soria Parra
a50cf92d3a
fix: ruff format
2025-02-20 11:04:46 +00:00
Jerome
ff22f48365
Add client handling for sampling, list roots, ping ( #218 )
...
Adds sampling and list roots callbacks to the ClientSession, allowing the client to handle requests from the server.
Co-authored-by: TerminalMan <84923604+SecretiveShell@users.noreply.github.com >
Co-authored-by: David Soria Parra <davidsp@anthropic.com >
2025-02-20 10:49:43 +00:00
David Soria Parra
0d3e02f6a2
fix: standardize resource response format
...
Github-Issue:#141
2025-02-03 11:33:32 +00:00
Henry Mao
1395607583
Create Client websocket.py
2025-01-29 21:27:09 +08:00
TerminalMan
99727a97ae
ruff format
2024-12-29 17:09:18 +00:00
TerminalMan
4f36581a5c
add text encoding params to STDIO client
2024-12-29 16:41:30 +00:00
David Soria Parra
1d4a0d3589
ruff format
2024-12-12 17:01:00 +00:00
David Soria Parra
ef9b4cf6a2
Remove click dependency in client
2024-12-12 16:41:30 +00:00
David Soria Parra
1177a11910
Return a specific server session instance of request context
...
We currently return a generic instance of RequestContext without
a specialization on the Session type. This makes it impossible
for servers to typesafe call `list_roots()` and other methods.
We now return a specific instance of `RequestContext[ServerSession]`
2024-11-11 21:11:13 +00:00
David Soria Parra
ec8c85edea
run ruff
2024-11-11 20:42:46 +00:00
David Soria Parra
b9b44e6dad
Don't re-export types
...
We will be a bit more low level and expect callees to import mcp.types
instead of relying in re-exported types. This makes usage more explicit
and avoids potential collisions in mcp.server.
2024-11-11 20:39:33 +00:00
David Soria Parra
ed87ae9f06
rename mcp_python to mcp
2024-11-11 12:40:32 +00:00