title: Can subprocess.Popen be used when called from py code running under mod_wsgi in Apache2
body: <p>I'm using subprocess.Popen and getting IOErrors when running under mod_wsgi.  The following code will work in a python term, or a django runserver, and under mod_python.  If you put it under mod_wsgi (v2), it fails:  (2, 'No such file or directory')  I have tried many variations involving using subprocess.PIPE.  I have tried to redefine stdout, and to use the httpd directives to turn off mod_wsgi's complains of stdout usage.  I recently tried upgrading to version 3.  </p>
  
  <pre><code>import subprocess
  
  input_file = 'test.html'
  
  p = subprocess.Popen(['htmldoc','-f', 'output.pdf', '--book', input_file])
  
  p.communicate()
  
  len(open('output.pdf').read())
  </code></pre>
  
  <p>My test effort is going to be to move back to mod_python, and see if the problem goes away.  I'd like to know if anyone else has done this and can shed some light on this problem.</p>