Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

companion for substrate #13237 #6626

Merged
merged 4 commits into from
Jan 30, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
9 changes: 9 additions & 0 deletions runtime/kusama/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -726,6 +726,10 @@ impl pallet_im_online::Config for Runtime {
type MaxPeerDataEncodingSize = MaxPeerDataEncodingSize;
}

parameter_types! {
pub MaxSetIdSessionEntries: u32 = BondingDuration::get() * SessionsPerEra::get();
}

impl pallet_grandpa::Config for Runtime {
type RuntimeEvent = RuntimeEvent;

Expand All @@ -747,6 +751,7 @@ impl pallet_grandpa::Config for Runtime {

type WeightInfo = ();
type MaxAuthorities = MaxAuthorities;
type MaxSetIdSessionEntries = MaxSetIdSessionEntries;
}

/// Submits transaction with the node's public and signature type. Adheres to the signed extension
Expand Down Expand Up @@ -1502,6 +1507,10 @@ pub type Migrations = (
// "Use 2D weights in XCM v3" <https://github.com/paritytech/polkadot/pull/6134>
pallet_xcm::migration::v1::MigrateToV1<Runtime>,
parachains_ump::migration::v1::MigrateToV1<Runtime>,
// Remove stale entries in the set id -> session index storage map (after
// this release they will be properly pruned after the bonding duration has
// elapsed)
pallet_grandpa::migrations::CleanupSetIdSessionMap<Runtime>,
);

/// Unchecked extrinsic type as expected by this runtime.
Expand Down
9 changes: 9 additions & 0 deletions runtime/polkadot/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -938,6 +938,10 @@ impl pallet_im_online::Config for Runtime {
type MaxPeerDataEncodingSize = MaxPeerDataEncodingSize;
}

parameter_types! {
pub MaxSetIdSessionEntries: u32 = BondingDuration::get() * SessionsPerEra::get();
}

impl pallet_grandpa::Config for Runtime {
type RuntimeEvent = RuntimeEvent;

Expand All @@ -959,6 +963,7 @@ impl pallet_grandpa::Config for Runtime {

type WeightInfo = ();
type MaxAuthorities = MaxAuthorities;
type MaxSetIdSessionEntries = MaxSetIdSessionEntries;
}

/// Submits a transaction with the node's public and signature type. Adheres to the signed extension
Expand Down Expand Up @@ -1613,6 +1618,10 @@ pub type Migrations = (
// "Use 2D weights in XCM v3" <https://github.com/paritytech/polkadot/pull/6134>
pallet_xcm::migration::v1::MigrateToV1<Runtime>,
parachains_ump::migration::v1::MigrateToV1<Runtime>,
// Remove stale entries in the set id -> session index storage map (after
// this release they will be properly pruned after the bonding duration has
// elapsed)
pallet_grandpa::migrations::CleanupSetIdSessionMap<Runtime>,
);

/// Unchecked extrinsic type as expected by this runtime.
Expand Down
9 changes: 9 additions & 0 deletions runtime/rococo/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -660,6 +660,10 @@ impl pallet_im_online::Config for Runtime {
type MaxPeerDataEncodingSize = MaxPeerDataEncodingSize;
}

parameter_types! {
pub const MaxSetIdSessionEntries: u32 = BondingDuration::get() * SessionsPerEra::get();
}

impl pallet_grandpa::Config for Runtime {
type RuntimeEvent = RuntimeEvent;

Expand All @@ -681,6 +685,7 @@ impl pallet_grandpa::Config for Runtime {

type WeightInfo = ();
type MaxAuthorities = MaxAuthorities;
type MaxSetIdSessionEntries = MaxSetIdSessionEntries;
}

/// Submits a transaction with the node's public and signature type. Adheres to the signed extension
Expand Down Expand Up @@ -1495,6 +1500,10 @@ pub type Migrations = (
// "Use 2D weights in XCM v3" <https://github.com/paritytech/polkadot/pull/6134>
pallet_xcm::migration::v1::MigrateToV1<Runtime>,
parachains_ump::migration::v1::MigrateToV1<Runtime>,
// Remove stale entries in the set id -> session index storage map (after
// this release they will be properly pruned after the bonding duration has
// elapsed)
pallet_grandpa::migrations::CleanupSetIdSessionMap<Runtime>,
);

/// Executive: handles dispatch to the various modules.
Expand Down
9 changes: 9 additions & 0 deletions runtime/westend/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -571,6 +571,10 @@ impl pallet_im_online::Config for Runtime {
type MaxPeerDataEncodingSize = MaxPeerDataEncodingSize;
}

parameter_types! {
pub const MaxSetIdSessionEntries: u32 = BondingDuration::get() * SessionsPerEra::get();
}

impl pallet_grandpa::Config for Runtime {
type RuntimeEvent = RuntimeEvent;

Expand All @@ -592,6 +596,7 @@ impl pallet_grandpa::Config for Runtime {

type WeightInfo = ();
type MaxAuthorities = MaxAuthorities;
type MaxSetIdSessionEntries = MaxSetIdSessionEntries;
}

/// Submits a transaction with the node's public and signature type. Adheres to the signed extension
Expand Down Expand Up @@ -1250,6 +1255,10 @@ pub type Migrations = (
// "Use 2D weights in XCM v3" <https://github.com/paritytech/polkadot/pull/6134>
pallet_xcm::migration::v1::MigrateToV1<Runtime>,
parachains_ump::migration::v1::MigrateToV1<Runtime>,
// Remove stale entries in the set id -> session index storage map (after
// this release they will be properly pruned after the bonding duration has
// elapsed)
pallet_grandpa::migrations::CleanupSetIdSessionMap<Runtime>,
);

/// Unchecked extrinsic type as expected by this runtime.
Expand Down