mirror of
https://github.com/zulip/zulip.git
synced 2025-11-15 11:22:04 +00:00
logging: Use logging.exception and exc_info for unexpected exceptions.
logging.exception() and logging.debug(exc_info=True), etc. automatically include a traceback. Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
committed by
Tim Abbott
parent
4b6d2cf25f
commit
1ed2d9b4a0
@@ -332,6 +332,6 @@ def do_rest_call(base_url: str,
|
||||
response_message = ("An exception of type *%s* occurred for message `%s`! "
|
||||
"See the Zulip server logs for more information." % (
|
||||
type(e).__name__, event["command"]))
|
||||
logging.exception(f"Outhook trigger failed:\n {e}")
|
||||
logging.exception("Outhook trigger failed:")
|
||||
fail_with_message(event, response_message)
|
||||
notify_bot_owner(event, exception=e)
|
||||
|
||||
Reference in New Issue
Block a user