Steve Dower <steve.do...@python.org> added the comment:
Thanks for doing the PR, Paul. Honestly, I'd rather document in subprocess that Popen("python") is not a good idea, and should use either sys.executable or shutil.which depending on what you mean. This is a platform-independent gotcha, as it's very easy to reproduce the failure (e.g. run on Linux where "python"==Python 2.x). Describing the current state of how venv works in the venv docs is fine, and what you've got there is accurate (might be easier to follow on first reading if it leads with Python picking up the venv based on the launched executable, rather than anything in the terminal's environment). My concern is that we don't make this level of detail a documented guarantee, and can still change it between major versions without the deprecation period. I'm happy to guarantee intended uses, and it might be worth figuring out what those are (e.g. does double-clicking in Explorer matter? what about the Run window? Desktop shortcuts? With/without activation? etc.) and likely we'd have to clarify which ones don't work the same for the symlink vs. redirector options. IOW, if someone writes an actual spec (and we all agree on it), we can guarantee that. Without it, I'd rather implementation internals remain internal. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue42041> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com