mirror of
https://github.com/Aider-AI/aider.git
synced 2025-06-06 04:35:00 +00:00
refactor: Simplify exception handling and remove redundant validation in LiteLLMExceptions
This commit is contained in:
parent
b9e15a1340
commit
46058c275c
2 changed files with 6 additions and 3 deletions
|
@ -65,9 +65,10 @@ class LiteLLMExceptions:
|
|||
if var not in self.exception_info:
|
||||
raise ValueError(f"{var} is in litellm but not in aider's exceptions list")
|
||||
|
||||
ex = getattr(litellm, var)
|
||||
dump(var, ex)
|
||||
self.exceptions[ex] = self.exception_info[var]
|
||||
for var in self.exception_info:
|
||||
ex = getattr(litellm, var)
|
||||
dump(var, ex)
|
||||
self.exceptions[ex] = self.exception_info[var]
|
||||
|
||||
def exceptions_tuple(self):
|
||||
return tuple(self.exceptions)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue