Skip to content

generateProof workers won't exit #579

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

Closed
pooryamoh opened this issue Jan 23, 2024 · 1 comment
Closed

generateProof workers won't exit #579

pooryamoh opened this issue Jan 23, 2024 · 1 comment
Labels
bug 🐛 Something isn't working duplicate ‼️ This issue or pull request already exists

Comments

@pooryamoh
Copy link

Describe the bug
Wrote simple test code, for generating proof off-chain, after generating proof code won't exit and stop

To Reproduce
My Code:

const cljs = require("circomlibjs");
const { Identity } = require("@semaphore-protocol/identity");
const { Group } = require("@semaphore-protocol/group");
const {
  generateProof,
  verifyProof,
  calculateNullifierHash,
} = require("@semaphore-protocol/proof");

async function main() {
  const identity = new Identity("secret");
  const groupId = 1;
  const externalNullifier = 1212;
  const signal = 1;

  const group = new Group(groupId, 17);

  group.addMember(identity.commitment);

  const fullProof = await generateProof(
    identity,
    group,
    externalNullifier,
    signal,
    {
      zkeyFilePath: "./semaphore.zkey",
      wasmFilePath: "./semaphore.wasm",
    }
  );
  console.log(fullProof);
}
main();

Expected behavior
Logging fullProof and exit.

Screenshots
image

Technologies (please complete the following information):

  • Node.js v18.12.1
  • NPM 9.6.2
  • @semaphore-protocol/contracts 3.15.2
  • @semaphore-protocol/group 3.15.2
  • @semaphore-protocol/identity 3.15.2
  • @semaphore-protocol/proof 3.15.2
  • OS windows 11
@pooryamoh pooryamoh added the bug 🐛 Something isn't working label Jan 23, 2024
@vplasencia
Copy link
Member

Hey @pooryamoh!

Here is more context about the issue you have: #318

A temporal solution could be to do something like this:

main().finally(() => process.exit());

@cedoor cedoor added the duplicate ‼️ This issue or pull request already exists label Jan 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something isn't working duplicate ‼️ This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

3 participants