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

autoUpdater unhandled rejection

Open skident opened this issue 4 months ago • 1 comments

  • Electron-Builder Version: "electron-builder": "^23.3.3", "electron-updater": "^5.3.0",

node v18.15.0

  • Electron Version: "electron": "^25.3.0",
  • Electron Type (current, beta, nightly):

macOS

I have an auto update logic in my app and sometimes I get an error like this one "Error: Cannot download "https://xxx/yyy/app.zip", status 403: Forbidden" I am totally fine with the issue, I have a handler for such types of errors which looks like this autoUpdater.on("error", (error) => {...}); But somehow this error is propagated to the very top level and ends up in the unhandled rejection handler. I wrapped everything with try catch blocks but anyway I get the unhandled rejection error.

Any ideas how to fix it?

skident avatar Feb 15 '24 09:02 skident

Can you try adding additional logging to the updater flow? https://www.electron.build/auto-update#debugging

mmaietta avatar Feb 16 '24 22:02 mmaietta