ENH: future-proof changing signature in format() and format_exception_only() #133
Closed
1 task done
Labels
enhancement
New feature or request
Things to check first
Feature description
Currently,
PatchedTracebackException
overrides the stdlibTracebackException
implementation offormat
andformat_exception_only
. With the new pyrepl coming in python3.13, the signatures of those methods changes: they get an additional kwargcolorize
. In PyPy we would like to backport that pure-python pyrepl to our python3.10 implementation, but then the overrides' signatures are wrong. Adding**kwargs
would future-proof the overrides, at the cost of loosing the nice colorization of tracebacks.Use case
This came up in pypy/pypy#5004, where pytest collection suddenly started failing. There may be other cases for using exceptiongroups on Python implementations and versions that change the signatures of the overriden functions.
The text was updated successfully, but these errors were encountered: