chore(lint): cleanup repeated cause exception in logging.exception replaced by helpful message (#10425)

This commit is contained in:
Bowen Liang 2024-11-15 15:41:40 +08:00 committed by GitHub
commit 51db59622c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
47 changed files with 83 additions and 72 deletions

View file

@ -70,7 +70,7 @@ class ChatMessageAudioApi(Resource):
except ValueError as e:
raise e
except Exception as e:
logging.exception(f"internal server error, {str(e)}.")
logging.exception("Failed to handle post request to ChatMessageAudioApi")
raise InternalServerError()
@ -128,7 +128,7 @@ class ChatMessageTextApi(Resource):
except ValueError as e:
raise e
except Exception as e:
logging.exception(f"internal server error, {str(e)}.")
logging.exception("Failed to handle post request to ChatMessageTextApi")
raise InternalServerError()
@ -170,7 +170,7 @@ class TextModesApi(Resource):
except ValueError as e:
raise e
except Exception as e:
logging.exception(f"internal server error, {str(e)}.")
logging.exception("Failed to handle get request to TextModesApi")
raise InternalServerError()