[issue30374] Make win_add2path.py take effect without having to log off

Paul Moore report at bugs.python.org
Mon May 15 16:42:40 EDT 2017


Paul Moore added the comment:

The reasons for not adding Python to PATH by default are complex. We've tried both ways and neither is 100% satisfactory.

The default install is a per-user install. If we added Python to PATH, then as a user setting it would come *after* the system part of PATH. If that includes python (for example, an older version of Python), then you think you have added Python to PATH but you still get the old version. We can't add the user python to the system PATH, as it may not be accessible to other users.

We don't make an all-users Python the default because users would then not be able to "pip install" modules without using an elevated prompt. So an all-users install should be left as a choice for a system admin who understands the implications.

Long story short, it's complicated and there's no really perfect solution.

The easiest answer is to say that you should be using the "py" launcher to start Python anyway. That *is* available in PATH and will pick up your default configured Python. With that, you don't need to add anything to PATH.

----------

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


More information about the Python-bugs-list mailing list