Skip to content

Instantly share code, notes, and snippets.

@SenpaiSilver
Created August 11, 2017 04:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save SenpaiSilver/eaacbc751396fe532c72337bde57c1c1 to your computer and use it in GitHub Desktop.
Save SenpaiSilver/eaacbc751396fe532c72337bde57c1c1 to your computer and use it in GitHub Desktop.
>>> import sys, traceback
>>> raise Exception("Hello World!")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
Exception: Hello World!
>>> traceback.print_tb(sys.last_traceback)
File "<stdin>", line 1, in <module>
>>> traceback.print_last()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
Exception: Hello World!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment