Feature Request: Reposition Execution

Marko Rauhamaa marko at pacujo.net
Mon May 11 08:02:46 EDT 2015


Dave Angel <davea at davea.name>:

> On 05/11/2015 07:46 AM, Skybuck Flying wrote:
>> Hello,
>>
>> Sometimes it can be handy to "interrupt/reset/reposition" a running script.
>> For example something externally goes badly wrong.
>
> os.kill()
>
> then in your process, handle the exception, and do whatever you think
> is worthwhile.

One thing that gives me trouble quite often is that Ctrl-C doesn't kill
a multithreaded Python program. Instead, you need to do:

   Ctrl-Z
   [1]+  Stopped
   kill %1


Marko



More information about the Python-list mailing list