You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think this behaviour is very surprising as the general behaviour of exceptions based on BaseException is that they propagate over error handling. Currently, we'd need to do something hacky like inherit from SystemExit instead, basically relegating BaseException to something internal.
This issue was mentioned in the PR, and supposed to be adjusted for Python 3.9:
Bug report
Checklist
and am confident this bug has not been reported before
CPython versions tested on:
3.11
Operating systems tested on:
Linux
Output from running 'python -VV' on the command line:
Python 3.11.4 (main, Jun 7 2023, 00:00:00) [GCC 13.1.1 20230511 (Red Hat 13.1.1-2)]
A clear and concise description of the bug:
Since bpo-32528, this code no longer works:
I think this behaviour is very surprising as the general behaviour of exceptions based on
BaseExceptionis that they propagate over error handling. Currently, we'd need to do something hacky like inherit fromSystemExitinstead, basically relegatingBaseExceptionto something internal.This issue was mentioned in the PR, and supposed to be adjusted for Python 3.9:
#13528 (review)
Unfortunately, it seems that was forgotten.