-
Notifications
You must be signed in to change notification settings - Fork 11
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
Make Coordinator aware of transcript size #334
Conversation
Move some common test definitions to conftest.py
uint16 dkgSize, | ||
uint16 threshold | ||
) public pure returns (uint256) { | ||
return 40 + (dkgSize + 1) * BLS12381.G2_POINT_SIZE + threshold * BLS12381.G1_POINT_SIZE; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a nitpick but 40
is the only unnamed component of this calculation. Perhaps it can be assigned to a constant similar to the BLS point sizes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're right, but the thing is that I don't understand well enough where that 40 comes from. I mean, it's a fixed overhead that comes from rust serialization but I don't have a full explanation for it. I'll update this when I have more info.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎸 .
Did you also want to verify your updated Coordinator contract on lynx, with our updated verify script? 😉
TIMEOUT = 1000 | ||
MAX_DKG_SIZE = 31 | ||
FEE_RATE = 42 | ||
ERC20_SUPPLY = 10**24 | ||
DURATION = 48 * 60 * 60 | ||
ONE_DAY = 24 * 60 * 60 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this cleanup. We were repeating the RitualState enum and fixtures in a number of places.
Type of PR:
Required reviews:
What this does:
Issues fixed/closed:
Why it's needed:
Notes for reviewers:
postTranscript
TXs in testnet DKG rituals (2-of-3):8768 = (644-128)*16 + 128*4
, where644
is the calldata size for apostTranscript
TX in a 2-of-3 ritual)