Skip to content

Commit f0185e3

Browse files
committed
Normalize exception
1 parent 3588252 commit f0185e3

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

Python/pythonrun.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1171,6 +1171,7 @@ get_exception_notes(struct exception_print_context *ctx, PyObject *value, PyObje
11711171
if (_PyObject_LookupAttr(value, &_Py_ID(__notes__), notes) < 0) {
11721172
PyObject *type, *errvalue, *tback;
11731173
PyErr_Fetch(&type, &errvalue, &tback);
1174+
PyErr_NormalizeException(&type, &errvalue, &tback);
11741175
note = PyUnicode_FromFormat("Ignored error getting __notes__: %R", errvalue);
11751176
Py_XDECREF(type);
11761177
Py_XDECREF(errvalue);

0 commit comments

Comments
 (0)