Update McpErrorCode XML docs and fix error code usage to align with MCP spec (#1291)
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: stephentoub <2642209+stephentoub@users.noreply.github.com>
This commit is contained in:
parent
5651e9ebfe
commit
186cb93630
1 changed files with 30 additions and 17 deletions
|
|
@ -591,7 +591,7 @@ internal sealed partial class McpServerImpl : McpServer
|
|||
{
|
||||
throw new McpProtocolException(
|
||||
$"Tool '{tool.ProtocolTool.Name}' does not support task-augmented execution.",
|
||||
McpErrorCode.MethodNotFound);
|
||||
McpErrorCode.InvalidParams);
|
||||
}
|
||||
|
||||
// Task augmentation requested - return CreateTaskResult
|
||||
|
|
@ -604,7 +604,7 @@ internal sealed partial class McpServerImpl : McpServer
|
|||
throw new McpProtocolException(
|
||||
$"Tool '{tool.ProtocolTool.Name}' requires task-augmented execution. " +
|
||||
"Include a 'task' parameter with the request.",
|
||||
McpErrorCode.MethodNotFound);
|
||||
McpErrorCode.InvalidParams);
|
||||
}
|
||||
|
||||
// Normal synchronous execution
|
||||
|
|
|
|||
Loading…
Reference in a new issue