[New-bugs-announce] [issue13197] subprocess: move shell arguments to a separate keyword param

anatoly techtonik report at bugs.python.org
Mon Oct 17 13:41:11 CEST 2011


New submission from anatoly techtonik <techtonik at gmail.com>:

subprocess.Popen(args, shell=shell) is implicitly inconsistent on Unix:
 1. when shell=False, the args should be a list or you'll lose program options
 2. when shell=True, the args should be a string or your program options will be passed to shell itself


I propose to make consistent behaviour - require args to be a list, and pass shell options in a separate shell_args keyword argument. If it not for python4, then perhaps it can be implemented in PopenShell() and PopenSystem() functions.

This will also require unification of behaviour across platforms.

----------
components: Library (Lib)
messages: 145669
nosy: techtonik
priority: normal
severity: normal
status: open
title: subprocess: move shell arguments to a separate keyword param

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue13197>
_______________________________________


More information about the New-bugs-announce mailing list