I\'m launching a number of subprocesses with subprocess.Popen in Python. I\'d like to check whether one such process has completed. I\'ve found two ways of checking the stat
Ouestion: ... a way to check if a process is still running ...
You can do it for instance:
p = subprocess.Popen(...
"""
A None value indicates that the process hasn't terminated yet.
"""
poll = p.poll()
if poll == None:
# p.subprocess is alive
Python » 3.6.1 Documentation popen-objects
Tested with Python:3.4.2