jupyter / jupyter_console

Jupyter Terminal Console
http://jupyter-console.readthedocs.io/en/latest/
BSD 3-Clause "New" or "Revised" License
247 stars 146 forks source link

Display Exception notes #288

Open jbvsmo opened 1 year ago

jbvsmo commented 1 year ago

Similar to my other issue #287

Python3.11 added the concept of notes on exceptions that are displayed after the exception value, in new lines (one per message).

>>> ex = TypeError(10)
>>> ex.add_note('foo is bar')
>>> raise ex
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: 10
foo is bar

Latest console does not show notes yet. Ref PEP 678