electron-builder icon indicating copy to clipboard operation
electron-builder copied to clipboard

Electron-Builder NSIS Installer Fails to Update: Deletes Files But Doesn't Reinstall

Open prostarz opened this issue 6 months ago • 6 comments

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.

prostarz avatar Jun 25 '25 12:06 prostarz

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.

mnvr avatar Jul 03 '25 14:07 mnvr

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.

github-actions[bot] avatar Aug 24 '25 00:08 github-actions[bot]

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.

ff-marco-pereira avatar Sep 03 '25 21:09 ff-marco-pereira

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?

ta1m1kam avatar Oct 23 '25 12:10 ta1m1kam