Closed dboakes closed 3 years ago
Seeing this also today, I recently updated to the electron builder pre-release (22.10.4) to fix a taskbar icon unpinning issue so thought that was the cause, but going by your versions maybe not.
Electron Builder Version: 22.10.4 (pre-release) Electron Version: 11.2.0 Electron Updater Version: 4.3.5
Maybe an issue on Github's end?
Edit: Just noticed you and the commenter below me are using S3... guess I'll report I'm experiencing the same issue with updating from a Github private repo.
I also experienced this today - using a github private repo for releases.
Seeing this also today, I recently updated to the electron builder pre-release (22.10.4) to fix a taskbar icon unpinning issue so thought that was the cause, but going by your versions maybe not.
Electron Builder Version: 22.10.4 (pre-release) Electron Version: 11.2.0 Electron Updater Version: 4.3.5
~Maybe an issue on Github's end?~ Edit: Just noticed you and the commenter below me are using S3... guess I'll report I'm experiencing the same issue with updating from a Github private repo.
I'm also using a private github repo, I suspect they use S3 to store the release files, which would be why the error says that. So you might well be right that it's a github issue to be honest.
Experiencing the exact same issue since yesterday, with a private github repo for releases.
Just noticed a pull request which seems to cover this issue at #5594. Made the adjustment in my local project, and fixed the error, but seems to be failing some of their tests so may lead to some other issues? Definitely the right direction though!
facing the same issue for github private repo.
Same for me. Also private repo.
Electron Builder Version: 22.3.2
Electron Version: 8.0.1
Electron Updater Version: 4.3.4
Another one here, I don't really know why some weeks ago the release system works fine but not now. I didn't touch nothing in my code.
Also in a private repo
Electron Builder: 22.9.1 Electron Updater: 4.3.5 Electron: 9.2.0
Same thing here, private repo. Someone fixed it?
node_modules/builder-util-runtime/out/httpExecutor.js
.endsWith(".amazonaws.com")
and replace with .endsWith(".amazonaws.com") || parsedNewUrl.searchParams.has("X-Amz-Credential")
Thanks to @GaryCaldwell https://github.com/electron-userland/electron-builder/pull/5594
- Open
node_modules/builder-util-runtime/out/httpExecutor.js
- Find
.endsWith(".amazonaws.com")
and replace with.endsWith(".amazonaws.com") || parsedNewUrl.searchParams.has("X-Amz-Credential")
- Done
Thanks to @GaryCaldwell #5594
Doesn't this have to be fixed somehow else? What if people have the older version installed and can't update to the new one?
I also experienced this today - using a github private repo for releases.
@abraaoz @paulkoeckdev - replace with .endsWith(".amazonaws.com") || parsedNewUrl.searchParams.has("X-Amz-Credential") is not working!!
Doesn't this have to be fixed somehow else? What if people have the older version installed and can't update to the new one?
Also having this issue, no code and repo configuration changed.
EDIT:
1. Open `node_modules/builder-util-runtime/out/httpExecutor.js` 2. Find `.endsWith(".amazonaws.com")` and replace with `.endsWith(".amazonaws.com") || parsedNewUrl.searchParams.has("X-Amz-Credential")` 3. Done
Thanks to @GaryCaldwell #5594
This fixed it for me, but a permanent solution is needed without changing the node_modules.
Its also happening to me
I changed to public repo but still have this error
Me too. Public Github repo
I'm having the same issue with a private GitHub repo. I haven't made any changes at all in several weeks, but all of a sudden this error message pops up and unable to update.
Electron Builder: 22.8.0 Electron Updater: 4.3.4 Electron: 10.1.2
Same error here. No changes and sudden my app is unable to update.
- Open
node_modules/builder-util-runtime/out/httpExecutor.js
- Find
.endsWith(".amazonaws.com")
and replace with.endsWith(".amazonaws.com") || parsedNewUrl.searchParams.has("X-Amz-Credential")
- Done
Thanks to @GaryCaldwell #5594
This definitely fixed the error running on my local machine, but what about 500+ installs of my app on users machines? They can't get this update because their local versions will be failing checking for the update. There has to be another fix applied to a server somewhere right?
- Open
node_modules/builder-util-runtime/out/httpExecutor.js
- Find
.endsWith(".amazonaws.com")
and replace with.endsWith(".amazonaws.com") || parsedNewUrl.searchParams.has("X-Amz-Credential")
- Done
Thanks to @GaryCaldwell #5594
Doesn't this have to be fixed somehow else? What if people have the older version installed and can't update to the new one?
^ This is what I was trying to ask. Users have the old one installed, so how do they update to get the new one?
Does anyone know if this may have something to do with electron-builder
or electron-updater
itself? I'm trying to see if perhaps doing version rollback may solve the problem temporarily.
I'm using:
No, the latest version of the same problem.
1. Open `node_modules/builder-util-runtime/out/httpExecutor.js` 2. Find `.endsWith(".amazonaws.com")` and replace with `.endsWith(".amazonaws.com") || parsedNewUrl.searchParams.has("X-Amz-Credential")` 3. Done
Thanks to @GaryCaldwell #5594
This fix works. But I've having problems when downloading a new published version in GitHub. It's downloading at 2 KB/s and finally the connection goes down. I'm experimenting some problems in GitHub, is a private repo.
Same issue here with the latest version available
Same issue. Using GitHub private repo. Need server side fix otherwise other users won't get latest update so the workaround mentioned above isn't a viable option. Please help! Thanks.
Same behaviour here and also needing a server side solution because I can ask all my users to download a new version manually.
Same issue here with GitHub repo. Thank you in advance!
For anyone running Quasar framework (or other framework that rebuilds dependencies) the above (client side) fixes didn't work for me as npm always rebuilds before building the executables, this might save someone a couple hours...
quasar.conf.js (feel free to remove all the console logs)
electron: {
bundler: 'builder', // 'packager' or 'builder'
builder: {
beforeBuild: arg => {
console.log(
`\r\n\r\nStarting patch for electron-updater issue\r\nSee https://github.com/electron-userland/electron-builder/issues/5595 for why this patch is necessary.\r\n`
);
const { appDir } = arg;
const fs = require('fs');
const path = require('path');
const fileName = 'httpExecutor.js';
const modulePath = 'node_modules/builder-util-runtime/out';
const filePath = path.join(appDir, modulePath, fileName);
try {
let fileContents = fs.readFileSync(filePath, 'utf8');
if (fileContents) {
const findString = new RegExp(
/\.endsWith\("\.amazonaws\.com"\)\)/
);
const replaceString =
'.endsWith(".amazonaws.com") || parsedNewUrl.searchParams.has("X-Amz-Credential"))';
if (fileContents.search(findString) > -1) {
console.log(
`Found string to patch in './${modulePath}/${fileName}', making the changes...`
);
fileContents = fileContents.replace(findString, replaceString);
try {
fs.writeFileSync(filePath, fileContents, 'utf8');
console.log(`${fileName} successfully patched!`);
} catch (err) {
console.error(`There was a problem writing the file back`);
}
} else {
console.warn(
`File was read successfully but could not find string to patch, check the issue above to see if this is still necessary.`
);
}
}
} catch (err) {
console.error(`Could not read ${fileName}`, err);
}
console.log(`\r\n\r\n`);
return true; // Do not remove this or node_modules folder is never placed in .asar
},
},
},
- Open
node_modules/builder-util-runtime/out/httpExecutor.js
- Find
.endsWith(".amazonaws.com")
and replace with.endsWith(".amazonaws.com") || parsedNewUrl.searchParams.has("X-Amz-Credential")
- Done
Thanks to @GaryCaldwell #5594
Doesn't this have to be fixed somehow else? What if people have the older version installed and can't update to the new one?
^ This is what I was trying to ask. Users have the old one installed, so how do they update to get the new one?
Does anyone have any pointers for this exact issue? I'm unsure how to distribute the fix to the current users 🤔 Appreciate any help given 🙏🏽
Same issue with Github Private Reo. Any help would be great! ❤️
omg def need a fix.. can't wait!!
Same issue here with GitHub private repo. Any help would be much appreciated.
Same issue occurs since 5 days with a public repo. Any guidance and help for this would be greatly appreciated.
Same issue on a private GitHub repo...
I am amazed at how little interest this bug seems to have, nobody uses Electron? I think I will migrate to a generic server to avoid this kind of problem in the future ...
Same issue, what happened to my client???
Does the fix mentioned above not work? I've been running it within my test users and its solved all their problems. I'm not the expert but based on the nature of the issue I dont see it as likely that a service side fix is possible. Thats how AWS works it would require github to move back where they publish releases I think.
You will have to ask all your users to manually download your newest version with the fix in place
Does the fix mentioned above not work? I've been running it within my test users and its solved all their problems. I'm not the expert but based on the nature of the issue I dont see it as likely that a service side fix is possible. Thats how AWS works it would require github to move back where they publish releases I think.
You will have to ask all your users to manually download your newest version with the fix in place
I hear what you're saying, but the problem with this is that we can't simply ask users to manually download a new update. There are more than 1000 users using our application now and not all of them will know how to do this. It might be easy to some people but not to others. Some users wont have a clue what to do. That's why auto updates are so good to use in the first place.
What worries me is that this could happen again at some point and then what? Do some sort of manual update again? We just can't risk that. I agree with @stephanebouget, we are going to migrate to a generic server and take back some control.
But the people who built this Updater system (infinite thanks for it) don't thought on this scenario? xD
But the people who built this Updater system (infinite thanks for it) don't thought on this scenario? xD
I agree. It's so difficult to know what's going to happen in the future. I don't think it's the fault of developers at all, I think something has happened outside of their control. I am hugely grateful to everyone who has contributed to building this for us all to use, it's a brilliant tool.
Complicated, updating everyone is immensely complicated! Many users who do not know how to update manual! what if the update is critical?
Has anybody made a donation yet requesting this issue? I am sure if we all chip in a couple bucks they would fix this faster...
Same issue: using private github repo
Electron Builder Version: 22.9.1 Electron Version: 1.7.9 Electron Updater Version: 2.9.3 Target: mac - dmg and zip
need an urgent fix pls.
Has anybody made a donation yet requesting this issue? I am sure if we all chip in a couple bucks they would fix this faster...
I've donated claiming for help xD
Same issue here. This needs to be fixed asap.
1. Open `node_modules/builder-util-runtime/out/httpExecutor.js` 2. Find `.endsWith(".amazonaws.com")` and replace with `.endsWith(".amazonaws.com") || parsedNewUrl.searchParams.has("X-Amz-Credential")` 3. Done
Thanks to @GaryCaldwell #5594
this works for me but for new version after changed not for previous version!
This is not the fault of the Electron Builder software. Something has changed on the AWS side and until they revert whatever change they made, existing installed apps will never be able to update. The suggested fix will only make future updates work, but unfortunately, existing users will have to install that next version manually that has the code fix.
We have taken out the release through Github Releases/AWS completely and changed to a generic server so we never have this problem again and had to send out a manual download link with an apology. Many users are ok with clicking a manual download link and letting it install and then you can carry on as you were. It is embarrassing and a massive pain I know but it gets you back up and running.
I am experiencing the same issue with a private GitHub repo. My question is why is my auto update even attempting to check AWS S3? No where within my configuration am I publishing to AWS S3.
Here is the error message received:
Checking for update
Error: HttpError: 400
"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<Error><Code>InvalidArgument</Code><Message>Only one auth mechanism allowed; only the X-Amz-Algorithm query parameter, Signature query string parameter or the Authorization header should be specified</Message><ArgumentName>Authorization</ArgumentName><ArgumentValue>token <GITHUB_TOKEN></ArgumentValue><RequestId>8CEA7569D23AFA24</RequestId><HostId>yARBtPCpNEB6aQ4b7PiSQbix/MSHeXr7/HN7ZhlAElWsnJpoxwYpCoCmfJpCcHJJSHeCbhlh43w=</HostId></Error>"
Headers: {
"status": "400",
"x-amz-request-id": "8CEA7569D23AFA24",
"x-amz-id-2": "yARBtPCpNEB6aQ4b7PiSQbix/MSHeXr7/HN7ZhlAElWsnJpoxwYpCoCmfJpCcHJJSHeCbhlh43w=",
"content-type": "application/xml",
"server": "AmazonS3",
"accept-ranges": "bytes",
"via": "1.1 varnish, 1.1 varnish",
"date": "Thu, 11 Feb 2021 18:44:54 GMT",
"x-served-by": "cache-dca12925-DCA, cache-mrs10565-MRS",
"x-cache": "MISS, MISS",
"x-cache-hits": "0, 0",
"strict-transport-security": "max-age=31536000",
"x-fastly-request-id": "444c3542b3369d5cc49bacfa2f63848eed31db77"
}
at d (C:\Users\DouglassHock\AppData\Local\Programs\reportapp\resources\app.asar\background.js:2:233011)
at IncomingMessage.<anonymous> (C:\Users\DouglassHock\AppData\Local\Programs\reportapp\resources\app.asar\background.js:2:235343)
at IncomingMessage.emit (events.js:310:20)
at endReadableNT (_stream_readable.js:1187:12)
at processTicksAndRejections (internal/process/task_queues.js:84:21)
Unhandled Rejection at: Promise {
<rejected> m [HttpError]: 400
"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<Error><Code>InvalidArgument</Code><Message>Only one auth mechanism allowed; only the X-Amz-Algorithm query parameter, Signature query string parameter or the Authorization header should be specified</Message><ArgumentName>Authorization</ArgumentName><ArgumentValue>token <GITHUB_TOKEN></ArgumentValue><RequestId>8CEA7569D23AFA24</RequestId><HostId>yARBtPCpNEB6aQ4b7PiSQbix/MSHeXr7/HN7ZhlAElWsnJpoxwYpCoCmfJpCcHJJSHeCbhlh43w=</HostId></Error>"
Headers: {
"status": "400",
"x-amz-request-id": "8CEA7569D23AFA24",
"x-amz-id-2": "yARBtPCpNEB6aQ4b7PiSQbix/MSHeXr7/HN7ZhlAElWsnJpoxwYpCoCmfJpCcHJJSHeCbhlh43w=",
"content-type": "application/xml",
"server": "AmazonS3",
"accept-ranges": "bytes",
"via": "1.1 varnish, 1.1 varnish",
"date": "Thu, 11 Feb 2021 18:44:54 GMT",
"x-served-by": "cache-dca12925-DCA, cache-mrs10565-MRS",
"x-cache": "MISS, MISS",
"x-cache-hits": "0, 0",
"strict-transport-security": "max-age=31536000",
"x-fastly-request-id": "444c3542b3369d5cc49bacfa2f63848eed31db77"
}
at d (C:\Users\DouglassHock\AppData\Local\Programs\reportapp\resources\app.asar\background.js:2:233011)
at IncomingMessage.<anonymous> (C:\Users\DouglassHock\AppData\Local\Programs\reportapp\resources\app.asar\background.js:2:235343)
at IncomingMessage.emit (events.js:310:20)
at endReadableNT (_stream_readable.js:1187:12)
at processTicksAndRejections (internal/process/task_queues.js:84:21) {
statusCode: 400,
description: '<?xml version="1.0" encoding="UTF-8"?>\n' +
'<Error><Code>InvalidArgument</Code><Message>Only one auth mechanism allowed; only the X-Amz-Algorithm query parameter, Signature query string parameter or the Authorization header should be specified</Message><ArgumentName>Authorization</ArgumentName><ArgumentValue>token <GITHUB_TOKEN></ArgumentValue><RequestId>8CEA7569D23AFA24</RequestId><HostId>yARBtPCpNEB6aQ4b7PiSQbix/MSHeXr7/HN7ZhlAElWsnJpoxwYpCoCmfJpCcHJJSHeCbhlh43w=</HostId></Error>',
code: 'HTTP_ERROR_400'
}
} reason: HttpError: 400
I am experiencing the same issue with a private GitHub repo. My question is why is my auto update even attempting to check AWS S3? No where within my configuration am I publishing to AWS S3.
Here is the error message received:
Checking for update Error: HttpError: 400 "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<Error><Code>InvalidArgument</Code><Message>Only one auth mechanism allowed; only the X-Amz-Algorithm query parameter, Signature query string parameter or the Authorization header should be specified</Message><ArgumentName>Authorization</ArgumentName><ArgumentValue>token <GITHUB_TOKEN></ArgumentValue><RequestId>8CEA7569D23AFA24</RequestId><HostId>yARBtPCpNEB6aQ4b7PiSQbix/MSHeXr7/HN7ZhlAElWsnJpoxwYpCoCmfJpCcHJJSHeCbhlh43w=</HostId></Error>" Headers: { "status": "400", "x-amz-request-id": "8CEA7569D23AFA24", "x-amz-id-2": "yARBtPCpNEB6aQ4b7PiSQbix/MSHeXr7/HN7ZhlAElWsnJpoxwYpCoCmfJpCcHJJSHeCbhlh43w=", "content-type": "application/xml", "server": "AmazonS3", "accept-ranges": "bytes", "via": "1.1 varnish, 1.1 varnish", "date": "Thu, 11 Feb 2021 18:44:54 GMT", "x-served-by": "cache-dca12925-DCA, cache-mrs10565-MRS", "x-cache": "MISS, MISS", "x-cache-hits": "0, 0", "strict-transport-security": "max-age=31536000", "x-fastly-request-id": "444c3542b3369d5cc49bacfa2f63848eed31db77" } at d (C:\Users\DouglassHock\AppData\Local\Programs\reportapp\resources\app.asar\background.js:2:233011) at IncomingMessage.<anonymous> (C:\Users\DouglassHock\AppData\Local\Programs\reportapp\resources\app.asar\background.js:2:235343) at IncomingMessage.emit (events.js:310:20) at endReadableNT (_stream_readable.js:1187:12) at processTicksAndRejections (internal/process/task_queues.js:84:21) Unhandled Rejection at: Promise { <rejected> m [HttpError]: 400 "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<Error><Code>InvalidArgument</Code><Message>Only one auth mechanism allowed; only the X-Amz-Algorithm query parameter, Signature query string parameter or the Authorization header should be specified</Message><ArgumentName>Authorization</ArgumentName><ArgumentValue>token <GITHUB_TOKEN></ArgumentValue><RequestId>8CEA7569D23AFA24</RequestId><HostId>yARBtPCpNEB6aQ4b7PiSQbix/MSHeXr7/HN7ZhlAElWsnJpoxwYpCoCmfJpCcHJJSHeCbhlh43w=</HostId></Error>" Headers: { "status": "400", "x-amz-request-id": "8CEA7569D23AFA24", "x-amz-id-2": "yARBtPCpNEB6aQ4b7PiSQbix/MSHeXr7/HN7ZhlAElWsnJpoxwYpCoCmfJpCcHJJSHeCbhlh43w=", "content-type": "application/xml", "server": "AmazonS3", "accept-ranges": "bytes", "via": "1.1 varnish, 1.1 varnish", "date": "Thu, 11 Feb 2021 18:44:54 GMT", "x-served-by": "cache-dca12925-DCA, cache-mrs10565-MRS", "x-cache": "MISS, MISS", "x-cache-hits": "0, 0", "strict-transport-security": "max-age=31536000", "x-fastly-request-id": "444c3542b3369d5cc49bacfa2f63848eed31db77" } at d (C:\Users\DouglassHock\AppData\Local\Programs\reportapp\resources\app.asar\background.js:2:233011) at IncomingMessage.<anonymous> (C:\Users\DouglassHock\AppData\Local\Programs\reportapp\resources\app.asar\background.js:2:235343) at IncomingMessage.emit (events.js:310:20) at endReadableNT (_stream_readable.js:1187:12) at processTicksAndRejections (internal/process/task_queues.js:84:21) { statusCode: 400, description: '<?xml version="1.0" encoding="UTF-8"?>\n' + '<Error><Code>InvalidArgument</Code><Message>Only one auth mechanism allowed; only the X-Amz-Algorithm query parameter, Signature query string parameter or the Authorization header should be specified</Message><ArgumentName>Authorization</ArgumentName><ArgumentValue>token <GITHUB_TOKEN></ArgumentValue><RequestId>8CEA7569D23AFA24</RequestId><HostId>yARBtPCpNEB6aQ4b7PiSQbix/MSHeXr7/HN7ZhlAElWsnJpoxwYpCoCmfJpCcHJJSHeCbhlh43w=</HostId></Error>', code: 'HTTP_ERROR_400' } } reason: HttpError: 400
welcome to the club buddy, we're all waiting for the developers to merge the PR with the fix for this issue. it's also not their fault it's more on AWS side of things because of some aauth credentials or tokens.
Electron Builder Version: 22.9.1
Electron Version: 9.1.0
Electron Type (current, beta, nightly): current
Electron Updater Version: 4.3.5
Target: mac - dmg and zip
Since yesterday, I've not been able to use the updater on my app. Anytime the app checks for an update, I get the below error message.
I'm aware something like this has happened before, per #1370, however this suddenly popped up on old and new versions of Electron Builder/Updater.
I was using Electron Updater v4.2.2 and Electron Builder v22.7.0, before updating to the latest versions listed above, but regardless, the issue is the same.
I haven't changed anything about my config for weeks, so struggling to figure out what the issue might be. Any help would be appreciated!
ERROR MESSAGE
package.json config: