Reveal Phase

The Reveal Phase lasts for 1 day, after the end of the Commit Phase.

During the reveal phase votes are tallied and a winner is publicly updated upon each reveal. Invalid votes (empty ballots, ballots that are not revealed, ballots that attempt to cheat the voting system, and ballots for trustees that never submitted a commitment) are counted as ballots ranking the default proposal as the first choice, with all other proposals left unranked. A proposal that ties the current winner does not replace it; in other words, ties are broken by favoring the proposal revealed first.

Revealing a Vote

As discussed in the Commit Phase section, Trustees upload a keccak256 hash of three values, a seed, their address, and a votes array. In this section, the Trustees provide the seed and the votes used to generate the hash, and the protocol checks the commit to ensure they are the same. Revealing is managed with reveal(bytes32 _seed, Vote[] calldata _votes) function in the CurrencyGovernance.sol. The function takes the following inputs:

  • bytes32 _seed: the seed used to create the hash commit.

  • Vote[] calldata _votes: the submitted ballot to match to the hash commit. See the previous section on how to format this array.

When the generation increments, the supervisor function compute() is called and the winning policy is enacted.

Last updated