From 6f9c6143d691c910a635be068c713e4b67f40efb Mon Sep 17 00:00:00 2001 From: ege-arhan Date: Mon, 21 Sep 2026 09:35:44 +0000 Subject: [PATCH] chore: justify LIT002 stash dict with mutable-ok reason (gate delta) --- litellm/llms/openai_like/messages/transformation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/litellm/llms/openai_like/messages/transformation.py b/litellm/llms/openai_like/messages/transformation.py index 67e2c2e28be..78429738ce7 100644 --- a/litellm/llms/openai_like/messages/transformation.py +++ b/litellm/llms/openai_like/messages/transformation.py @@ -88,7 +88,7 @@ class OpenAILikeAnthropicMessagesConfig(AnthropicMessagesConfig): model the cost map does not know (see #40890). Pop them before the base transform so no drop warning fires, restore afterwards. """ - stashed: dict = {} + stashed: dict = {} # mutable-ok: transient pop/restore stash, never escapes the call for _key in ("thinking", "output_config", "temperature"): if _key in anthropic_messages_optional_request_params: stashed[_key] = anthropic_messages_optional_request_params.pop(_key)