From f8179498fff04ac725a60fefeda69ee59fbbc131 Mon Sep 17 00:00:00 2001 From: giulio-leone Date: Thu, 5 Mar 2026 17:14:30 +0100 Subject: [PATCH] =?UTF-8?q?fix:=20change=20all=20verbose=5Flogger.warning?= =?UTF-8?q?=20=E2=86=92=20info=20in=20websearch=20handler?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Per Sameerlite's review: warning-level logs trigger Slack alerts. All 6 remaining .warning() calls were operational/fallback messages, not actual errors. Changed to .info() to match the first fix at L510. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .../integrations/websearch_interception/handler.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/litellm/integrations/websearch_interception/handler.py b/litellm/integrations/websearch_interception/handler.py index 82121f75e41..284b45fda28 100644 --- a/litellm/integrations/websearch_interception/handler.py +++ b/litellm/integrations/websearch_interception/handler.py @@ -502,7 +502,7 @@ class WebSearchInterceptionLogger(CustomLogger): ) search_tasks.append(self._execute_search(query)) else: - verbose_logger.warning( + verbose_logger.info( f"WebSearchInterception: Tool call {tool_call['id']} has no query" ) # Add empty result for tools without query @@ -529,7 +529,7 @@ class WebSearchInterceptionLogger(CustomLogger): final_search_results.append(cast(str, result)) else: # Should never happen, but handle for type safety - verbose_logger.warning( + verbose_logger.info( f"WebSearchInterception: Unexpected result type {type(result)} at index {i}" ) final_search_results.append(str(result)) @@ -619,7 +619,7 @@ class WebSearchInterceptionLogger(CustomLogger): try: from litellm.proxy.proxy_server import llm_router except ImportError: - verbose_logger.warning( + verbose_logger.info( "WebSearchInterception: Could not import llm_router from proxy_server, " "falling back to direct litellm.asearch() with perplexity" ) @@ -642,7 +642,7 @@ class WebSearchInterceptionLogger(CustomLogger): f"with provider '{search_provider}'" ) else: - verbose_logger.warning( + verbose_logger.info( f"WebSearchInterception: Search tool '{self.search_tool_name}' not found in router, " "falling back to first available or perplexity" ) @@ -716,7 +716,7 @@ class WebSearchInterceptionLogger(CustomLogger): ) search_tasks.append(self._execute_search(query)) else: - verbose_logger.warning( + verbose_logger.info( f"WebSearchInterception: Tool call {tool_call.get('id')} has no query" ) # Add empty result for tools without query @@ -741,7 +741,7 @@ class WebSearchInterceptionLogger(CustomLogger): elif isinstance(result, str): final_search_results.append(cast(str, result)) else: - verbose_logger.warning( + verbose_logger.info( f"WebSearchInterception: Unexpected result type {type(result)} at index {i}" ) final_search_results.append(str(result))