rexdavinci / browser-solidity-compiler

18 stars 7 forks source link

"Error: Function not implemented" on production version. #5

Open kuchaow opened 1 year ago

kuchaow commented 1 year ago

I've been using the package for a bit and it works very well when I'm developing in localhost but I deployed to production and all of a sudden it started giving me that error, I'm not sure what is wrong since in localhost is fine, maybe the webworkers?

I'd appreciate if someone gives me a bit of guidance on this.

kuchaow commented 1 year ago

I use Next.js by the way.

nikola-bozin-org commented 1 year ago

This is fixed in this branch: https://github.com/nikola-bozin-org/browser-solidity-compiler/tree/feature/fixing-web-runner

Use it as simply as importing scripts

SyugamCan commented 1 year ago

@kuchaow The problem been resolved?

bircher044 commented 1 year ago

@kuchaow Hi! did you find the solution?

nikola-bozin-org commented 1 year ago

@kuchaow Hi! did you find the solution?

You can check this package: https://www.npmjs.com/package/solidity-browser-compiler

bircher044 commented 1 year ago

@kuchaow Hi! did you find the solution?

You can check this package: https://www.npmjs.com/package/solidity-browser-compiler

Hi! thanks for your reply! But that version from npm is 1 year old and still has that error. For me worked this one:

"@agnostico/browser-solidity-compiler": "github:Tech-Claw/_solidity-browser-compiler",

nikola-bozin-org commented 1 year ago

@kuchaow Hi! did you find the solution?

You can check this package: https://www.npmjs.com/package/solidity-browser-compiler

Hi! thanks for your reply! But that version from npm is 1 year old and still has that error. For me worked this one:

"@agnostico/browser-solidity-compiler": "github:Tech-Claw/_solidity-browser-compiler",

Are you sure?

This one: https://www.npmjs.com/package/solidity-browser-compiler is 3 months old and it should have the errors fixed.

bircher044 commented 1 year ago

ech-Claw/_solidity-browser-compiler

oh sorry, you are right. I was talking about original @agnostico/browser-solidity-compiler. In any case i got my problem solved currently. Thanks

kuchaow commented 1 year ago

@kuchaow Hi! did you find the solution?

In the end instead of compiling in the browser I set up a cloud function in firebase that returns the compiled contract with solc, much easier.

kuchaow commented 1 year ago

I'd recommend that if any of you all have the same problem, use a regular compiler in a script, set up a server and then make an http request to the server if you need to compile a contract.

kuchaow commented 1 year ago

If you have any doubts you can comment here, I'll leave it open.