Killing a subprocess including its children from python
- by user316664
Hi,
I'm using the subprocess module on python 2.5 to spawn a java program (the selenium server, to be precise) as follows:
import os
import subprocess
display = 0
log_file_path = "/tmp/selenium_log.txt"
selenium_port = 4455
selenium_folder_path = "/wherever/selenium/lies"
env = os.environ
env["DISPLAY"] = ":%d.0" % display
command = ["java",
…