From 332e8aa3e5b63a30b1da70c87024a1a811382c2f Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Tue, 11 Aug 2026 13:47:34 +0000 Subject: [PATCH] style: apply ruff format to touched handlers Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> --- litellm/integrations/websearch_interception/handler.py | 4 +--- litellm/llms/anthropic/chat/guardrail_translation/handler.py | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/litellm/integrations/websearch_interception/handler.py b/litellm/integrations/websearch_interception/handler.py index 5077528af50..7bbafc8d8c6 100644 --- a/litellm/integrations/websearch_interception/handler.py +++ b/litellm/integrations/websearch_interception/handler.py @@ -949,9 +949,7 @@ class WebSearchInterceptionLogger(CustomLogger): if not native_blocks: return response if isinstance(response, _MutableMappingLike) and isinstance(response, dict): - response["content"] = WebSearchInterceptionLogger._prepended_content( - response.get("content"), native_blocks - ) + response["content"] = WebSearchInterceptionLogger._prepended_content(response.get("content"), native_blocks) return response if isinstance(response, _HasContent): try: diff --git a/litellm/llms/anthropic/chat/guardrail_translation/handler.py b/litellm/llms/anthropic/chat/guardrail_translation/handler.py index 0d65d4058cd..afd491c5569 100644 --- a/litellm/llms/anthropic/chat/guardrail_translation/handler.py +++ b/litellm/llms/anthropic/chat/guardrail_translation/handler.py @@ -1163,9 +1163,7 @@ class AnthropicMessagesHandler(BaseTranslation): """ try: sse_string: Final = sse_bytes.decode("utf-8") - return "".join( - self._sse_text_delta(event) for event in sse_string.split("\n\n") if event.strip() - ) + return "".join(self._sse_text_delta(event) for event in sse_string.split("\n\n") if event.strip()) except Exception as e: verbose_proxy_logger.error("Error extracting text from SSE: %s", e) return ""