Frage

I have been very happy with using the pyinstaller to make windows programs (.exe files]. But I find the debugging phase very time consuming.

I would like to pyinstaller to compile the python code so it will display the error if it crashes.

So far I have made a try and except

try:
    # My code goes here
except Exception as e:
    print "ERROR:"
    print type(e)     # the exception instance
    print e.args

But it is not giving me the full crash log.

War es hilfreich?

Lösung

Try traceback module, especially print_... functions. Also, try catching BaseExceptions, all exceptions are derived from it, and some aren't derived from Exception.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top