Skip to content

Commit

Permalink
Eliminate experimental feature (#3654)
Browse files Browse the repository at this point in the history
Totally removes the `experimental` feature. Closes #3648.

---------

Co-authored-by: Bastian Köcher <git@kchr.de>
  • Loading branch information
s0me0ne-unkn0wn and bkchr committed Mar 17, 2024
1 parent d2a7100 commit 1f9505c
Show file tree
Hide file tree
Showing 41 changed files with 15 additions and 120 deletions.
2 changes: 0 additions & 2 deletions cumulus/pallets/collator-selection/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -77,5 +77,3 @@ try-runtime = [
"pallet-timestamp/try-runtime",
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]
1 change: 0 additions & 1 deletion cumulus/pallets/collator-selection/src/mock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,6 @@ impl pallet_aura::Config for Test {
type MaxAuthorities = ConstU32<100_000>;
type DisabledValidators = ();
type AllowMultipleBlocksPerSlot = ConstBool<false>;
#[cfg(feature = "experimental")]
type SlotDuration = pallet_aura::MinimumPeriodTimesTwo<Self>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -251,8 +251,6 @@ std = [
"xcm/std",
]

experimental = ["pallet-aura/experimental"]

# A feature that should be enabled when the runtime should be built for on-chain
# deployment. This will disable stuff that shouldn't be part of the on-chain wasm
# to make it smaller, like logging for example.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>;
}

Expand Down Expand Up @@ -723,7 +720,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -236,8 +236,6 @@ std = [
"xcm/std",
]

experimental = ["pallet-aura/experimental"]

# A feature that should be enabled when the runtime should be built for on-chain
# deployment. This will disable stuff that shouldn't be part of the on-chain wasm
# to make it smaller, like logging for example.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,10 +171,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>;
}

Expand Down Expand Up @@ -703,7 +700,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,6 @@ try-runtime = [
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]
fast-runtime = []

# A feature that should be enabled when the runtime should be built for on-chain
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -277,10 +277,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>;
}

Expand Down Expand Up @@ -445,7 +442,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -246,8 +246,6 @@ try-runtime = [
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]

# A feature that should be enabled when the runtime should be built for on-chain
# deployment. This will disable stuff that shouldn't be part of the on-chain wasm
# to make it smaller, like logging for example.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -251,10 +251,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>;
}

Expand Down Expand Up @@ -407,7 +404,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -232,8 +232,6 @@ std = [
"xcm/std",
]

experimental = ["pallet-aura/experimental"]

# A feature that should be enabled when the runtime should be built for on-chain
# deployment. This will disable stuff that shouldn't be part of the on-chain wasm
# to make it smaller, like logging for example.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -184,10 +184,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>;
}

Expand Down Expand Up @@ -483,7 +480,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -196,8 +196,6 @@ try-runtime = [
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]

# A feature that should be enabled when the runtime should be built for on-chain
# deployment. This will disable stuff that shouldn't be part of the on-chain wasm
# to make it smaller, like logging for example.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -193,10 +193,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = pallet_timestamp::weights::SubstrateWeight<Runtime>;
}

Expand Down Expand Up @@ -349,7 +346,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,4 @@ try-runtime = [
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]

fast-runtime = []
Original file line number Diff line number Diff line change
Expand Up @@ -206,10 +206,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>;
}

Expand Down Expand Up @@ -369,7 +366,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,4 @@ try-runtime = [
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]

fast-runtime = []
Original file line number Diff line number Diff line change
Expand Up @@ -206,10 +206,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>;
}

Expand Down Expand Up @@ -369,7 +366,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,6 @@ try-runtime = [
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]

# A feature that should be enabled when the runtime should be built for on-chain
# deployment. This will disable stuff that shouldn't be part of the on-chain wasm
# to make it smaller, like logging for example.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -221,10 +221,7 @@ impl cumulus_pallet_aura_ext::Config for Runtime {}
impl pallet_timestamp::Config for Runtime {
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>;
}

Expand All @@ -233,7 +230,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
2 changes: 0 additions & 2 deletions cumulus/parachains/runtimes/people/people-rococo/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -188,5 +188,3 @@ try-runtime = [
"polkadot-runtime-common/try-runtime",
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]
4 changes: 0 additions & 4 deletions cumulus/parachains/runtimes/people/people-rococo/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>;
}

Expand Down Expand Up @@ -337,7 +334,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
2 changes: 0 additions & 2 deletions cumulus/parachains/runtimes/people/people-westend/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -188,5 +188,3 @@ try-runtime = [
"polkadot-runtime-common/try-runtime",
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]
4 changes: 0 additions & 4 deletions cumulus/parachains/runtimes/people/people-westend/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>;
}

Expand Down Expand Up @@ -337,7 +334,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
2 changes: 0 additions & 2 deletions cumulus/parachains/runtimes/starters/seedling/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -79,5 +79,3 @@ std = [
"sp-version/std",
"substrate-wasm-builder",
]

experimental = ["pallet-aura/experimental"]
4 changes: 0 additions & 4 deletions cumulus/parachains/runtimes/starters/seedling/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -213,17 +213,13 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<false>;
#[cfg(feature = "experimental")]
type SlotDuration = pallet_aura::MinimumPeriodTimesTwo<Self>;
}

impl pallet_timestamp::Config for Runtime {
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ parachains_common::SLOT_DURATION / 2 }>;
type WeightInfo = ();
}

Expand Down
2 changes: 0 additions & 2 deletions cumulus/parachains/runtimes/starters/shell/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -99,5 +99,3 @@ try-runtime = [
"parachain-info/try-runtime",
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]
4 changes: 0 additions & 4 deletions cumulus/parachains/runtimes/starters/shell/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -241,17 +241,13 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<false>;
#[cfg(feature = "experimental")]
type SlotDuration = pallet_aura::MinimumPeriodTimesTwo<Self>;
}

impl pallet_timestamp::Config for Runtime {
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ parachains_common::SLOT_DURATION / 2 }>;
type WeightInfo = ();
}

Expand Down
2 changes: 0 additions & 2 deletions cumulus/parachains/runtimes/testing/penpal/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -191,5 +191,3 @@ try-runtime = [
"polkadot-runtime-common/try-runtime",
"sp-runtime/try-runtime",
]

experimental = ["pallet-aura/experimental"]
1 change: 0 additions & 1 deletion cumulus/parachains/runtimes/testing/penpal/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -582,7 +582,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<false>;
#[cfg(feature = "experimental")]
type SlotDuration = pallet_aura::MinimumPeriodTimesTwo<Self>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,5 +134,3 @@ runtime-benchmarks = [
"xcm-builder/runtime-benchmarks",
"xcm-executor/runtime-benchmarks",
]

experimental = ["pallet-aura/experimental"]
Original file line number Diff line number Diff line change
Expand Up @@ -228,10 +228,7 @@ impl pallet_timestamp::Config for Runtime {
/// A timestamp: milliseconds since the unix epoch.
type Moment = u64;
type OnTimestampSet = Aura;
#[cfg(feature = "experimental")]
type MinimumPeriod = ConstU64<0>;
#[cfg(not(feature = "experimental"))]
type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>;
type WeightInfo = ();
}

Expand Down Expand Up @@ -594,7 +591,6 @@ impl pallet_aura::Config for Runtime {
type DisabledValidators = ();
type MaxAuthorities = ConstU32<100_000>;
type AllowMultipleBlocksPerSlot = ConstBool<true>;
#[cfg(feature = "experimental")]
type SlotDuration = ConstU64<SLOT_DURATION>;
}

Expand Down
Loading

0 comments on commit 1f9505c

Please sign in to comment.