Squirrel.Windows icon indicating copy to clipboard operation
Squirrel.Windows copied to clipboard

Exception when RELEASES contains URL with query parameters, again

Open virror opened this issue 9 years ago • 2 comments

I get this when using electron-builder and electron-release-server. Mu url contains a version number as its required by the server and i talked with the electron-builder team and they said its something on your side.

virror avatar Aug 30 '16 13:08 virror

@virror which version of Squirrel is this occurring on? And are you able to share the specific error you are seeing? It's hard to say where this might be failing without more information.

shiftkey avatar May 05 '19 11:05 shiftkey

I will provide more info as i'm having the same issue.

in the electron-release-server docs it is stated that: You'll just need to configure your Update.exe or Squirrel.Windows to use http://download.myapp.com/update/win32/:version/:channel as a feed URL without query parameters.

The issue is that i couldn't find anything on the internet about this parameters and how to omit them.

This is what happens during the autoUpdate process

2021-05-26 15:39:49> Program: Starting Squirrel Updater: --checkForUpdate http://xx.xx.xx.xx:port/update/win64/1.9.9/stable
2021-05-26 15:39:49> Program: Fetching update information, downloading from http://xx.xx.xx.xx:port/update/win64/1.9.9/stable
2021-05-26 15:39:49> CheckForUpdateImpl: Using existing staging user ID: ad977f1c-3f3e-56c7-a0dc-bd413c9d4be4
2021-05-26 15:39:49> CheckForUpdateImpl: Downloading RELEASES file from http://xx.xx.xx.xx:port/update/win64/1.9.9/stable
2021-05-26 15:39:49> FileDownloader: Downloading url: http://xx.xx.xx.xx:port/update/win64/1.9.9/stable/RELEASES?id=my-app-name&localVersion=1.9.9&arch=amd64
2021-05-26 15:39:49> Unhandled exception: System.AggregateException: Si sono verificati uno o più errori. ---> System.Exception: Filename can either be an absolute HTTP[s] URL, *or* a file name

My autoUpdate code

const url = 'http://xx.xx.xx.xx:port/update/win64/' + appVersion + '/stable';
autoUpdater.setFeedURL({ url });
autoUpdater.checkForUpdates();

I've seen a similar issue (#705) but it was closed without suggesting a solution.

It looks like the problem is on the electron-release-server side but it affirms that, somehow, it is possible to configure Squirrel to not add any parameters to the feed URL.

I started programming not a long time ago so i may be missing something obvious, help is really appreciated

FranzJoseph17 avatar May 28 '21 13:05 FranzJoseph17