go-sdk/internal/jsonrpc2
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Robert Findley b34ba2149d
mcp: handle bad or missing params (#210)
Audit all cases where params must not be null, and enforce this using
methodInfo via a new methodFlags bitfield that parameterizes method
requirements. Write extensive conformance tests catching all the
(server-side) crashes that were possible.

We should go further and validate schema against the spec, but that is
more indirect, more complicated, and potentially slower. For now we
adopt this more explicit approach.

Still TODO in a subsequent CL: verify the client side of this with
client conformance tests.

Additionally, improve some error messages that were redundant or leaked
internal implementation details.

Fixes #195
2025-07-31 10:57:59 -04:00
..
conn.go internal/jsonrpc2,mcp: fix typos (#183) 2025-07-28 12:18:03 -04:00
frame.go internal/jsonrpc2_v2: refactor Reader/Writer and remove event dependency 2025-06-10 07:56:09 -07:00
jsonrpc2.go x/tools: modernize interface{} -> any 2025-02-19 15:14:27 -08:00
jsonrpc2_test.go internal/jsonrpc2_v2,mcp: remove unneeded dependencies 2025-06-18 22:11:26 -07:00
messages.go jsonrpc: expose encoding and decoding functions (#114) 2025-07-14 07:01:40 -04:00
net.go internal/jsonrpc2_v2: update for go1.16+ 2025-05-27 10:50:54 -07:00
serve.go internal/mcp: implement HTTP SSE transport 2025-04-23 19:15:20 -07:00
serve_test.go internal/jsonrpc2_v2,mcp: remove unneeded dependencies 2025-06-18 22:11:26 -07:00
wire.go mcp: handle bad or missing params (#210) 2025-07-31 10:57:59 -04:00
wire_test.go x/tools: modernize interface{} -> any 2025-02-19 15:14:27 -08:00