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.

getRandomValues couldn't be found from a WebWorker in Edge18

See original GitHub issue

Describe the bug

I’ve used uuid v4 in a webworker but now I’m seeing error logs from Edge18.

SCRIPT0: SCRIPT0: uuid: This browser does not seem to support crypto.getRandomValues(). If you need to support this browser, please provide a custom random number generator through options.rng.
27788d0bfdaa0d0b9446.worker.js (2,1)

Runtime

  • OS: Windows 10
  • Runtime: Edge
  • Runtime Version: EdgeHTML 18.19041

Issue Analytics

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

github_iconTop GitHub Comments

2reactions
broofacommented, Mar 2, 2020

@ctavan 'worth noting that this a perfect example of why Math.getRandomValues() is needed.

0reactions
evertbouwcommented, Mar 3, 2020

Thanks!

I wasn’t sure if this was intended because I couldn’t really find anything on Google. In my worker I guess I used uuid out of habit but an auto increment id should suffice so I’m doing that now.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Running window.crypto.getRandomValues() from inside a ...
Having either an async API or having the crypto API being available in Web Workers seems perfectly reasonable to me. Seems like a...
Read more >
WebAssembly | Can I use... Support tables for HTML5, CSS3, etc
getRandomValues () method, but not actual cryptography functionality under ... 3 In Edge 12-18, Web Crypto was not supported in Web Workers and...
Read more >
Safari Technology Preview Release Notes - Apple Developer
Changed to make sure nested worker gets controlled if matching a service worker ... and Edge that use the WebExtension APIs can be...
Read more >
Web Workers are slower and that's OK.
Yes that's right it's over 100,000 times slower to do the function in a web worker and 10,000,000 times slower if you count...
Read more >
WebWorkers: Code Session - Supercharged - YouTube
In this Supercharged Live Code Session, Mariko Kosaka joins Surma to show you how to use WebWorkers to keep your main thread jank...
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