Feb. 7, 2020
11:58 a.m.
On Sat, Feb 8, 2020 at 4:51 AM Shai Berger <shai@platonix.com> wrote:
To summarize, I am suggesting that
except ExceptionType: raise as OtherException(...)
Have, more-or-less, the semantics of Python 2's:
except ExceptionType: traceback = sys.exc_info()[2] raise OtherException, OtherException(...), traceback
-1. That would mean that a line of code could phantom-raise an exception that it has no idea even exists. I'd much rather it be defined with semantics based on existing exception chaining (which is what Ram's original proposal was). ChrisA