always retry httpx errors

This commit is contained in:
Paul Gauthier 2024-05-11 15:01:56 -07:00
parent 6c45b58698
commit 4841f318c1

View file

@ -20,6 +20,13 @@ def should_giveup(e):
if not hasattr(e, "status_code"):
return False
if type(e) in (
httpx.ConnectError,
httpx.RemoteProtocolError,
httpx.ReadTimeout,
):
return False
return not litellm._should_retry(e.status_code)