[issue9265] Can't choose other shell in subprocess

2010-07-15 Thread Stefan Krah
Stefan Krah added the comment: Isn't just the name of the executable wrong? /bin/bash is executed all right, but the name is set to "/bin/sh". Index: Lib/subprocess.py === --- Lib/subprocess.py (revision 82816) +++ Lib/subproce

[issue9265] Can't choose other shell in subprocess

2010-07-15 Thread R. David Murray
R. David Murray added the comment: >From looking at the code, it appears that what happens currently is that >executable is used to run /bin/sh when shell=True. So I'm pretty sure there >is a bug here. What isn't clear is whether or not fixing this bug will cause >currently working code to

[issue9265] Can't choose other shell in subprocess

2010-07-15 Thread Éric Araujo
Éric Araujo added the comment: The SHELL variable is not to be trusted, since e.g. dash (my system’s /bin/sh) in a bash will have SHELL=bash. I tested this command: "help set >/dev/null && echo ok". Bash prints ok but dash gives an error. This test worked for versions 2.4 up to 3.2. Narnie,

[issue9265] Can't choose other shell in subprocess

2010-07-15 Thread Eric Smith
Changes by Eric Smith : -- nosy: +eric.smith ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue9265] Can't choose other shell in subprocess

2010-07-15 Thread Stefan Krah
Stefan Krah added the comment: I think this is invalid. Please run: >>> from subprocess import Popen >>> Popen("echo $SHELL", executable="/bin/bash", shell=True) /bin/bash >>> -- nosy: +skrah ___ Python tracker _

[issue9265] Can't choose other shell in subprocess

2010-07-15 Thread Éric Araujo
Éric Araujo added the comment: Thank you for the report. The docs indeed say “If shell=True, the executable argument specifies which shell to use”. Could you provide your change as a diff file following the guidelines on http://www.python.org/dev/patches/ ? Diffs are easier to review than who

[issue9265] Can't choose other shell in subprocess module. Includes fix.

2010-07-14 Thread Narnie Harshoe
Changes by Narnie Harshoe : -- title: Can choose other shell in subprocess module. Includes fix. -> Can't choose other shell in subprocess module. Includes fix. ___ Python tracker __