[issue14440] Close background process if IDLE closes abnormally.

Andrew Svetlov report at bugs.python.org
Sat Mar 31 22:02:13 CEST 2012


Andrew Svetlov <andrew.svetlov at gmail.com> added the comment:

Terry, sorry.

That's definitely posix-specific bug. I'll make a patch assuming Windows works well with killing IDLE.

To be polite I'll describe used signal names shortly.

SIGKILL, SIGTERM, SIGINT and SIGQUIT are used to stop process.
— SIGKILL is mimic to Windows TerminateProcess in some way. 
  It cannot be overloaded by target process and unconditionally terminates one.
— SIGTERM is default signal for kill utility. Used to stop process by some program.
— SIGINT sent if user press Ctrl+C in terminal. 
  Overridden very often.
  Python does it itself to translate this signal to KeyboardInterrupt exception.
— SIGQUIT bound to Ctrl+\ and used to stop program with memory dump. 
  The standard way to process it 
  (if need to, the most programs leaves that handler untouched) is: 
  close used resources and maybe write to stderr/logs some message. 
  Usually SIGQUIT sent to hang program to stop execution 
  if Ctrl+C doesn't help but potentially dangerous SIGKILL is not desirably 
  by risk of lacking important data or locking kernel objects.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue14440>
_______________________________________


More information about the Python-bugs-list mailing list