Electron-Builder NSIS Installer Fails to Update: Deletes Files But Doesn't Reinstall
Description
I am encountering a critical issue with the electron-builder generated Windows NSIS installer when attempting to update an already installed application.
Problem: When the installer is executed on a system where the application is already installed (e.g., attempting an update), it deletes the existing application files but then fails to complete the reinstallation process. This leaves the application in a broken, uninstalled state.
Behavior:
- When updating: Installer runs, removes existing app files, then either crashes or fails to proceed with the new installation, leaving the directory empty or partially removed.
- When performing a fresh install: If the application is not already installed, the installer works perfectly fine, installing the application as expected.
This behaviour suggests an issue specifically within the update mechanism or how the installer interacts with an existing installation, rather than a general installation problem.
Same outcome is being reported by Windows users of our app. We're using electron-builder 26.0.14 and electron-updater 6.6.5.
I am starting to see this issue with electron-builder 24.X. It worked fine with 22.10.5. Please recommend some solution if available
This issue is stale because it has been open for 30 days with no activity. Remove stale label or comment, or this will be closed in 30 days.
Try "electron-updater": "^6.3.0-alpha.6" and "electron-builder": "^24.4.0", I got it to work for windows 11 but disabling differential updates.
I got this working by providing different productname and artifactname. But I wanted to know if there is any other solution available.
I'm experiencing the same issue when using the NSIS installer.
Environment:
electron-updater: 6.6.8 electron-builder: 26.0.20
Has anyone found a solution or workaround for this?