Message262252
faulthandler was enhanced in Python 3.6:
* Issue #26563: faulthandler now works in non-Python threads.
* Issue #26154: Issue #26154: Add a new private _PyThreadState_UncheckedGet() function which gets the current thread state, but don't call Py_FatalError() if it is NULL.
Can you please try Python 3.6 (default branch of Mercurial) with your use case to check if the issue is solved? And also Python 3.5 (3.5 branch of Mercurial)?
I can try to backport some enhancements from Python 3.6 to Python 3.5 if needed.
If it's ok for you, I will then port changes to the GitHub project.
Note: I also add new unit tests.
> SIGUSR1/2 will get delivered to any running thread. The current thread of the signal doesn't give any useful information. Try to get the current Python thread which holds the GIL instead, or use NULL.
I don't understand your usecase, since faulthandler displays *all* Python threads by default.
all_threads=True in faulthandler.register(signum, file=sys.stderr, all_threads=True, chain=False):
https://docs.python.org/dev/library/faulthandler.html#faulthandler.register |
|
Date |
User |
Action |
Args |
2016-03-23 09:23:15 | vstinner | set | recipients:
+ vstinner, Albert.Zeyer |
2016-03-23 09:23:14 | vstinner | set | messageid: <1458724994.98.0.573250172974.issue23886@psf.upfronthosting.co.za> |
2016-03-23 09:23:14 | vstinner | link | issue23886 messages |
2016-03-23 09:23:14 | vstinner | create | |
|