Created
March 5, 2020 14:39
-
-
Save tldrafael/1f6346e39fbdc1df18431a691e588cd9 to your computer and use it in GitHub Desktop.
Example to get traceback info
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import traceback | |
import sys | |
try: | |
pass | |
except Exception as e: | |
traceback_info = ''.join(traceback.format_exception(*sys.exc_info())) | |
logger.info(traceback_info) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment