bpo-36829: PyErr_WriteUnraisable() normalizes exception (GH-13507)

PyErr_WriteUnraisable() now creates a traceback object if there is no
current traceback. Moreover, call PyErr_NormalizeException() and
PyException_SetTraceback() to normalize the exception value. Ignore
silently any error.
This commit is contained in:
Victor Stinner 2019-05-23 01:00:58 +02:00 committed by GitHub
parent 5edcf26358
commit df22c03b93
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 47 additions and 13 deletions

View file

@ -86,6 +86,10 @@ PyAPI_FUNC(void) _Py_DumpHexadecimal(
unsigned long value,
Py_ssize_t width);
PyAPI_FUNC(PyObject*) _PyTraceBack_FromFrame(
PyObject *tb_next,
struct _frame *frame);
#ifdef __cplusplus
}
#endif