Skip to content

feat(DisputeKit): change RNG for governor only #24

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

Merged
merged 1 commit into from
Jan 20, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions contracts/src/arbitration/dispute-kits/DisputeKitClassic.sol
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ import "../../rng/RNG.sol";
* - a vote aggreation system: plurality,
* - an incentive system: equal split between coherent votes,
* - an appeal system: fund 2 choices only, vote on any choice.
* TODO:
* - phase management: Generating->Drawing->Resolving->Generating in coordination with KlerosCore to freeze staking.
*/
contract DisputeKitClassic is DisputeKit {
// ************************************* //
Expand Down Expand Up @@ -151,6 +153,14 @@ contract DisputeKitClassic is DisputeKit {
core = KlerosCore(_core);
}

/** @dev Changes the `_rng` storage variable.
* @param _rng The new value for the `RNGenerator` storage variable.
*/
function changeRandomNumberGenerator(RNG _rng) external onlyByGovernor {
rng = _rng;
// TODO: if current phase is generating, call rng.requestRN() for the next block
}

// ************************************* //
// * State Modifiers * //
// ************************************* //
Expand Down