From cec08f6800549f76251a8989532e30562d827720 Mon Sep 17 00:00:00 2001 From: ishaan-jaff Date: Thu, 25 Jan 2024 11:56:52 -0800 Subject: [PATCH] (fix) alerting debug statements --- litellm/proxy/utils.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/litellm/proxy/utils.py b/litellm/proxy/utils.py index 9bef040348..4c6030e5bc 100644 --- a/litellm/proxy/utils.py +++ b/litellm/proxy/utils.py @@ -200,11 +200,12 @@ class ProxyLogging: # percent of max_budget left to spend percent_left = (user_max_budget - user_current_spend) / user_max_budget verbose_proxy_logger.debug( - f"Bduget Alerts: Percent left: {percent_left} for {user_info}" + f"Budget Alerts: Percent left: {percent_left} for {user_info}" ) # check if crossed budget if user_current_spend >= user_max_budget: + verbose_proxy_logger.debug(f"Budget Crossed for {user_info}") message = "Budget Crossed for" + user_info await self.alerting_handler( message=message, @@ -230,7 +231,7 @@ class ProxyLogging: ) return - pass + return async def alerting_handler( self, message: str, level: Literal["Low", "Medium", "High"]