[issue26389] Expand traceback module API to accept just an exception as an argument
Brett Cannon
report at bugs.python.org
Wed Apr 10 15:33:27 EDT 2019
Brett Cannon <brett at python.org> added the comment:
Boy, having a postional-only parameter in that first position would have been handy when we created this API (as Matthias pointed out). :)
The 'exec' keyword-only parameter is obviously the safest option here.
Making the first parameter positional-only and then making the other parameters optional would lead to the most fluid API long-term as people I suspect would much rather just pass in an object than always specifying the keyword-only parameter every time going forward. I also doubt anyone is specifying etype by name.
So my vote is:
+1 to a positional-only first parameter
+0 to 'exc' keyword-only parameter
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue26389>
_______________________________________
More information about the Python-bugs-list
mailing list