1.8 KiB
1.8 KiB
Resolution
00001KVHR3WRY を完了しました。
実装内容:
- New internal crate
mcpを追加しました。 - Explicit MCP stdio server config から resolved stdio server spec を作成する bridge を追加しました。
- Tokio child process による local stdio MCP server lifecycle foundation を実装しました。
- stdin/stdout/stderr handling、newline-delimited JSON-RPC request/response handling、initialize/capability negotiation、
notifications/initializedを実装しました。 - stdout/stderr/protocol payloads は bounded に扱います。
- stderr は bounded diagnostics/logging として扱い、protocol failure とは別扱いです。
- server name / phase-aware errors を追加しました。
- shutdown は stdin close / wait / terminate / kill fallback で deterministic に行います。
- Server-to-client requests は fail-closed し、sampling/elicitation は advertise せず、unknown request は JSON-RPC error で返します。
McpStdioServerSpecのDebugは custom redacted 実装にし、resolved env/secret-derived values を出さない regression test を追加しました。- ToolRegistry / tools/resources/prompts registration、remote MCP / Streamable HTTP / OAuth は実装していません。
主な commit:
a114fa9d mcp: implement stdio lifecycle clientf396e1a2 mcp: redact stdio server spec debug9cf5344f merge: mcp stdio lifecycle client
Review:
- r1 は resolved spec
Debugによる env/secret leak でrequest_changes。 - Coder が custom redacted
Debugと regression test を追加。 - r2 は
approve。
最終 validation:
cargo fmt --checkgit diff --check HEAD^1..HEADcargo test -p mcpcargo checkcargo tree -p mcp --depth 1nix build .#yoi --no-link
Package impact:
nix path-info -S .#yoi:112615056