I pushed my faulthandler module into the default branch (Python 3.3).
Since one week, I fixed a lot of bugs (platform issues), improved the
tests and Antoine wrote a new implementation of dump_backtraces_later()
using a thread (instead of SIGALRM+alarm()). It should now work on all
platforms (but register() is not available on Windows).
Use "python -X faulthandler" or "PYTHONFAULTHANDLER=1 python" to install
the fault handler at startup (catch segfaults and other fatal errors).
You can also register a signal (e.g. SIGUSR1) to dump the traceback on
The latest added feature is to be able to the dump the traceback after a
timeout and exit the process: we may use it on regrtest.py to learn more
about test_multiprocess and test_threadsignals hangs. Issue #11393 has a
patch implementing this issue: add --timeout option to regrtest.py. You
can also just dump the traceback after the timeout without exiting.
Py_FatalError() always print the Python traceback (except if an
exception was raised: print the exception with its traceback).
For more information, read the doc:
Please tell me if you have any issue related to faulthandler.
If you get "undefined reference to `_PyFaulthandler_Init'" compiler
error, copy Modules/Setup.dist to Modules/Setup (cp Modules/Setup.dist
test_faulthandler hangs on AMD64 Gentoo Wide 3.x and AMD64 OpenIndiana
3.x. It looks to be related to the stack overflow test (the stack is
maybe not limited on these buildbots?). I have a patch, but I cannot
test it because these buildbots are dead (oops, sorry!).
Most buildbots are red because a regression in test_logging (since 2
days): I disabled temporary the test (issue #11557), I hope that the
situation will be better in a few hours.
Thank you Antoine for your reviews!
On Tue, 29 Mar 2011 21:00:22 +0200
ezio.melotti <python-checkins(a)python.org> wrote:
> changeset: 405:f722956afeac
> user: Ezio Melotti
> date: Tue Mar 29 22:00:13 2011 +0300
> Add a table of contents to the FAQ.
Could it be collapsed by default? It's quite long, and redundant with
>> There's a space missing here, and the link doesn't work.
> It does for me. This may depend on the mail reader and whether it parses
> the url out in spite of the missing space.
Victor was talking about the rendered HTML, not his email client. :)