Steve Dower <steve.do...@python.org> added the comment:

> How about making the py[w].exe launcher unset __PYVENV_LAUNCHER__ whenever it 
> runs a registered version explicitly?

I think this is a good idea, though it can be unset unconditionally. If we're 
in a virtual environment, then it will run the intermediate process which will 
set the variable again (this is unavoidable unless we include specialized 
knowledge in the launcher to find the base python.exe from the pyvenv.cfg, 
which I'd rather not duplicate in so many places, when you consider that the 
script launcher will need it too).

As for updating the script launchers, on one hand I'd love to have them, but on 
the other it's more for us to maintain and there's definitely been benefit from 
it being backported for us. As long as they run the correct python.exe, I think 
it's fine.

I think that CreateProcess oddity where it searches the current process's 
directory first is going to catch people out regardless (I'm surprised it 
hasn't come up before), but I guess most people play it safe and use full paths.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue35797>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to