STINNER Victor <vstin...@python.org> added the comment:
For faulthandler.enable(), maybe we reset SIGSEGV signal handler to the default handler if __has_feature(address_sanitizer) is true: https://clang.llvm.org/docs/AddressSanitizer.html#conditional-compilation-with-has-feature-address-sanitizer But we cannot do that in faulthandler._sigsegv() since this function is used to test_faulthandler to check the signal handler installed by faulthandler previously. Maybe we should add a function to test.support which resets the signal handler and then trigger a crash. There are multiple functions which trigger crashes on purpose: * _testcapi.crash_no_current_thread() => Py_FatalError() * _testcapi.return_null_without_error() => Py_FatalError() * _testcapi.return_result_wit_error() => Py_FatalError() * _testcapi.negative_refcount() => Py_FatalError() * _testcapi.pymem_buffer_overflow() => Py_FatalError() * _testcapi.set_nomemory(0) is used to trigger a _PyErr_NormalizeException crash => Py_FatalError() * etc. Py_FatalError() calls abort() which raises SIGABRT signal, but ASAN doesn't catch this signal. More generally, search for support.SuppressCrashReport usage in tests. See also faulthandler_suppress_crash_report() C function. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue42985> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com