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

Add verifyTallyResult, verifyPerVOSpentVoiceCredits, verifySpentVoiceCredits #835

Merged

Conversation

yuetloo
Copy link
Contributor

@yuetloo yuetloo commented Nov 22, 2023

This PR adds the functions to the new Tally contract as I think they were accidentally removed from code refactoring as they were available in v0.10 and v1.1 (incorrect implementation, see PR #742 )

Clrfund uses these functions to verify the tally results in the tally.json file on-chain as part of the round finalization and when recipients invoke the claimFunds function.

Note: I moved the standalone test deployPollWithRandomSigner.test.ts in the suites.test.ts as it was failing with nonce error caused by running the tests in parallel.

Run the integration test suites to test the new functions:

cd integrationTests
npm run test

Copy link

netlify bot commented Dec 7, 2023

Deploy Preview for maci-typedoc failed.

Name Link
🔨 Latest commit 8165968
🔍 Latest deploy log https://app.netlify.com/sites/maci-typedoc/deploys/65737660e40548000869f497

Copy link
Collaborator

@ctrlc03 ctrlc03 left a comment

Choose a reason for hiding this comment

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

Great stuff thank you very much for this PR!! just left a couple of comments here and there

crypto/ts/utils.ts Show resolved Hide resolved
contracts/contracts/Tally.sol Outdated Show resolved Hide resolved
contracts/contracts/Tally.sol Outdated Show resolved Hide resolved
contracts/contracts/Tally.sol Outdated Show resolved Hide resolved
contracts/contracts/Tally.sol Outdated Show resolved Hide resolved
cli/ts/utils/verifiers.ts Outdated Show resolved Hide resolved
crypto/ts/utils.ts Outdated Show resolved Hide resolved
cli/ts/commands/verify.ts Show resolved Hide resolved
cli/ts/commands/verify.ts Outdated Show resolved Hide resolved
cli/ts/commands/verify.ts Outdated Show resolved Hide resolved
@ctrlc03 ctrlc03 self-requested a review December 8, 2023 14:45
@yuetloo yuetloo force-pushed the fix/verify-tally-on-chain branch from cce6a6b to 8165968 Compare December 8, 2023 20:02
Copy link
Collaborator

@ctrlc03 ctrlc03 left a comment

Choose a reason for hiding this comment

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

Thanks for applying the changes, LGTM!

contracts/contracts/Tally.sol Show resolved Hide resolved
@ctrlc03 ctrlc03 merged commit 2ce6f5c into privacy-scaling-explorations:dev Dec 8, 2023
12 checks passed
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.

2 participants