Companion for Update Bounty Deposit (#11014) (#5183)

* update bounty deposit config

* fix

* update lockfile for {"substrate"}

Co-authored-by: parity-processbot <>
This commit is contained in:
Shawn Tabrizi
2022-03-25 11:09:32 -04:00
committed by GitHub
parent 7a61d75666
commit cbd6570c56
3 changed files with 193 additions and 183 deletions
+165 -163
View File
File diff suppressed because it is too large Load Diff
+14 -10
View File
@@ -746,12 +746,6 @@ parameter_types! {
pub const TipFindersFee: Percent = Percent::from_percent(20); pub const TipFindersFee: Percent = Percent::from_percent(20);
pub const TipReportDepositBase: Balance = 100 * CENTS; pub const TipReportDepositBase: Balance = 100 * CENTS;
pub const DataDepositPerByte: Balance = 1 * CENTS; pub const DataDepositPerByte: Balance = 1 * CENTS;
pub const BountyDepositBase: Balance = 100 * CENTS;
pub const BountyDepositPayoutDelay: BlockNumber = 4 * DAYS;
pub const BountyUpdatePeriod: BlockNumber = 90 * DAYS;
pub const MaximumReasonLength: u32 = 16384;
pub const BountyCuratorDeposit: Permill = Permill::from_percent(50);
pub const BountyValueMinimum: Balance = 200 * CENTS;
pub const MaxApprovals: u32 = 100; pub const MaxApprovals: u32 = 100;
pub const MaxAuthorities: u32 = 100_000; pub const MaxAuthorities: u32 = 100_000;
pub const MaxKeys: u32 = 10_000; pub const MaxKeys: u32 = 10_000;
@@ -782,11 +776,24 @@ impl pallet_treasury::Config for Runtime {
type SpendFunds = Bounties; type SpendFunds = Bounties;
} }
parameter_types! {
pub const BountyDepositBase: Balance = 100 * CENTS;
pub const BountyDepositPayoutDelay: BlockNumber = 4 * DAYS;
pub const BountyUpdatePeriod: BlockNumber = 90 * DAYS;
pub const MaximumReasonLength: u32 = 16384;
pub const CuratorDepositMultiplier: Permill = Permill::from_percent(50);
pub const CuratorDepositMin: Balance = 10 * CENTS;
pub const CuratorDepositMax: Balance = 500 * CENTS;
pub const BountyValueMinimum: Balance = 200 * CENTS;
}
impl pallet_bounties::Config for Runtime { impl pallet_bounties::Config for Runtime {
type BountyDepositBase = BountyDepositBase; type BountyDepositBase = BountyDepositBase;
type BountyDepositPayoutDelay = BountyDepositPayoutDelay; type BountyDepositPayoutDelay = BountyDepositPayoutDelay;
type BountyUpdatePeriod = BountyUpdatePeriod; type BountyUpdatePeriod = BountyUpdatePeriod;
type BountyCuratorDeposit = BountyCuratorDeposit; type CuratorDepositMultiplier = CuratorDepositMultiplier;
type CuratorDepositMin = CuratorDepositMin;
type CuratorDepositMax = CuratorDepositMax;
type BountyValueMinimum = BountyValueMinimum; type BountyValueMinimum = BountyValueMinimum;
type ChildBountyManager = ChildBounties; type ChildBountyManager = ChildBounties;
type DataDepositPerByte = DataDepositPerByte; type DataDepositPerByte = DataDepositPerByte;
@@ -798,15 +805,12 @@ impl pallet_bounties::Config for Runtime {
parameter_types! { parameter_types! {
pub const MaxActiveChildBountyCount: u32 = 100; pub const MaxActiveChildBountyCount: u32 = 100;
pub const ChildBountyValueMinimum: Balance = BountyValueMinimum::get() / 10; pub const ChildBountyValueMinimum: Balance = BountyValueMinimum::get() / 10;
// This will be 1% of the bounty value.
pub const ChildBountyCuratorDepositBase: Permill = Permill::from_percent(1);
} }
impl pallet_child_bounties::Config for Runtime { impl pallet_child_bounties::Config for Runtime {
type Event = Event; type Event = Event;
type MaxActiveChildBountyCount = MaxActiveChildBountyCount; type MaxActiveChildBountyCount = MaxActiveChildBountyCount;
type ChildBountyValueMinimum = ChildBountyValueMinimum; type ChildBountyValueMinimum = ChildBountyValueMinimum;
type ChildBountyCuratorDepositBase = ChildBountyCuratorDepositBase;
type WeightInfo = weights::pallet_child_bounties::WeightInfo<Runtime>; type WeightInfo = weights::pallet_child_bounties::WeightInfo<Runtime>;
} }
+14 -10
View File
@@ -778,12 +778,6 @@ parameter_types! {
pub const TipFindersFee: Percent = Percent::from_percent(20); pub const TipFindersFee: Percent = Percent::from_percent(20);
pub const TipReportDepositBase: Balance = 1 * DOLLARS; pub const TipReportDepositBase: Balance = 1 * DOLLARS;
pub const DataDepositPerByte: Balance = 1 * CENTS; pub const DataDepositPerByte: Balance = 1 * CENTS;
pub const BountyDepositBase: Balance = 1 * DOLLARS;
pub const BountyDepositPayoutDelay: BlockNumber = 8 * DAYS;
pub const BountyUpdatePeriod: BlockNumber = 90 * DAYS;
pub const MaximumReasonLength: u32 = 16384;
pub const BountyCuratorDeposit: Permill = Permill::from_percent(50);
pub const BountyValueMinimum: Balance = 10 * DOLLARS;
pub const MaxApprovals: u32 = 100; pub const MaxApprovals: u32 = 100;
pub const MaxAuthorities: u32 = 100_000; pub const MaxAuthorities: u32 = 100_000;
pub const MaxKeys: u32 = 10_000; pub const MaxKeys: u32 = 10_000;
@@ -814,12 +808,25 @@ impl pallet_treasury::Config for Runtime {
type WeightInfo = weights::pallet_treasury::WeightInfo<Runtime>; type WeightInfo = weights::pallet_treasury::WeightInfo<Runtime>;
} }
parameter_types! {
pub const BountyDepositBase: Balance = 1 * DOLLARS;
pub const BountyDepositPayoutDelay: BlockNumber = 8 * DAYS;
pub const BountyUpdatePeriod: BlockNumber = 90 * DAYS;
pub const MaximumReasonLength: u32 = 16384;
pub const CuratorDepositMultiplier: Permill = Permill::from_percent(50);
pub const CuratorDepositMin: Balance = 10 * DOLLARS;
pub const CuratorDepositMax: Balance = 200 * DOLLARS;
pub const BountyValueMinimum: Balance = 10 * DOLLARS;
}
impl pallet_bounties::Config for Runtime { impl pallet_bounties::Config for Runtime {
type Event = Event; type Event = Event;
type BountyDepositBase = BountyDepositBase; type BountyDepositBase = BountyDepositBase;
type BountyDepositPayoutDelay = BountyDepositPayoutDelay; type BountyDepositPayoutDelay = BountyDepositPayoutDelay;
type BountyUpdatePeriod = BountyUpdatePeriod; type BountyUpdatePeriod = BountyUpdatePeriod;
type BountyCuratorDeposit = BountyCuratorDeposit; type CuratorDepositMultiplier = CuratorDepositMultiplier;
type CuratorDepositMin = CuratorDepositMin;
type CuratorDepositMax = CuratorDepositMax;
type BountyValueMinimum = BountyValueMinimum; type BountyValueMinimum = BountyValueMinimum;
type ChildBountyManager = ChildBounties; type ChildBountyManager = ChildBounties;
type DataDepositPerByte = DataDepositPerByte; type DataDepositPerByte = DataDepositPerByte;
@@ -830,15 +837,12 @@ impl pallet_bounties::Config for Runtime {
parameter_types! { parameter_types! {
pub const MaxActiveChildBountyCount: u32 = 100; pub const MaxActiveChildBountyCount: u32 = 100;
pub const ChildBountyValueMinimum: Balance = BountyValueMinimum::get() / 10; pub const ChildBountyValueMinimum: Balance = BountyValueMinimum::get() / 10;
// This will be 1% of the bounty value.
pub const ChildBountyCuratorDepositBase: Permill = Permill::from_percent(1);
} }
impl pallet_child_bounties::Config for Runtime { impl pallet_child_bounties::Config for Runtime {
type Event = Event; type Event = Event;
type MaxActiveChildBountyCount = MaxActiveChildBountyCount; type MaxActiveChildBountyCount = MaxActiveChildBountyCount;
type ChildBountyValueMinimum = ChildBountyValueMinimum; type ChildBountyValueMinimum = ChildBountyValueMinimum;
type ChildBountyCuratorDepositBase = ChildBountyCuratorDepositBase;
type WeightInfo = weights::pallet_child_bounties::WeightInfo<Runtime>; type WeightInfo = weights::pallet_child_bounties::WeightInfo<Runtime>;
} }