You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Python 3.12.3 installer fails to install py.exe #118347
I use Python with MkDocs and had needed to update my environment on a Windows 10 machine that only had Python 3.7. I installed version 3.12.3 since it is the latest stable at the time. I used all the default settings. Afterwards, I ran py --version and py --list and it does not show the latest installation. I thought I must have missed something so I uninstalled 3.12.3 and reinstalled, being careful that the box to install py.exe is checked. The installer does not ask for admin permissions. I can run 3.12.3 in its shell via the Start menu, but it is not known to py.exe and the C:\Winddows\py.exe executable file has a really old date. I then installed Python 3.9.2 because that is consistent with a Linux environment that I use on another machine. Installing with the default settings, the installer askes for admin permissions and py.exe shows the 3.9-64 version and has a newer date consistent with the installer. It seems to me that the 3.12.3 installer is not handling the py.exe installation correctly. I see some other issues related to the installer but not this specific issue, as far as I can tell.
My py.exe is 3.13.104.1013 dated 2.15.2024, when I installed 3.13.0a5. It was not replaced when I installed 3.13.0a6 and 3.12.3 3 weeks ago. I presume because it was not changed.
Clearly it's not detecting the existing install like it is supposed to, because you have a per-machine install which ought to be changing to also do a per-machine install instead of the admin-free default.
If you can, it would be helpful to see the log files created in %TEMP% when you did the installs. I assume the older versions won't be there anymore, but the latest ones should be.
@terryjreedy - the launcher is versioned independently from CPython, though the numbers happen to match. But it means that the one installed with 3.13 is "newer" than the one with 3.12 and won't be downgraded. It should have been upgraded for alpha 6 though, so that might be another issue. If you've got your log file still, that would be great to see.
For both of you, in this case, we only need the main log file (all the other ones have longer names than the main file). If you're unsure, a zip file with all the Python... log files you can find in %TEMP% is fine.
@zooba, Again, I am using Windows 10 on a machine that is kept up to date. I uninstalled 3.12.3 using "Add/Remove Programs" and removed all %TEMP% log files for that version, just to make sure that I have a clean set of files. I reran the installer and picked "Install Now" ("Use admin privileges when installing py.exe" is selected but "Add python.exe to PATH" is not). Again, it did NOT prompt for admin login and I got "Setup was successful". In a Windows command shell, I get the following (it lists 3.12 now but I don't think it did when going from 3.7 to 3.12, but I also have 3.9.2 installed now).
C:\Users\sam\AppData\Local\Temp>py --list
Installed Pythons found by py Launcher for Windows
-3.9-64 *
-3.7-32
-3.6-64
-3.12-64
C:\Users\sam\AppData\Local\Temp>py --version
Python 3.9.2
Okay, it looks like when we fixed installs breaking due to mixed launcher installs I changed the meanings of some variables without updating all the other users of them. Should be a straightforward fix.
In the meantime, if you want the launcher that comes with 3.12.3, you can get it from https://www.python.org/ftp/python/3.12.3/win32/launcher.msi and double-click to install it directly (or run msiexec /i launcher.msi ALLUSERS=1 for an all-users install, which you @smalers will need to do for your scenario).
Activity
terryjreedy commentedon Apr 27, 2024
My py.exe is 3.13.104.1013 dated 2.15.2024, when I installed 3.13.0a5. It was not replaced when I installed 3.13.0a6 and 3.12.3 3 weeks ago. I presume because it was not changed.
zooba commentedon Apr 28, 2024
Clearly it's not detecting the existing install like it is supposed to, because you have a per-machine install which ought to be changing to also do a per-machine install instead of the admin-free default.
If you can, it would be helpful to see the log files created in
%TEMP%when you did the installs. I assume the older versions won't be there anymore, but the latest ones should be.@terryjreedy - the launcher is versioned independently from CPython, though the numbers happen to match. But it means that the one installed with 3.13 is "newer" than the one with 3.12 and won't be downgraded. It should have been upgraded for alpha 6 though, so that might be another issue. If you've got your log file still, that would be great to see.
For both of you, in this case, we only need the main log file (all the other ones have longer names than the main file). If you're unsure, a zip file with all the
Python...log files you can find in%TEMP%is fine.smalers commentedon Apr 29, 2024
@zooba, Again, I am using Windows 10 on a machine that is kept up to date. I uninstalled 3.12.3 using "Add/Remove Programs" and removed all %TEMP% log files for that version, just to make sure that I have a clean set of files. I reran the installer and picked "Install Now" ("Use admin privileges when installing py.exe" is selected but "Add python.exe to PATH" is not). Again, it did NOT prompt for admin login and I got "Setup was successful". In a Windows command shell, I get the following (it lists 3.12 now but I don't think it did when going from 3.7 to 3.12, but I also have 3.9.2 installed now).
Attached is the main log file as requested.
Python 3.12.3 (64-bit)_20240428193401.log
zooba commentedon Apr 29, 2024
Okay, it looks like when we fixed installs breaking due to mixed launcher installs I changed the meanings of some variables without updating all the other users of them. Should be a straightforward fix.
pythongh-118347: Fix Windows installer not updating launcher
zooba commentedon Apr 29, 2024
In the meantime, if you want the launcher that comes with 3.12.3, you can get it from https://www.python.org/ftp/python/3.12.3/win32/launcher.msi and double-click to install it directly (or run
msiexec /i launcher.msi ALLUSERS=1for an all-users install, which you @smalers will need to do for your scenario).gh-118347: Fix Windows installer not updating launcher (GH-118386)
pythongh-118347: Fix Windows installer not updating launcher (pythonG…
zooba commentedon Apr 29, 2024
Fix is in and backporting to 3.12.
gh-118347: Fix Windows installer not updating launcher (GH-118386)
pythongh-118347: Fix Windows installer not updating launcher (pythonG…
pythongh-118347: Fix Windows installer not updating launcher (pythonG…