Output from subprocess.Popen()

Clodoaldo Pinto Neto clodoaldo.pinto at gmail.com
Tue Oct 17 07:02:21 EDT 2006


Fredrik Lundh wrote:
> Clodoaldo Pinto Neto wrote:
>
> > But I still don't understand what is happening. The manual says that
> > when shell=True the executable argument specifies which shell to use:
>
> no, it says that when shell=True, it runs the command "through" the
> default shell.  that is, it hands it over to the shell for execution,
> pretty much as if you'd typed it in yourself.

"If shell=True, the executable argument specifies which shell to use."

Taken from 6.8.1 v2.4:

"The executable argument specifies the program to execute. It is very
seldom needed: Usually, the program to execute is defined by the args
argument. If shell=True, the executable argument specifies which shell
to use. On Unix, the default shell is /bin/sh. On Windows, the default
shell is specified by the COMSPEC environment variable."




More information about the Python-list mailing list