[issue1215] Python hang when catching a segfault

2011-08-21 Thread Martin Pool
Martin Pool m...@sourcefrog.net added the comment: The documentation for this can now point to the faulthandler module (in Python 3). -- nosy: +poolie ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1215

[issue1215] Python hang when catching a segfault

2011-01-31 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: The consensus is that this is not a crash (and not even a bug). I am not sure what is the proper type for doc enhancement, but is certainly should not show up in a search for crashers. -- components:

[issue1215] Python hang when catching a segfault

2010-09-18 Thread Mark Lawrence
Mark Lawrence breamore...@yahoo.co.uk added the comment: There are several suggestions inline as how how the docs should be changed. -- assignee: - d...@python nosy: +BreamoreBoy, d...@python ___ Python tracker rep...@bugs.python.org

[issue1215] Python hang when catching a segfault

2010-06-16 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: From the comments, it seems like this should be changed to a doc issue. Given that I do not know a 'synchronous' from an 'asynchronous' signal, I would want an expanded list if I were using this module. Strengthening 'little sense' to 'do not

[issue1215] Python hang when catching a segfault

2008-12-05 Thread Georg Brandl
Georg Brandl [EMAIL PROTECTED] added the comment: The docs already say Because the C signal handler always returns, it makes little sense to catch synchronous errors like :const:`SIGFPE` or :const:`SIGSEGV`. Should this still be reworded or promoted to a warning? -- nosy:

[issue1215] Python hang when catching a segfault

2008-12-05 Thread Adam Olsen
Adam Olsen [EMAIL PROTECTED] added the comment: I'm in favour of just the doc change now. It's less work and we don't really need to disable that usage. ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue1215

[issue1215] Python hang when catching a segfault

2008-01-20 Thread Christian Heimes
Changes by Christian Heimes: -- components: +Documentation keywords: +easy priority: - normal __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1215 __ ___

[issue1215] Python hang when catching a segfault

2008-01-14 Thread Guido van Rossum
Guido van Rossum added the comment: I'm not sure what the point of that would be. Somebody might want to send these asynchronously (using kill) which we might legitimately want to catch. Also you don't know which other synchronous signals a platform might define. I think at best a doc update

[issue1215] Python hang when catching a segfault

2008-01-14 Thread Ralf Schmitt
Ralf Schmitt added the comment: Those who want to legitimately catch SIGSEGV will end up with an uninterruptible python process using 100 % CPU on a real segmentation fault. But, then I can live with the current behaviour. __ Tracker [EMAIL PROTECTED]

[issue1215] Python hang when catching a segfault

2008-01-14 Thread Adam Olsen
Adam Olsen added the comment: In essence, it's a weakness of the POSIX API that it doesn't distinguish synchronous from asynchronous signals. The consequences of either approach seem minor though. I cannot imagine a sane use case for catching SIGSEGV, but documentation changes should be

[issue1215] Python hang when catching a segfault

2008-01-14 Thread Ralf Schmitt
Ralf Schmitt added the comment: Should I work on a patch, which makes signal.signal raise an Exception for SIGSEGV, SIGBUS, SIGFPE,...? __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1215 __

[issue1215] Python hang when catching a segfault

2008-01-12 Thread Ralf Schmitt
Ralf Schmitt added the comment: If you replace your call segfault.segfault() with os.kill(os.getpid(), signal.SIGSEGV) everything works as expected. The problem is that the signal is just caught in the c handler (and a flag is set) and then the program continues with the offending *c = 'a';

[issue1215] Python hang when catching a segfault

2008-01-12 Thread Adam Olsen
Adam Olsen added the comment: The warning in the documentation should be strengthened. Python simply does not and cannot support synchronously-generated signals. It is possible to send a normally synchronous signal asynchronously, such as the os.kill() Ralf mentioned, so it's theoretically

[issue1215] Python hang when catching a segfault

2007-09-28 Thread Guido van Rossum
Guido van Rossum added the comment: Why is this a Python bug? -- nosy: +gvanrossum __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1215 __ ___ Python-bugs-list mailing

[issue1215] Python hang when catching a segfault

2007-09-28 Thread Miki Tebeka
Miki Tebeka added the comment: Because it hangs Python :) I know, while 1: pass also hangs Python, however it'll nice if this behaviour was documented or (IMO better) that Python will raise an InvalidArgument exception on SIGSEGV (like it does for SIGKILL). __

[issue1215] Python hang when catching a segfault

2007-09-27 Thread Miki Tebeka
New submission from Miki Tebeka: The following code hangs Python: #!/usr/bin/env python import segfault import signal from os import _exit from sys import stdout def handler(signal, stackframe): print OUCH stdout.flush() _exit(1) if __name__ == __main__: from sys import argv