Exception notes are already implemented for older Pythons with T416566 but these should only be printed when an Exception is raised and not be given with str(). The idea is to patch the sys.excepthook accordingly for older Pythons like:
original_excepthook = sys.excepthook
def excepthook_with_notes(exc_type, exc_value, exc_traceback):
# normal traceback
original_excepthook(exc_type, exc_value, exc_traceback)
# notes
notes = getattr(exc_value, '__notes__', [])
for note in notes:
print(note)
sys.excepthook = excepthook_with_notes