I'm reading the writeup on the cgitb (extended traceback) module on the
PMOTW blog:

https://pymotw.com/3/cgitb/

To get a much longer & more informative traceback of an error, it is only
necessary to use

    import cgitb
    cgitb.enable(format='text')

at the start of execution. It occurs to me that the PyInstaller bootloader
could do this prior to invoking the main script. Then if the script fails,
there will be much more than the standard traceback, without any code
changes needed in the bundled script.

Obviously this should not be done normally, but it might be done when the
--debug flag is used. This would mean PyInstaller would have to make sure
to bundle the cgitb module if --debug is given, and the bootloader could do
the import and enable before starting the main script.

Does this sound like a good idea? If not, at least we should mention cgitb
in the "when things go wrong" section?

Dave Cortesi

-- 
You received this message because you are subscribed to the Google Groups 
"PyInstaller" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to pyinstaller+unsubscr...@googlegroups.com.
To post to this group, send email to pyinstaller@googlegroups.com.
Visit this group at https://groups.google.com/group/pyinstaller.
For more options, visit https://groups.google.com/d/optout.

Reply via email to