title: How do I run multiple subprocesses in parallel and wait for them to finish in Python
body: <p>I am trying to migrate a bash script to Python.</p>
  <p>The bash script runs multiple OS commands in parallel then waits for them to finish before resuming, ie:</p>
  <blockquote>
  <p>command1 &amp;</p>
  <p>command2 &amp;</p>
  <p>.</p>
  <p>commandn &amp;</p>
  <p>wait</p>
  <p>command</p>
  </blockquote>
  <p>I want to achieve the same using Python subprocess. Is this possible? How can I wait for a subprocess.call command to finish before resuming?</p>