-
Notifications
You must be signed in to change notification settings - Fork 37
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
[300 SigmaUSD] Vote for update(pool) command #26
Comments
I will work on this. |
Hi @greenhat I have a question about this issue: Should the owner of the ballot token have their group element stored in the oracle config? Seems like it since we will need to implement transfer ballot token.
What do you reckon? Thanks. |
I think it's ok to store it in the config. Scanning for it seems way more complex. Let's try a simple solution first. :) |
There is an updated (with v2.0a changes) version of the EIP - ergoplatform/eips#41 |
Got it, thanks! |
I'm almost done with this issue but I ran into a problem with the case where we're spending an existing ballot box. I got the following error: I tracked it down and the problem originates in this line of the contract. Now I believe we need to amend the contract because for the So I amended the contract by removing the line with val update = INPUTS.size > 1 &&
INPUTS(1).tokens.size > 0 &&
INPUTS(1).tokens(0)._1 == updateNFT && // can only update when update box is the 2nd input
output.R4[GroupElement].get == selfPubKey && // public key is preserved
output.value >= SELF.value && // value preserved or increased
! (output.R5[Any].isDefined) // no more registers; prevents box from being reused as a valid vote Then the test passes (playground link) Am I doing this correctly? |
@kettlebell Good call! I agree. |
The bounty is sent. Thank you! |
Should be done after #45 is merged.
To vote for the pool box update as per https://github.com/ergoplatform/eips/blob/bd7a6098db78d67ac2ca9ada4c09bfe709d5ac03/eip-0023.md#vote-for-update (with updates introduced in v2.0a, e.g reward tokens were moved from the refresh box to the pool box) add a new command line option
--vote-update-pool
with the following parameters:If the ballot token is locked in the existing ballot box (i.e. output of the previous update tx) it should be spent to create the new ballot box.
The text was updated successfully, but these errors were encountered: