mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-25 10:44:24 +00:00
update exception logic
This commit is contained in:
parent
93fb247b1d
commit
d02ab9bfcd
3 changed files with 17 additions and 3 deletions
|
@ -1762,7 +1762,7 @@ def exception_type(model, original_exception, custom_llm_provider):
|
|||
llm_provider="cohere",
|
||||
model=model
|
||||
)
|
||||
raise ValueError(original_exception)
|
||||
raise original_exception
|
||||
elif custom_llm_provider == "huggingface":
|
||||
if "length limit exceeded" in error_str:
|
||||
exception_mapping_worked = True
|
||||
|
@ -1915,7 +1915,7 @@ def exception_type(model, original_exception, custom_llm_provider):
|
|||
model=model
|
||||
)
|
||||
else:
|
||||
raise ValueError(original_exception)
|
||||
raise original_exception
|
||||
except Exception as e:
|
||||
# LOGGING
|
||||
exception_logging(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue