From: Oleg Broytman Date: Thu, 21 Apr 2016 19:34:50 +0000 (+0300) Subject: init.py: add an example of using cgitb.enable X-Git-Url: https://git.phdru.name/?p=dotfiles.git;a=commitdiff_plain;h=b979a2004c12b0a5b4e61661322717e6c8556b8f init.py: add an example of using cgitb.enable --- diff --git a/lib/python/init.py b/lib/python/init.py index 7ef24db..1690a42 100644 --- a/lib/python/init.py +++ b/lib/python/init.py @@ -178,6 +178,14 @@ def init(): sys.excepthook = excepthook + #try: + # import cgitb + #except ImportError: + # pass + #else: + # # cgitb.enable() overrides sys.excepthook + # cgitb.enable(format='text') + # From Thomas Heller: # https://mail.python.org/pipermail/python-list/2001-April/099020.html