Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

prover.ts: decouple prover.ts from zk.js #169

Closed
wants to merge 7 commits into from
Closed

prover.ts: decouple prover.ts from zk.js #169

wants to merge 7 commits into from

Conversation

sergeytimoshin
Copy link
Contributor

@sergeytimoshin sergeytimoshin commented Jul 4, 2023

Draft based on #126

@ananas-block
Copy link
Contributor

Thanks!

I noticed that it is not used in zk.js yet (it probably wasn't used in the prior pr either).
In zk.js it is used in transaction.ts
Can you replace the prover class in zk.js?
(Then it will be naturally included in more tests in zk.js and light-system programs as well.)

);
});

it("Test Generic Self-contained Prover for VerifierZero", async () => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

regarding tests you could add a couple more standard tests:

  • failing
  • run full prove two times and receive the same public inputs as output (the proof will be different ofc because it is using different randomness)

@ananas-block
Copy link
Contributor

snarkjs's process does not terminate automatically can you add the following to terminate it?

(globalThis as any).curve_bn128.terminate();

see iden3/snarkjs#152

@ananas-block ananas-block changed the title draft;light-prover-sdk cleanup light-prover-sdk: decouple prover.ts from zk.js Jul 4, 2023
@ananas-block ananas-block changed the title light-prover-sdk: decouple prover.ts from zk.js prover.ts: decouple prover.ts from zk.js Jul 4, 2023
});

after(async () => {
globalThis.curve_bn128.terminate();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My intuition was to put this into the prove method.
Do you see tradeoff putting it in there?

@ananas-block
Copy link
Contributor

ananas-block commented Jul 6, 2023

@sergeytimoshin The test failure might not be related to your changes, since it is complaining about an account with insufficient rent.
I haven't seen this error in ci before let me investigate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants