docs.python.org/3/library/subprocess.html subprocess https://docs.python.org/3/library/subprocess.html subprocess.check_output() subprocess.Popen.returncode subprocess wait() subprocess.check_output() Python 3.x: subprocess docs.python.org/3/library/subprocess.html timeout is now supported run function from the subprocess module the subprocess docs subprocess subprocess.check_output() https://docs.python.org/3/library/subprocess.html subprocess.check_output() subprocess.check_output() subprocess.check_output() subprocess.check_output subprocess docs.python.org/3/library/subprocess.html docs.python.org/3/library/subprocess.html docs.python.org/3/library/subprocess.html subprocess.check_output() docs.python.org/3/library/subprocess.html