fix: replace http code by jsonrpc (#1920)

This commit is contained in:
Marcelo Trylesinski 2026-01-21 18:37:55 +01:00 • committed by GitHub
commit 656f887aff
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -50,12 +50,7 @@ def validate_sampling_tools(
"""
if tools is not None or tool_choice is not None:
if not check_sampling_tools_capability(client_caps):
raise McpError(
ErrorData(
code=INVALID_PARAMS,
message="Client does not support sampling tools capability",
)
)
raise McpError(ErrorData(code=INVALID_PARAMS, message="Client does not support sampling tools capability"))
def validate_tool_use_result_messages(messages: list[SamplingMessage]) -> None: