Is there a way to check if a subprocess is still running?

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 is None:
  # p.subprocess is alive

Python ยป 3.6.1 Documentation popen-objects

Tested with Python:3.4.2

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)