question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Updater: download-progress event not firing

See original GitHub issue
  • Version: “vue-cli-plugin-electron-builder”: “1.4.4”, “electron-builder”: “^21.2.0”,
  • Electron Version: “electron”: “^6.1.7”,

  • Electron Type (current, beta, nightly): current

  • Target: Windows

From the autoUpdater logs:

[2020-05-02 10:59:11.283] [info] Checking for update
[2020-05-02T08:59:11.290Z] [verbose]: updater: checking-for-update
[2020-05-02T08:59:11.291Z] [verbose]: status message to renderer, win (true): {"loading":true,"message":"Checking for update..."}
[2020-05-02T08:59:11.291Z] [debug]: application_update event: {"loading":true,"message":"Checking for update..."}
[2020-05-02 10:59:14.436] [info] Found version 1.2.37 (url: Rekordcloud-Companion-App-Setup.exe)
[2020-05-02T08:59:14.441Z] [verbose]: updater: update-available
[2020-05-02 10:59:14.441] [info] Downloading update from Rekordcloud-Companion-App-Setup.exe
[2020-05-02T08:59:14.442Z] [verbose]: status message to renderer, win (true): {"loading":true,"message":"Update found, downloading..."}
[2020-05-02T08:59:14.442Z] [debug]: application_update event: {"loading":true,"message":"Update found, downloading..."}
[2020-05-02 10:59:14.448] [debug] updater cache dir: C:\Users\Alpha\AppData\Local\rekordcloud-companion-app-updater
[2020-05-02 10:59:14.456] [info] No cached update info available
[2020-05-02 10:59:14.462] [info] Download block maps (old: "https://github.com/rekordcloud/companion-app-releases/releases/download/v1.2.36/Rekordcloud-Companion-App-Setup.exe.blockmap", new: https://github.com/rekordcloud/companion-app-releases/releases/download/v1.2.37/Rekordcloud-Companion-App-Setup.exe.blockmap)
[2020-05-02 10:59:15.443] [debug] g37lYn5+Uv1hYjkjPz8yNqpB duplicated in blockmap (same size), it doesn't lead to broken differential downloader, just corresponding block will be skipped)
[2020-05-02 10:59:15.449] [debug] 9sp5PQVmpRErRDAGvBxKRxuc duplicated in blockmap (same size), it doesn't lead to broken differential downloader, just corresponding block will be skipped)
[2020-05-02 10:59:15.454] [debug] wYAigekaq26SS4iYDHzXIMtX duplicated in blockmap (same size), it doesn't lead to broken differential downloader, just corresponding block will be skipped)
... more of the same
[2020-05-02 10:59:15.927] [info] File has 3972 changed blocks
[2020-05-02 10:59:15.934] [debug] [
  {
    "kind": 1,
    "start": 0,
    "end": 15450
  },
  {
    "kind": 0,
    "start": 15450,
    "end": 23693
  },
  ... more of the same
]
[2020-05-02 10:59:15.954] [info] Full: 197,721.73 KB, To download: 88,373.3 KB (45%)
[2020-05-02 10:59:16.710] [info] Differential download: https://github.com/rekordcloud/companion-app-releases/releases/download/v1.2.37/Rekordcloud-Companion-App-Setup.exe
[2020-05-02 10:59:16.716] [debug] download range: bytes=0-15449
[2020-05-02 10:59:17.035] [info] Redirect to https://github-production-release-asset-2e65be.s3.amazonaws.com/211889690/3513c780-8b98-11ea-90e7-2ed003eb3083
[2020-05-02 10:59:17.145] [debug] download range: bytes=23693-80118
[2020-05-02 10:59:17.265] [debug] download range: bytes=126502-139280
[2020-05-02 10:59:17.404] [debug] download range: bytes=8443316-12174819
[2020-05-02 10:59:18.540] [debug] download range: bytes=25503850-26079736
... more of this

During all this the download-progress event has not fired.

    autoUpdater.on('checking-for-update', () => {
      log('updater: checking-for-update')
    })

    autoUpdater.on('update-available', async () => {
      log('updater: update-available')
    })

    autoUpdater.on('download-progress', (progressObj: IDownloadProgress) => { // Does not fire
      log('updater: download-progress')
    })

It has worked before and I can’t really say if it’s broken for all users or not but this issue has been in here for quite a while.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:6
  • Comments:10 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
harshitsillycommented, Sep 10, 2020

@Oscabrera - hi plz use this module https://www.npmjs.com/package/@imjs/electron-differential-updater the one you are referring to is not supported by us anymore…

0reactions
samuelmaddockcommented, Nov 19, 2020

This issue seemingly started happening when differential downloads were fixed (#4736). When the differential download failed previously, the full download would occur and ‘download-progress’ events would be emitted as expected. With differential downloads working, the events are no longer emitted.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Electron Updater download-progress Event no getting called
I´d like to show a progressbar inside my Electron App while an update gets downloaded. So, I´ ...
Read more >
BackgroundFetchRegistration: progress event - Web APIs | MDN
Practically, this event is fired when any of the following properties will return a new value: uploaded ,; downloaded ,; result , or ......
Read more >
Progress Events - Chrome Developers
There are five types of events that developers can respond to in Native Client: progress, message, view change, focus, and input events (each...
Read more >
Axios — Download Progress in Node.js - Future Studio
You can then notify the progress bar to update the status. Here's a working implementation of an Axios download showing its progress on...
Read more >
Angular File Download with Progress | Nils Mehlhorn
I found a problem, though: Download . The Download interface is not generic. Your StackBlitz also shows that error. Fixed by removing the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found