bufsize must be an integer in subprocess.Popen

INADA Naoki songofacandy at gmail.com
Mon Feb 23 07:33:19 EST 2015


> Hi, the parameter list should be a list of strings, not several unpacked
> strings :
>
>     command = ["/root/Desktop/abc.py","64","abc"]
>     proc1 = subprocess.Popen(command, shell=True, stdout=subprocess.PIPE,
> stderr=subprocess.PIPE)
>

The first argument is list of string only when `shell=False` (default).
When `shell=True`, you should one string as the argument.

-- 
INADA Naoki  <songofacandy at gmail.com>



More information about the Python-list mailing list