Update architecture filter for arm64 installer#387
Update architecture filter for arm64 installer#387HarithaVattikuti wants to merge 1 commit intomainfrom
Conversation
There was a problem hiding this comment.
Pull request overview
Updates the Windows installer cleanup logic so ARM64 Python MSI registrations (which use an “(ARM64)” DisplayName suffix) are correctly detected and removed, preventing stale registry entries from blocking re-installation on Windows ARM64.
Changes:
- Adjust
Get-RegistryVersionFilterto recognize ARM64 DisplayName suffixes by expanding the architecture match to includeARM64. - Replace simple x86/other logic with a
switchover architecture to support ARM64 explicitly.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| # ARM64 Python installer registers as "(ARM64)" in the display name, not "(64-bit)" | ||
| $archFilter = switch ($Architecture) { | ||
| 'x86' { "32-bit" } | ||
| 'arm64' { "64-bit|ARM64" } | ||
| default { "64-bit" } |
There was a problem hiding this comment.
The comment says the ARM64 installer registers as "(ARM64)" instead of "(64-bit)", but the filter intentionally matches both by using 64-bit|ARM64. Please update the comment to reflect that we're expanding the match to include ARM64 (while still matching 64-bit entries), to avoid misleading future maintainers.
|
@HarithaVattikuti Could you update tests to check the scenario when the exactly same python version is installed in the image, e.g. by installing normal and freethreaded version in the same job 🙏 |
|
@HarithaVattikuti What could we do to retroactively fix |
The 3.14.4 artifacts can be regenerated and released after this pull request is merged. |
Problem
The Python ARM64 installer registers its display name suffix as (ARM64) (for example, "Python 3.14.4 (ARM64)") instead of the more generic (64-bit). As a result, the Remove-RegistryEntries script fails to identify and clean up these ARM64-specific registry entries. This can leave behind stale Windows Installer registrations, which subsequently prevent new installations of Python on ARM64 systems.
Solution
This change updates the logic in Remove-RegistryEntries to properly match and remove ARM64 installer entries by recognizing the (ARM64) suffix. With this fix, stale registry records will be correctly cleared, ensuring that new Python installations on Windows ARM64 are not blocked by previous residual entries.