maci icon indicating copy to clipboard operation
maci copied to clipboard

Use `snarkjs` API call instead of CLI call

Open baumstern opened this issue 3 years ago • 2 comments

There are some snarkjs call using shell execution (e.g.). But it is error-prone to check execution result.

API call example

baumstern avatar Aug 29 '22 08:08 baumstern

@gurrpi can you assign this issue to me , I can work on it

sleepyqadir avatar Sep 03 '22 10:09 sleepyqadir

@gurrpi can you assign this issue to me , I can work on it

Cool! Just be aware current active branch is v1.

baumstern avatar Sep 03 '22 10:09 baumstern

FYI @sleepyqadir I'm unassigning this from you. If you'd like to return to this, please let us know!

Also copying over @yuetloo's comments from #746

Hi,

Package managers like npm and yarn have optimization that hoist shared packages to the root level. When application like clrfund imports MACI packages, and the snarkjs package is hoisted up to root level, application will get path not found error.

This is the line for the hardcoded snark.js path https://github.com/privacy-scaling-explorations/maci/blob/78609349aecd94186216ac8743d61b1cb81a097f/circuits/ts/index.ts#L8

Is there any plan to not hardcode the path? For example, use snarkjs api as describe here: > https://github.com/iden3/snarkjs#using-node

samajammin avatar Oct 26 '23 20:10 samajammin