israelss / vue-worker

A Vue.js plugin to use webworkers in a simply way.
MIT License
593 stars 41 forks source link

Failed to execute 'postMessage' on 'Worker' #9

Open okwme opened 7 years ago

okwme commented 7 years ago

got this error, any ideas?

DOMException: Failed to execute 'postMessage' on 'Worker': function (){return ccall(ident,returnType,argTypes,arguments)} could not be cloned.
    at eval (webpack-internal:///622:1:3485)
    at new Promise (<anonymous>)
    at Worker.o.post (webpack-internal:///622:1:3301)
    at Object.run (webpack-internal:///622:1:3729)
    at eval (webpack-internal:///241:87:26)
    at http://code.dappbench.com/browser-solc.min.js:1:141533
    at HTMLScriptElement.d.readyState.d.onload (http://code.dappbench.com/browser-solc.min.js:1:141310)
counterbeing commented 6 years ago

With zero context or experience with this plugin, i'd bet you're passing an object that contains a function, which cannot be cloned. There are limitations around what can be posted to a worker, I think it's in the README.md.