-
Notifications
You must be signed in to change notification settings - Fork 1.6k
OpenGov improvements for Kusama #6372
Changes from 2 commits
6f18e65
5980e4f
18429a6
b294ffe
0ebf85c
a5b47d1
58d1360
e30ede4
e3b6d65
49c0169
3197402
b4e12b9
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -71,8 +71,8 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
pallet_referenda::TrackInfo { | ||
name: "root", | ||
max_deciding: 1, | ||
decision_deposit: 1_000 * GRAND, | ||
prepare_period: 3 * HOURS, | ||
decision_deposit: 100 * GRAND, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 3 * HOURS, | ||
min_enactment_period: 3 * HOURS, | ||
|
@@ -85,8 +85,8 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
pallet_referenda::TrackInfo { | ||
name: "whitelisted_caller", | ||
max_deciding: 10, | ||
decision_deposit: 10_000 * GRAND, | ||
prepare_period: 3 * HOURS, | ||
decision_deposit: 100 * GRAND, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. thank you for this. But doesn't this setup now mean that one can maliciously jam this track with just 10*100 GRAND, which is only 3.33k KSM. Or is there a "decision gate" requiring the whitlelisting to be done to enter deciding? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Updated |
||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 10 * MINUTES, | ||
min_enactment_period: 30 * MINUTES, | ||
|
@@ -100,7 +100,7 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "staking_admin", | ||
max_deciding: 10, | ||
decision_deposit: 5 * GRAND, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 3 * HOURS, | ||
min_enactment_period: 2 * DAYS, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Wonder why min_enactment_period of the staking admin track would be less than of the root? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Root is hugely dangerous, so we're being a bit more conservative on the enactment time. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I expressed it wrong, the root min_enactment_period less than staking_admin now. |
||
|
@@ -114,7 +114,7 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "treasurer", | ||
max_deciding: 10, | ||
decision_deposit: 5 * GRAND, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 3 * HOURS, | ||
min_enactment_period: 2 * DAYS, | ||
|
@@ -128,7 +128,7 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "lease_admin", | ||
max_deciding: 10, | ||
decision_deposit: 5 * GRAND, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 3 * HOURS, | ||
min_enactment_period: 2 * DAYS, | ||
|
@@ -142,7 +142,7 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "fellowship_admin", | ||
max_deciding: 10, | ||
decision_deposit: 5 * GRAND, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 3 * HOURS, | ||
min_enactment_period: 2 * DAYS, | ||
|
@@ -156,7 +156,7 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "general_admin", | ||
max_deciding: 10, | ||
decision_deposit: 5 * GRAND, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 3 * HOURS, | ||
min_enactment_period: 2 * DAYS, | ||
|
@@ -170,7 +170,7 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "auction_admin", | ||
max_deciding: 10, | ||
decision_deposit: 5 * GRAND, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 3 * HOURS, | ||
min_enactment_period: 2 * DAYS, | ||
|
@@ -184,7 +184,7 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "referendum_canceller", | ||
max_deciding: 1_000, | ||
decision_deposit: 50 * GRAND, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 3 * HOURS, | ||
min_enactment_period: 10 * MINUTES, | ||
|
@@ -198,7 +198,7 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "referendum_killer", | ||
max_deciding: 1_000, | ||
decision_deposit: 50 * GRAND, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 3 * HOURS, | ||
min_enactment_period: 10 * MINUTES, | ||
|
@@ -212,10 +212,10 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "small_tipper", | ||
max_deciding: 200, | ||
decision_deposit: 5 * QUID, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 3 * HOURS, | ||
min_enactment_period: 28 * DAYS, | ||
min_enactment_period: 24 * HOURS, | ||
min_approval: APP_SMALL_TIPPER, | ||
min_support: SUP_SMALL_TIPPER, | ||
}, | ||
|
@@ -226,10 +226,10 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "big_tipper", | ||
max_deciding: 100, | ||
decision_deposit: 50 * QUID, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 6 * HOURS, | ||
min_enactment_period: 28 * DAYS, | ||
min_enactment_period: 24 * HOURS, | ||
min_approval: APP_BIG_TIPPER, | ||
min_support: SUP_BIG_TIPPER, | ||
}, | ||
|
@@ -240,10 +240,10 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "small_spender", | ||
max_deciding: 50, | ||
decision_deposit: 500 * QUID, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 12 * HOURS, | ||
min_enactment_period: 28 * DAYS, | ||
min_enactment_period: 24 * HOURS, | ||
min_approval: APP_SMALL_SPENDER, | ||
min_support: SUP_SMALL_SPENDER, | ||
}, | ||
|
@@ -254,10 +254,10 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "medium_spender", | ||
max_deciding: 20, | ||
decision_deposit: 1_500 * QUID, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
confirm_period: 24 * HOURS, | ||
min_enactment_period: 28 * DAYS, | ||
min_enactment_period: 24 * HOURS, | ||
min_approval: APP_MEDIUM_SPENDER, | ||
min_support: SUP_MEDIUM_SPENDER, | ||
}, | ||
|
@@ -268,10 +268,10 @@ const TRACKS_DATA: [(u16, pallet_referenda::TrackInfo<Balance, BlockNumber>); 15 | |
name: "big_spender", | ||
max_deciding: 10, | ||
decision_deposit: 5 * GRAND, | ||
prepare_period: 4, | ||
prepare_period: 4 * HOURS, | ||
decision_period: 28 * DAYS, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. any chance we can set There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Reduced to 14 days throughout, with tippers at 7 days. The curves are designed to be safe. If a faster conclusion is desired by teams, then I think they really ought to be helping increase turnout for their proposal from token holders/voters. |
||
confirm_period: 48 * HOURS, | ||
min_enactment_period: 28 * DAYS, | ||
min_enactment_period: 24 * HOURS, | ||
min_approval: APP_BIG_SPENDER, | ||
min_support: SUP_BIG_SPENDER, | ||
}, | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -125,6 +125,9 @@ impl< | |
AllowDeath, | ||
) | ||
.is_ok(); | ||
if ok { | ||
Currency::reactivate(amount); | ||
} | ||
debug_assert!( | ||
ok, | ||
"`can_check_in` must have returned `true` immediately prior; qed" | ||
|
@@ -138,6 +141,7 @@ impl< | |
if let Some(amount) = Matcher::matches_fungible(what) { | ||
if let Some(checked_account) = CheckedAccount::get() { | ||
Currency::deposit_creating(&checked_account, amount); | ||
Currency::deactivate(amount); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. both currency calls, withdraw and deposit_creating return imbalance, can be used to determine the reactivate/deactivate amount There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. it should be equivalent. |
||
} | ||
} | ||
} | ||
|
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.
Wouldn't ReservedAmount from the Auctions pallet capture everything in crowdloans and self-funded bids?
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.
Self-funded bids can still be used in governance.
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.
Really? How?