Can't get python running
eryk sun
eryksun at gmail.com
Mon Jan 22 03:11:19 EST 2018
On Sun, Jan 21, 2018 at 10:57 AM, Paul Moore <p.f.moore at gmail.com> wrote:
>
> The "py" launcher is always added to PATH. It's installed by default
> (and always has been I believe) although there is a checkbox you can
> untick if you don't want to install it.
Yes, we can choose to not install the launcher. However, if we select
to install it, it seems we don't get to choose the install path or
whether it's added to PATH. When installed for the current user, the
launcher installs in "%LocalAppData%\Python\Launcher". This directory
is added to PATH even if we don't select "add Python to environment
variables". When installed for all users it goes in "%SystemRoot%",
which is already in the default system PATH and also implicitly
searched by WinAPI CreateProcess even if PATH isn't defined. The
launcher's primary purpose is to handle the .py[w] file association
and support shebangs in scripts, and to that end it does not have to
be in PATH. But it has also become a convenient way to manage multiple
Python installations from the command line, especially for `py
-X[.Y[-32]] -m pip` and (for 3.5+) `py -X[.Y[-32]] -m venv`
As to installing Windows applications in the root of the system drive,
that's fine for a single-user or personal system, if it's what you
prefer. The default DACL of the system drive's root directory allows
authenticated users to create directories that all authenticated users
have the right to modify. This is too permissive in general, so
starting with 3.5 the installer stopped using C:\PythonXY as the
default target. Now, all-users installs default to
"%ProgramFiles%\PythonXY" or "%ProgramFiles(x86)%\PythonXY-32", and
current-user installs default to
"%LocalAppData%\Programs\Python\PythonXY[-32]". %LocalAppData% expands
to "%UserProfile%\AppData\Local". By default, a user's profile
directory is accessible only to the user, administrators, and SYSTEM.
More information about the Python-list
mailing list