<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Mike Driscoll wrote:
<blockquote
 cite="mid:86a0b31e-de71-4820-a37f-3c0fa26b768f@i72g2000hsd.googlegroups.com"
 type="cite">
  <pre wrap="">On Jan 14, 9:02 pm, Astan Chee <a class="moz-txt-link-rfc2396E" href="mailto:st...@al.com.au"><st...@al.com.au></a> wrote:
  </pre>
  <blockquote type="cite">
    <pre wrap="">Hi,
I have a python module that keeps on crashing with various windows
errors (not BSOD but the less lethal windows XP popup ones). Now these
are intentional and rather sporadic so I cant really solve it by
attempting to fix the crash; rather what Im trying to do is make another
module outside it that restarts this module every time it crashes. Is
this possible? 
    </pre>
  </blockquote>
  <pre wrap=""><!---->
If you're not going to catch the error that is causing the crash, then
I think your only option is to restart your application with an
external program. 
  </pre>
</blockquote>
My understanding of using an external application to do this is to
first create my module as an executable using py2exe. Then I have
another python script that runs this module like this<br>
<br>
while (1):<br>
    os.popen("program_module.exe")<br>
<br>
and make this other python script into another executable and execute
this one. If Im not mistaken, when the python program crashes, the
thread is killed. is this correct or how should I do it?<br>
Thanks again.<br>
Astan<br>
</body>
</html>