Skip to content

Commit

Permalink
fix(cost_calculator.py): move to debug for noisy warning message on c…
Browse files Browse the repository at this point in the history
…ost calculation error

Fixes #5610
  • Loading branch information
krrishdholakia committed Sep 10, 2024
1 parent b1ecfe0 commit 745d6b9
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions litellm/cost_calculator.py
Original file line number Diff line number Diff line change
Expand Up @@ -829,18 +829,11 @@ def response_cost_calculator(
)
return None
except Exception as e:
if litellm.suppress_debug_info: # allow cli tools to suppress this information.
verbose_logger.debug(
"litellm.cost_calculator.py::response_cost_calculator - Returning None. Exception occurred - {}/n{}".format(
str(e), traceback.format_exc()
)
)
else:
verbose_logger.warning(
"litellm.cost_calculator.py::response_cost_calculator - Returning None. Exception occurred - {}/n{}".format(
str(e), traceback.format_exc()
)
verbose_logger.debug(
"litellm.cost_calculator.py::response_cost_calculator - Returning None. Exception occurred - {}/n{}".format(
str(e), traceback.format_exc()
)
)
return None


Expand Down

0 comments on commit 745d6b9

Please sign in to comment.