PyDocs

Nav

Python Runtime Services

exception

sys

function · Added in 3.11
  • exception()
Return the current exception.

Return the most recent exception caught by an except clause
in the current stack frame or in an older stack frame, or None
if no such exception exists.
0 Examples
No examples for sys/exception.
See Also
No see-alsos for sys/exception
0 Notes
No notes for exception