From 8f3a0894c2b8d21a517a8d8ea8141b9bc905920e Mon Sep 17 00:00:00 2001 From: ege-arhan Date: Thu, 22 Oct 2026 17:31:01 +0000 Subject: [PATCH] fix(utils): add reason to pyright ignore for allowed_tools guard --- litellm/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/litellm/utils.py b/litellm/utils.py index 36f3fcd637a..f863d7c285e 100644 --- a/litellm/utils.py +++ b/litellm/utils.py @@ -9056,7 +9056,7 @@ def validate_chat_completion_tool_choice( # {"type": "allowed_tools", "allowed_tools": {"mode": ..., "tools": [...]}}. # Pass it through untouched so downstream providers see the full payload. if tool_choice_type == "allowed_tools" and isinstance( - tool_choice.get("allowed_tools"), # pyright: ignore[reportUnknownMemberType, reportUnknownVariableType] + tool_choice.get("allowed_tools"), # pyright: ignore[reportUnknownMemberType, reportUnknownVariableType] # raw dict payload dict, ): return tool_choice