Skip to content

fix(bundler): swap WIX registry search order to prioritize InstallDir#14945

Merged
FabianLars merged 3 commits into
tauri-apps:devfrom
veeceey:fix/issue-14213-wix-registry-search-order
Feb 16, 2026
Merged

fix(bundler): swap WIX registry search order to prioritize InstallDir#14945
FabianLars merged 3 commits into
tauri-apps:devfrom
veeceey:fix/issue-14213-wix-registry-search-order

Conversation

@veeceey
Copy link
Copy Markdown
Contributor

@veeceey veeceey commented Feb 15, 2026

Fixes #14213

When both the NSIS default registry key and the named InstallDir key exist (e.g. after migrating from NSIS to WIX), the WIX installer was using the wrong install path on update. This happened because WIX evaluates multiple RegistrySearch entries within a Property and uses the last value found.

The previous order searched for InstallDir first and the NSIS default key second, so the default key would win when both existed. This caused apps installed to C:\Program Files to silently move to the AppData folder on update via the updater plugin.

This swaps the order so the NSIS default key is searched first (as a fallback), and the named InstallDir key is searched second, giving it priority when present.

As @FabianLars noted in the issue thread, swapping the two searches is the correct approach.

@veeceey veeceey requested a review from a team as a code owner February 15, 2026 09:50
@FabianLars
Copy link
Copy Markdown
Member

As @FabianLars noted in the issue thread, swapping the two searches is the correct approach.

I couldn't remember my comment over there at all anymore 😂

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 15, 2026

Package Changes Through 1356a35

There are 3 changes which include tauri-cli with patch, @tauri-apps/cli with patch, tauri-bundler with patch

Planned Package Versions

The following package releases are the planned based on the context of changes in this pull request.

package current next
tauri-bundler 2.8.0 2.8.1
@tauri-apps/cli 2.10.0 2.10.1
tauri-cli 2.10.0 2.10.1

Add another change file through the GitHub UI by following this link.


Read about change files or the docs at github.com/jbolda/covector

@FabianLars
Copy link
Copy Markdown
Member

Thanks for the PR! Would you mind signing (and force-pushing) your commit? Our branch protection rules require that :)

@FabianLars
Copy link
Copy Markdown
Member

Perhaps a small comment in the wix file that explains why the order is like it is would be nice too i think so we don't end up swapping it again 😅

@veeceey
Copy link
Copy Markdown
Contributor Author

veeceey commented Feb 16, 2026

Added a NOTE comment above the RegistrySearch block explaining that in WIX the last successful match wins, so the ordering is intentional. Should help prevent future accidental swaps.

Regarding commit signing — I'll get that sorted and force-push the signed commits shortly.

@veeceey veeceey force-pushed the fix/issue-14213-wix-registry-search-order branch from ae4d190 to 6734788 Compare February 16, 2026 08:15
When both the NSIS default key and the named InstallDir key exist in
the registry, WIX uses the last RegistrySearch value found. The previous
order caused the NSIS default key to override InstallDir, which made
apps installed to Program Files move to AppData on update.

Swap the order so InstallDir (set by the MSI installer) is searched
last and takes priority.

Closes tauri-apps#14213
Adds a NOTE comment above the RegistrySearch block to clarify that
the last successful match wins in WIX, preventing future accidental
reordering.
@veeceey veeceey force-pushed the fix/issue-14213-wix-registry-search-order branch from 6734788 to 57a45b9 Compare February 16, 2026 08:16
@veeceey
Copy link
Copy Markdown
Contributor Author

veeceey commented Feb 16, 2026

Commits are now signed and force-pushed. Also added the NOTE comment you suggested about the registry search ordering.

@FabianLars
Copy link
Copy Markdown
Member

Awesome, thanks!

@FabianLars FabianLars merged commit 6252432 into tauri-apps:dev Feb 16, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[bug] tauri wix template issue with registry search for install location

2 participants