[Tutor] popen2.Popen4 objects
klappnase
klappnase@freenet.de
Mon Aug 4 13:42:01 EDT 2003
Hello,
I hope that I do not bother all of you too much with my dumb newbie questions,
here I have yet another one.
I want to run a shell command using a popen2.Popen4 object.
I use the following line:
self.pp = popen2.Popen4(cmd)
Now I use self.pp.pid to capture the PID of the child process and self.pp.poll() to check whether the child process
has finished.
Seems to work all fine, however I found that after the child process has finished, the Popen4 instance
still persists:
>>>print self.pp
>>><popen2.Popen4 instance at 0x834d1fc>
I think it sould be removed somehow, but I don't know how to do that. I'd be very thankful for any help.
Michael
More information about the Tutor
mailing list