diff --git a/dip-template/runtimes/dip-consumer/Cargo.toml b/dip-template/runtimes/dip-consumer/Cargo.toml index c474da6ec..e79acbb30 100644 --- a/dip-template/runtimes/dip-consumer/Cargo.toml +++ b/dip-template/runtimes/dip-consumer/Cargo.toml @@ -33,7 +33,7 @@ frame-executive = { workspace = true } frame-support = { workspace = true } frame-system = { workspace = true } frame-system-rpc-runtime-api = { workspace = true } -pallet-aura = { workspace = true } +pallet-aura = { workspace = true, features = ["experimental"] } pallet-authorship = { workspace = true } pallet-balances = { workspace = true } pallet-session = { workspace = true } diff --git a/dip-template/runtimes/dip-consumer/src/lib.rs b/dip-template/runtimes/dip-consumer/src/lib.rs index b12bd4b26..91a3af86f 100644 --- a/dip-template/runtimes/dip-consumer/src/lib.rs +++ b/dip-template/runtimes/dip-consumer/src/lib.rs @@ -367,6 +367,7 @@ impl pallet_aura::Config for Runtime { type AuthorityId = AuraId; type DisabledValidators = (); type MaxAuthorities = ConstU32<100_000>; + type SlotDuration = ConstU64; } impl cumulus_pallet_aura_ext::Config for Runtime {} diff --git a/dip-template/runtimes/dip-provider/Cargo.toml b/dip-template/runtimes/dip-provider/Cargo.toml index 8b0181b68..d3d28e601 100644 --- a/dip-template/runtimes/dip-provider/Cargo.toml +++ b/dip-template/runtimes/dip-provider/Cargo.toml @@ -33,7 +33,7 @@ frame-executive = { workspace = true } frame-support = { workspace = true } frame-system = { workspace = true } frame-system-rpc-runtime-api = { workspace = true } -pallet-aura = { workspace = true } +pallet-aura = { workspace = true, features = ["experimental"] } pallet-authorship = { workspace = true } pallet-balances = { workspace = true } pallet-session = { workspace = true } diff --git a/dip-template/runtimes/dip-provider/src/lib.rs b/dip-template/runtimes/dip-provider/src/lib.rs index c9a30efa8..c6e3ac944 100644 --- a/dip-template/runtimes/dip-provider/src/lib.rs +++ b/dip-template/runtimes/dip-provider/src/lib.rs @@ -368,6 +368,7 @@ impl pallet_aura::Config for Runtime { type AuthorityId = AuraId; type DisabledValidators = (); type MaxAuthorities = ConstU32<100_000>; + type SlotDuration = ConstU64; } impl cumulus_pallet_aura_ext::Config for Runtime {} diff --git a/integration-tests/emulated/Cargo.toml b/integration-tests/emulated/Cargo.toml index 212585bcb..6a21b6a6b 100644 --- a/integration-tests/emulated/Cargo.toml +++ b/integration-tests/emulated/Cargo.toml @@ -12,7 +12,7 @@ version = { workspace = true } [dependencies] asset-hub-rococo-emulated-chain = { workspace = true, default-features = true } -asset-hub-rococo-runtime = { workspace = true, default-features = true } +asset-hub-rococo-runtime = { workspace = true, default-features = true, features = ["experimental"] } attestation = { workspace = true, default-features = true } ctype = { workspace = true, default-features = true } cumulus-primitives-core = { workspace = true, default-features = true } diff --git a/nodes/parachain/src/service.rs b/nodes/parachain/src/service.rs index 9fb995cc0..0fb24c7bc 100644 --- a/nodes/parachain/src/service.rs +++ b/nodes/parachain/src/service.rs @@ -47,7 +47,7 @@ use substrate_prometheus_endpoint::Registry; use runtime_common::{AccountId, AuthorityId, Balance, BlockNumber, Hash, Nonce}; -pub const AUTHORING_DURATION: u64 = 500; +pub const AUTHORING_DURATION: u64 = 1500; pub const TASK_MANAGER_IDENTIFIER: &str = "aura"; type Header = sp_runtime::generic::Header; diff --git a/pallets/parachain-staking/Cargo.toml b/pallets/parachain-staking/Cargo.toml index cdf30bccf..df9d972d1 100644 --- a/pallets/parachain-staking/Cargo.toml +++ b/pallets/parachain-staking/Cargo.toml @@ -12,7 +12,7 @@ version = { workspace = true } [dev-dependencies] kilt-support = { workspace = true, features = ["mock", "try-runtime"] } -pallet-aura = { workspace = true, features = ["std"] } +pallet-aura = { workspace = true, features = ["experimental", "std"] } pallet-timestamp = { workspace = true, features = ["std"] } sp-consensus-aura = { workspace = true, features = ["std"] } sp-core = { workspace = true, features = ["std"] } diff --git a/pallets/parachain-staking/src/mock.rs b/pallets/parachain-staking/src/mock.rs index de30aa6ca..45fc24264 100644 --- a/pallets/parachain-staking/src/mock.rs +++ b/pallets/parachain-staking/src/mock.rs @@ -28,7 +28,7 @@ use frame_support::{ use frame_system::pallet_prelude::BlockNumberFor; use pallet_authorship::EventHandler; use sp_consensus_aura::sr25519::AuthorityId; -use sp_core::{ConstBool, H256}; +use sp_core::{ConstBool, ConstU64, H256}; use sp_runtime::{ impl_opaque_keys, testing::UintAuthorityId, @@ -120,6 +120,7 @@ impl pallet_aura::Config for Test { type DisabledValidators = (); type MaxAuthorities = MaxCollatorCandidates; type AllowMultipleBlocksPerSlot = ConstBool; + type SlotDuration = ConstU64<2>; } impl pallet_authorship::Config for Test { diff --git a/runtimes/kestrel/Cargo.toml b/runtimes/kestrel/Cargo.toml index b3906fb6a..d93fcc503 100644 --- a/runtimes/kestrel/Cargo.toml +++ b/runtimes/kestrel/Cargo.toml @@ -42,7 +42,7 @@ pallet-transaction-payment-rpc-runtime-api = { workspace = true } frame-executive = { workspace = true } frame-support = { workspace = true } frame-system = { workspace = true } -pallet-aura = { workspace = true } +pallet-aura = { workspace = true, features = ["experimental"] } pallet-authorship = { workspace = true } pallet-balances = { workspace = true } pallet-grandpa = { workspace = true } diff --git a/runtimes/kestrel/src/lib.rs b/runtimes/kestrel/src/lib.rs index 86270ad67..ad9f39631 100644 --- a/runtimes/kestrel/src/lib.rs +++ b/runtimes/kestrel/src/lib.rs @@ -209,6 +209,7 @@ impl pallet_aura::Config for Runtime { type DisabledValidators = (); type MaxAuthorities = MaxAuthorities; type AllowMultipleBlocksPerSlot = ConstBool; + type SlotDuration = ConstU64<1000>; } impl pallet_grandpa::Config for Runtime { diff --git a/runtimes/peregrine/Cargo.toml b/runtimes/peregrine/Cargo.toml index 66f1f9879..f8b46c79b 100644 --- a/runtimes/peregrine/Cargo.toml +++ b/runtimes/peregrine/Cargo.toml @@ -70,7 +70,7 @@ frame-executive = { workspace = true } frame-support = { workspace = true } frame-system = { workspace = true } pallet-assets = { workspace = true } -pallet-aura = { workspace = true } +pallet-aura = { workspace = true, features = ["experimental"] } pallet-authorship = { workspace = true } pallet-balances = { workspace = true } pallet-collective = { workspace = true } diff --git a/runtimes/peregrine/src/lib.rs b/runtimes/peregrine/src/lib.rs index 71a50fab5..17a1e966e 100644 --- a/runtimes/peregrine/src/lib.rs +++ b/runtimes/peregrine/src/lib.rs @@ -42,7 +42,7 @@ use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot, EnsureSigned}; use pallet_asset_switch::xcm::{AccountId32ToAccountId32JunctionConverter, MatchesSwitchPairXcmFeeFungibleAsset}; use parity_scale_codec::{Decode, Encode, MaxEncodedLen}; use sp_api::impl_runtime_apis; -use sp_core::{ConstBool, OpaqueMetadata}; +use sp_core::{ConstBool, ConstU64, OpaqueMetadata}; use sp_runtime::{ create_runtime_str, generic, impl_opaque_keys, traits::{AccountIdLookup, BlakeTwo256, Block as BlockT, ConvertInto, OpaqueKeys}, @@ -295,6 +295,7 @@ impl pallet_aura::Config for Runtime { type DisabledValidators = (); type MaxAuthorities = MaxAuthorities; type AllowMultipleBlocksPerSlot = ConstBool; + type SlotDuration = ConstU64; } parameter_types! { diff --git a/runtimes/spiritnet/Cargo.toml b/runtimes/spiritnet/Cargo.toml index 4716c6c83..24c4ef6a8 100644 --- a/runtimes/spiritnet/Cargo.toml +++ b/runtimes/spiritnet/Cargo.toml @@ -70,7 +70,7 @@ frame-executive = { workspace = true } frame-support = { workspace = true } frame-system = { workspace = true } pallet-assets = { workspace = true } -pallet-aura = { workspace = true } +pallet-aura = { workspace = true, features = ["experimental"] } pallet-authorship = { workspace = true } pallet-balances = { workspace = true } pallet-collective = { workspace = true } diff --git a/runtimes/spiritnet/src/lib.rs b/runtimes/spiritnet/src/lib.rs index 71e3c86b9..ae0f32c63 100644 --- a/runtimes/spiritnet/src/lib.rs +++ b/runtimes/spiritnet/src/lib.rs @@ -42,7 +42,7 @@ use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot, EnsureSigned}; use pallet_asset_switch::xcm::{AccountId32ToAccountId32JunctionConverter, MatchesSwitchPairXcmFeeFungibleAsset}; use parity_scale_codec::{Decode, Encode, MaxEncodedLen}; use sp_api::impl_runtime_apis; -use sp_core::{ConstBool, OpaqueMetadata}; +use sp_core::{ConstBool, ConstU64, OpaqueMetadata}; use sp_runtime::{ create_runtime_str, generic, impl_opaque_keys, traits::{AccountIdLookup, BlakeTwo256, Block as BlockT, ConvertInto, OpaqueKeys}, @@ -288,6 +288,7 @@ impl pallet_aura::Config for Runtime { type DisabledValidators = (); type MaxAuthorities = MaxAuthorities; type AllowMultipleBlocksPerSlot = ConstBool; + type SlotDuration = ConstU64; } parameter_types! {