fix: reply -32700 on stdio parse errors instead of closing (#833)
* fix: reply -32700 on stdio parse errors instead of closing * fix: make JsonRpcError id optional per MCP spec
This commit is contained in:
parent
0f776ab1d6
commit
321ab14f67
1 changed files with 191 additions and 53 deletions
|
|
@ -219,7 +219,7 @@ where
|
|||
}
|
||||
Err(e) => {
|
||||
transport
|
||||
.send(ServerJsonRpcMessage::error(e.clone(), id))
|
||||
.send(ServerJsonRpcMessage::error(e.clone(), Some(id)))
|
||||
.await
|
||||
.map_err(|error| {
|
||||
ServerInitializeError::transport::<T>(error, "sending error response")
|
||||
|
|
|
|||
Loading…
Reference in a new issue