[issue15451] PATH is not honored in subprocess.Popen in win32

2017-02-04 Thread Eryk Sun
Eryk Sun added the comment: Sure, let's close this in favor of the older documentation issue 8557. -- resolution: -> duplicate stage: needs patch -> resolved status: open -> closed superseder: -> subprocess PATH semantics and portability ___ Python

[issue15451] PATH is not honored in subprocess.Popen in win32

2017-02-04 Thread Martin Panter
Martin Panter added the comment: Perhaps this is a duplicate of Issue 8557 -- nosy: +martin.panter ___ Python tracker ___

[issue15451] PATH is not honored in subprocess.Popen in win32

2017-02-03 Thread Eryk Sun
Eryk Sun added the comment: > difference from the behaviour of Posix's execvpe() was deliberate POSIX doesn't define execvpe [1]. GNU glibc implemented it in 2009 [2]. On Windows, MSC has had execvpe and spawnvpe since at least 5.0 [3], and I think it arrived in 4.0 in 1986. Guido added

[issue15451] PATH is not honored in subprocess.Popen in win32

2017-02-03 Thread Anthony Scopatz
Changes by Anthony Scopatz : -- nosy: +Anthony Scopatz versions: +Python 3.6 ___ Python tracker ___

[issue15451] PATH is not honored in subprocess.Popen in win32

2014-09-03 Thread Geoffrey Bache
Changes by Geoffrey Bache gjb1...@users.sourceforge.net: -- nosy: +gjb1002 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15451 ___ ___

[issue15451] PATH is not honored in subprocess.Popen in win32

2014-09-03 Thread Terry J. Reedy
Changes by Terry J. Reedy tjre...@udel.edu: -- versions: +Python 3.4, Python 3.5 -Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15451 ___

[issue15451] PATH is not honored in subprocess.Popen in win32

2012-07-29 Thread Richard Oudkerk
Richard Oudkerk added the comment: But I observe that the same script(with proper modification of file names) works very well under Linux. After I dive into the source code, I found Python use execvpe to invoke the child process which _will_ use the PATH variable to search the executable.

[issue15451] PATH is not honored in subprocess.Popen in win32

2012-07-29 Thread Terry J. Reedy
Terry J. Reedy added the comment: What I understand you two as saying is that there seems to be an undocumented difference in execxxe between unix and windows which has been carried over to subprocess. In particular, for both, the PATH component of the env parameter is used to search for the

[issue15451] PATH is not honored in subprocess.Popen in win32

2012-07-29 Thread Richard Oudkerk
Richard Oudkerk added the comment: What I understand you two as saying is that there seems to be an undocumented difference in execxxe between unix and windows which has been carried over to subprocess. No. There is no difference between the platforms in the behaviour of os.execvpe().

[issue15451] PATH is not honored in subprocess.Popen in win32

2012-07-28 Thread Grissiom Gu
Grissiom Gu added the comment: Thank you for everyone participated in this issue. I learnt a lot from you. But I observe that the same script(with proper modification of file names) works very well under Linux. After I dive into the source code, I found Python use execvpe to invoke the child

[issue15451] PATH is not honored in subprocess.Popen in win32

2012-07-27 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: Richard is correct. From 17.1.1.2. Popen Constructor If env is not None, it must be a mapping that defines the environment variables for the new process; these are used instead of inheriting the current process’ environment, which is the

[issue15451] PATH is not honored in subprocess.Popen in win32

2012-07-26 Thread Chris Rebert
Changes by Chris Rebert pyb...@rebertia.com: -- nosy: +cvrebert ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15451 ___ ___ Python-bugs-list

[issue15451] PATH is not honored in subprocess.Popen in win32

2012-07-26 Thread Richard Oudkerk
Richard Oudkerk shibt...@gmail.com added the comment: I think env is used for specifying the environment used by the child process once it has started. env['PATH'] is not used by the parent process to find program to run. Having said that, maybe if you used shell=True as well then the shell

[issue15451] PATH is not honored in subprocess.Popen in win32

2012-07-25 Thread Grissiom Gu
New submission from Grissiom Gu chaos.pro...@gmail.com: My system is 32 bit win7 and python is 2.7.2. Sample code is here: === import os, sys nenv = {} nenv['PATH'] = 'C:\\Windows\\System32\\;e:\\projects\\teest\\python\\exe\\' nenv['SystemRoot'] = 'C:\\Windows\\'