Open JamesLMilner opened 5 years ago
Hiya - this is correct, since Greenlet workers do not have an origin. Even if IndexedDB was accessible from the greenlet function context, it would be a different database than would be accessible in the parent document. This is true for the current Data URL -based implementation, but also for the upcoming switch (back) to Blob URLs.
Unfortunately, the only way to correct this behaviour is to produce an actual file/URL that contains the worker code, which means getting into build process stuff and that's not library territory. For that the only solution I have is workerize-loader which is Webpack-specific.
Hello! Just noticed this problem with greenlet on Firefox (66.0.3); indexedDB is
null
in the greenlet execution context.Reproduction case:
Also on Chrome (73.0.3683.103) it appears the success callback is never called:
Let me know if there's any other information I can provide that might be useful here.