Swallowing a BaseException is not allowed.#731
Swallowing a BaseException is not allowed.#731smurfix wants to merge 1 commit intopytransitions:masterfrom
Conversation
|
Hello @smurfix,
is there a PEP or something where I can look this up? |
|
There doesn't seem a PEP-or-whatever documenting this, unfortunately. https://docs.python.org/3/tutorial/errors.html states
There are a couple of I'm not saying not to call the exception handler, which is what #619 wants us to. My patch specifically does call the handler. It just always propagates the exception instead of eating it, after doing so. |
|
Hi @smurfix,
got it. I absolutely see why 'handling' all exceptions causes unwanted behaviour (
looking forward to feedback |
Python basically forbids swallowing a
BaseExceptionthat's not anException.(You do not want a
KeyboardInterruptor aSystemExitto not terminate the program.)Also, using asyncio, you must always propagate a cancellation.