Skip to content

Commit

Permalink
fix: Catch and surface BaseException()
Browse files Browse the repository at this point in the history
Currently, the behavior of the library is to catch Exception() when encountered in the user provided callback, surface it to the calling code and shut down the client.

However, for BaseException() encountered in the user provided callback, the BaseException() is not surfaced to the calling code and the client is not shut down.

Make the behavior of the client when BaseException() is encountered consistent with the behavior of the client when Exception() is encountered.
  • Loading branch information
mukund-ananthu committed Mar 5, 2024
1 parent cdb94a8 commit 75bdc75
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -124,7 +124,7 @@ def _wrap_callback_errors(
"""
try:
callback(message)
except Exception as exc:
except BaseException as exc:
# Note: the likelihood of this failing is extremely low. This just adds
# a message to a queue, so if this doesn't work the world is in an
# unrecoverable state and this thread should just bail.
Expand Down

0 comments on commit 75bdc75

Please sign in to comment.