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.

app crashed after reload/refresh using web workers

See original GitHub issue

NWJS Version : 0.46.0-sdk Operating System : OSX

Expected behavior

Don’t crash.

Actual behavior

Screenshot_2020-05-21_at_14_35_24

How to reproduce

  1. Open app.
  2. Register web worker.
self.onmessage = e => console.log(e);
self.postMessage('OK');  
  1. nw.Window.get().reload()
  2. Wait 5-20s.

More info

  • tested on 0.45.4 - 0.46.0 with same result
  • nw.Window.get().reloadDev() => TypeError: nw.Window.get(...).reloadDev is not a function

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
rogerwangcommented, May 30, 2020

This is fixed in git and will be available in the next nightly build.

0reactions
xlandcommented, Feb 17, 2022

This issue also happens on 0.61.0.0 @rogerwang

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Fix the Refresh Button When Using Service Workers
In a previous article, I explained how and why Service Workers break the browser's Refresh button by default. Getting this right requires an ......
Read more >
Service worker issue: page never loads when ...
I now understand that the service worker is replaced when "Update on reload" is checked even if the service worker hasn't changed.
Read more >
How To Hard Reload Your React Web App Using Error ...
You just need to write the logic to hard reload the page when the user hits the refresh button. Step 1: Uninstall service...
Read more >
The service worker lifecycle - web.dev
If you force-reload the page (shift-reload) it bypasses the service worker entirely. It'll be uncontrolled. This feature is in the spec, so it ......
Read more >
Let It Crash: Best Practices for Handling Node.js Errors on ...
At last, we arrive at higher-level error types: the error events thrown by JavaScript itself. When a JavaScript error is not properly handled, ......
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