Open ih3xcode opened 5 years ago
I get the same error.
same
Hello, mb you have double-"/" ? Cuz your server constant ended on '/' and feed is {server}/..
Seems like result feed is https://hazel.mineinfo80.now.sh//update...
CAN ANYONE FUCKING ANSWER FROM THE FUCKING CREATORS U PIECES OF TRASH, EVERYONE HAS SAME ERROR, AND STUPID DUMB DOCUMENTATION EXPLAINS NOTHING
I got the same error. @electron/autoUpdater and @electron-updater/autoUpdater are different things @electron/autoUpdater gets RELEASE file and download latest .nupkg package whose path written in RELEASE @electron-updater/autoUpdater gets latest.yml and download the latest .exe installer whose path written in latest.yml For usage of electron-updater server, a static file service is enough
Same problem, package is not usable like this with @electron-updater/autoUpdater. Hazel is not supposed to be compatible...
Same error.
any one explane for this error? is Hazel is support for private repo and download release ???
Same error here
I changed some codes to make electron-updater
work well.
these codes will add /files
route on your server, serving each release file directly.
...
// aded new lines below exports.releases
exports.files = async (req, res) => {
const { filename } = req.params;
const latest = await loadCache();
if (!latest.files[filename]) {
send(res, 404, `can't load ${filename}`)
return
}
if (shouldProxyPrivateDownload) {
proxyPrivateDownload(latest.files[filename], req, res);
return
}
res.writeHead(302, {
Location: latest.files[filename].url
})
res.end()
}
...
...
// Clear list of download links
this.latest.platforms = {}
this.latest.files = {}
for (const asset of release.assets) {
const { name, browser_download_url, url, content_type, size } = asset
// added new lines
this.latest.files[name] = {
name,
api_url: url,
url: browser_download_url,
content_type,
size: Math.round(size / 1000000 * 10) / 10
}
if (name === 'RELEASES') {
...
...
// Define a route for every relevant path
...
router.get('/files/:filename', routes.files);
...
and then I removed autoUpdater.setFeedURL({ url })
and added dev-app-update.yml
at ./
provider: generic
url: <hazel-server-url>/files
I changed some codes to make
electron-updater
work well. these codes will add/files
route on your server, serving each release file directly../lib/routes.js
... // aded new lines below exports.releases exports.files = async (req, res) => { const { filename } = req.params; const latest = await loadCache(); if (!latest.files[filename]) { send(res, 404, `can't load ${filename}`) return } if (shouldProxyPrivateDownload) { proxyPrivateDownload(latest.files[filename], req, res); return } res.writeHead(302, { Location: latest.files[filename].url }) res.end() } ...
./lib/cache.js
... // Clear list of download links this.latest.platforms = {} this.latest.files = {} for (const asset of release.assets) { const { name, browser_download_url, url, content_type, size } = asset // added new lines this.latest.files[name] = { name, api_url: url, url: browser_download_url, content_type, size: Math.round(size / 1000000 * 10) / 10 } if (name === 'RELEASES') { ...
./lib/index.js
... // Define a route for every relevant path ... router.get('/files/:filename', routes.files); ...
and then I removed
autoUpdater.setFeedURL({ url })
and addeddev-app-update.yml
at./
provider: generic url: <hazel-server-url>/files
Thanks this one did the trick
I changed some codes to make
electron-updater
work well. these codes will add/files
route on your server, serving each release file directly../lib/routes.js
... // aded new lines below exports.releases exports.files = async (req, res) => { const { filename } = req.params; const latest = await loadCache(); if (!latest.files[filename]) { send(res, 404, `can't load ${filename}`) return } if (shouldProxyPrivateDownload) { proxyPrivateDownload(latest.files[filename], req, res); return } res.writeHead(302, { Location: latest.files[filename].url }) res.end() } ...
./lib/cache.js
... // Clear list of download links this.latest.platforms = {} this.latest.files = {} for (const asset of release.assets) { const { name, browser_download_url, url, content_type, size } = asset // added new lines this.latest.files[name] = { name, api_url: url, url: browser_download_url, content_type, size: Math.round(size / 1000000 * 10) / 10 } if (name === 'RELEASES') { ...
./lib/index.js
... // Define a route for every relevant path ... router.get('/files/:filename', routes.files); ...
and then I removed
autoUpdater.setFeedURL({ url })
and addeddev-app-update.yml
at./
provider: generic url: <hazel-server-url>/files
thanks for this, it really did the trick. Have to make some edits to suite my bundled app
I changed some codes to make
electron-updater
work well. these codes will add/files
route on your server, serving each release file directly../lib/routes.js
... // aded new lines below exports.releases exports.files = async (req, res) => { const { filename } = req.params; const latest = await loadCache(); if (!latest.files[filename]) { send(res, 404, `can't load ${filename}`) return } if (shouldProxyPrivateDownload) { proxyPrivateDownload(latest.files[filename], req, res); return } res.writeHead(302, { Location: latest.files[filename].url }) res.end() } ...
./lib/cache.js
... // Clear list of download links this.latest.platforms = {} this.latest.files = {} for (const asset of release.assets) { const { name, browser_download_url, url, content_type, size } = asset // added new lines this.latest.files[name] = { name, api_url: url, url: browser_download_url, content_type, size: Math.round(size / 1000000 * 10) / 10 } if (name === 'RELEASES') { ...
./lib/index.js
... // Define a route for every relevant path ... router.get('/files/:filename', routes.files); ...
and then I removed
autoUpdater.setFeedURL({ url })
and addeddev-app-update.yml
at./
provider: generic url: <hazel-server-url>/files
I am Facing Same Issue But I am working with github releases with private repo , ANY HELP in my case?
I changed some codes to make
electron-updater
work well. these codes will add/files
route on your server, serving each release file directly../lib/routes.js
... // aded new lines below exports.releases exports.files = async (req, res) => { const { filename } = req.params; const latest = await loadCache(); if (!latest.files[filename]) { send(res, 404, `can't load ${filename}`) return } if (shouldProxyPrivateDownload) { proxyPrivateDownload(latest.files[filename], req, res); return } res.writeHead(302, { Location: latest.files[filename].url }) res.end() } ...
./lib/cache.js
... // Clear list of download links this.latest.platforms = {} this.latest.files = {} for (const asset of release.assets) { const { name, browser_download_url, url, content_type, size } = asset // added new lines this.latest.files[name] = { name, api_url: url, url: browser_download_url, content_type, size: Math.round(size / 1000000 * 10) / 10 } if (name === 'RELEASES') { ...
./lib/index.js
... // Define a route for every relevant path ... router.get('/files/:filename', routes.files); ...
and then I removed
autoUpdater.setFeedURL({ url })
and addeddev-app-update.yml
at./
provider: generic url: <hazel-server-url>/files
I am Facing Same Issue But I am working with github releases with private repo , ANY HELP in my case? You have to setup Github credentials on hazel before deploy and then it will download the artifact correctly I had the same use case.
Im using electron-updater; its throwing:
Cannot find channel "latest.yml" update info: HttpError: 404
config:const { autoUpdater } = require("electron-updater") const server = "https://hazel.mineinfo80.now.sh/"; const feed = "${server}/update/${process.platform}/${app.getVersion()}";