feat: optimize invoke errors (#1922)

This commit is contained in:
takatost 2024-01-04 17:49:55 +08:00 committed by GitHub
commit b88a8f7bb1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
15 changed files with 29 additions and 29 deletions

View file

@ -58,7 +58,7 @@ class ChatMessageAudioApi(Resource):
except ModelCurrentlyNotSupportError:
raise ProviderModelCurrentlyNotSupportError()
except InvokeError as e:
raise CompletionRequestError(str(e))
raise CompletionRequestError(e.description)
except ValueError as e:
raise e
except Exception as e: