subprocess.Popen - terminate

py codecraig at
Tue Nov 15 20:29:00 CET 2005

I am using subprocess.Popen to execute an executable, how can I
terminate that process when I want?

for example (on windows)

p = subprocess.Popen("calc.exe")

now say I want to kill calc.exe can I do it?  By the way, I am
not looking for a windows only solution I need something that is
universal (mac, *nix, etc)


More information about the Python-list mailing list