BerriAI / litellm

Python SDK, Proxy Server to call 100+ LLM APIs using the OpenAI format - [Bedrock, Azure, OpenAI, VertexAI, Cohere, Anthropic, Sagemaker, HuggingFace, Replicate, Groq]
https://docs.litellm.ai/docs/
Other
12.17k stars 1.41k forks source link

[Bug]: AttributeError: 'PrometheusLogger' object has no attribute 'litellm_remaining_api_key_requests_for_model' #5334

Closed themrzmaster closed 3 weeks ago

themrzmaster commented 3 weeks ago

What happened?

19:25:30 - LiteLLM:ERROR: litellm_logging.py:1517 - LiteLLM.LoggingError: [Non-Blocking] Exception occurred while success logging Traceback (most recent call last): File "/usr/local/lib/python3.11/site-packages/litellm/litellm_core_utils/litellm_logging.py", line 1449, in async_success_handler await callback.async_log_success_event( File "/usr/local/lib/python3.11/site-packages/litellm/integrations/prometheus.py", line 323, in async_log_success_event self.litellm_remaining_api_key_requests_for_model.labels( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ AttributeError: 'PrometheusLogger' object has no attribute 'litellm_remaining_api_key_requests_for_model'

on proxy image: ghcr.io/berriai/litellm:main-v1.43.19-stable

Relevant log output

No response

Twitter / LinkedIn details

No response

ishaan-jaff commented 3 weeks ago

@themrzmaster do you have prometheus logging on ?

ishaan-jaff commented 3 weeks ago

fixed here: https://github.com/BerriAI/litellm/commit/65c0626aa4c01f387b02cf0238880dfa5bd21593