◐ Shell
clean mode source ↗

Message 68427 - Python tracker

Yet another question. There is a slight discrepancy between tracebacks
generated by the builtin-reporting and tracebacks generated by traceback.py.

With built-in reporting:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "f.py", line 22, in raise_cause
inner_raise_cause()
  File "f.py", line 13, in inner_raise_cause
raise KeyError from e
KeyError

With traceback.py:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "f.py", line 22, in raise_cause
    inner_raise_cause()
  File "f.py", line 13, in inner_raise_cause
    raise KeyError from e
KeyError

As you see, indentation of code lines is different. Should we harmonize
those behaviours?