-
Notifications
You must be signed in to change notification settings - Fork 15
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
feat(contracts): payout strategy #353
base: main
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
2386826
to
105f96b
Compare
105f96b
to
2ae0d51
Compare
2ae0d51
to
6639fb3
Compare
539d403
to
f8b6297
Compare
f8b6297
to
fa08127
Compare
fa08127
to
e00838c
Compare
e00838c
to
e207a61
Compare
e207a61
to
732f0c6
Compare
732f0c6
to
ba485ab
Compare
aa7ffce
to
a1bdfbf
Compare
a1bdfbf
to
bc627f3
Compare
bc627f3
to
be8ebb9
Compare
be8ebb9
to
8d6c909
Compare
8d6c909
to
3d79e37
Compare
3d79e37
to
5f22872
Compare
5f22872
to
5a3c534
Compare
5a3c534
to
a646b7d
Compare
a646b7d
to
55187fa
Compare
55187fa
to
085256a
Compare
085256a
to
c62e4f8
Compare
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 so much! just one comment but otherwise lgtm
/// @param voiceCreditsPerOptions The voice credit options received for recipient | ||
function getAllocatedAmounts( | ||
uint256[] calldata voiceCreditsPerOptions | ||
) public view afterTallying returns (uint256[] memory amounts) { |
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.
don't think there's need to have afterTallying here, when called by other functions they also have the same modifier.
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.
This is a public function so it can be used directly. And if there is no results it won't show the correct result and revert with no reason.
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.
ballots tallied not necessarily means that the results have been added (sure in our version with our scripts it does cause the scripts do both operations in once, but they are not necessarily done together, nor would be true in the case of multiple batches of results and the call made before the second batch is added). Either way not a problem, just a small suggestion
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.
So I'd keep this one. There is also a check if we don't have full results uploaded.
- [x] Use tally as payout strategy - [x] Add deposit/claim/withdraw functions - [x] Add tests - [x] Add pause for tally in poll deploy script - [x] Update deploy config - [x] Add tally initialization - [x] Add batch method for rewards calculation
c62e4f8
to
b028697
Compare
Next things to do:
Related to #263