[PyQt] Automatic Crash Reporting
me at the-compiler.org
Thu Sep 25 05:41:57 BST 2014
* Timothy W. Grove <tim_grove at sil.org> [2014-09-25 04:15:53 +0100]:
> Can anyone recommend a good automatic crash reporting module that would work
> nicely with a python3/pyqt4 application? Thanks.
What are you looking for exactly? Some full-fledged (likely
commercial) solution  or just some simple error report dialog?
I've done the latter in my own project with much success. However it's
coupled to some other stuff in the project so I can't really give you
a ready solution, but feel free to rip out what you can need.
- It uses PyQt to display an error dialog with all the logs and a
restart button: 
- It calls that dialog from sys.excepthook: 
- It uses the logging module to log all log calls (debug loglevel) to
the RAM and shows that log then: 
- It also integrates Qt warnings and Python warnings in the same log.
- It uses the faulthandler module to write a crash dump on segfaults
and then displays the report window on the next start: 
- Some other useful information is gathered (version information, OS
information, their configfile, commandline arguments, list of Qt
- When the user clicks "Report", the full crash log is automatically
sent to my pastebin via urllib: 
An example crashdump is at . It's been some effort to set this up,
but it has proven to be incredibely helpful for debugging issues.
 Some I've just found, with no idea how good they all are:
http://www.the-compiler.org | me at the-compiler.org (Mail/XMPP)
GPG 0xFD55A072 | http://the-compiler.org/pubkey.asc
I love long mails! | http://email.is-not-s.ms/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 819 bytes
Desc: not available
More information about the PyQt