Prev: throw

traceback

traceback()
This function, which you should only call inside an eror handler for a catch statement (see Error-Handling Statements), returns the traceback for the error which triggered the error handler. If you are not in an error handler, this function throws an ~error error.