From aa512fac6e6f064315b95a87a94891f52839d6a8 Mon Sep 17 00:00:00 2001 From: Sheng Fan Date: Tue, 18 Mar 2025 11:46:35 +0800 Subject: [PATCH] refactor(app): Complete exception logging in LLM.ask --- app/llm.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/llm.py b/app/llm.py index 18a13af..f78a7f7 100644 --- a/app/llm.py +++ b/app/llm.py @@ -309,8 +309,8 @@ class LLM: elif isinstance(oe, APIError): logger.error(f"API error: {oe}") raise - except Exception as e: - logger.error(f"Unexpected error in ask: {e}") + except Exception: + logger.exception(f"Unexpected error in ask") raise @retry(