From a312ef31e39af511688a4d49101edacb519e14d6 Mon Sep 17 00:00:00 2001 From: Yuta Saito Date: Wed, 21 Jan 2026 15:04:24 +0900 Subject: [PATCH] chore: fix mypy --- litellm/responses/mcp/litellm_proxy_mcp_handler.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/litellm/responses/mcp/litellm_proxy_mcp_handler.py b/litellm/responses/mcp/litellm_proxy_mcp_handler.py index 2419126fe2f..4376e076a95 100644 --- a/litellm/responses/mcp/litellm_proxy_mcp_handler.py +++ b/litellm/responses/mcp/litellm_proxy_mcp_handler.py @@ -35,7 +35,9 @@ else: # NOTE: We intentionally keep ToolParam as a broad type here to avoid tight coupling # to optional OpenAI SDK typing symbols in environments that may not have them available. -ToolParam = Dict[str, Any] +# `Any` is used to keep mypy compatible with the broader OpenAI tool union types +# passed around in Responses API while still allowing dict-style access at runtime. +ToolParam = Any LITELLM_PROXY_MCP_SERVER_URL = "litellm_proxy" LITELLM_PROXY_MCP_SERVER_URL_PREFIX = f"{LITELLM_PROXY_MCP_SERVER_URL}/mcp/"