From 768ce68fc96e47c8aa4a19d530f65e3aca8a43f1 Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Wed, 28 Feb 2024 14:33:03 -0800 Subject: [PATCH] fix(utils.py): fix palm exception mapping --- litellm/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/litellm/utils.py b/litellm/utils.py index a5eee8c56..b025cd60a 100644 --- a/litellm/utils.py +++ b/litellm/utils.py @@ -6972,7 +6972,7 @@ def exception_type( if "500 An internal error has occurred." in error_str: exception_mapping_worked = True raise APIError( - status_code=original_exception.status_code, + status_code=getattr(original_exception, "status_code", 500), message=f"PalmException - {original_exception.message}", llm_provider="palm", model=model,