fix session length of Rococo and Wococo (#1304)

This commit is contained in:
Svyatoslav Nikolsky
2022-02-01 11:05:03 +03:00
committed by Bastian Köcher
parent 01ee74c949
commit e190c35c95
4 changed files with 31 additions and 8 deletions
+8 -3
View File
@@ -25,13 +25,18 @@ use sp_std::prelude::*;
pub use bp_polkadot_core::*;
// Rococo runtime = Wococo runtime
pub use bp_rococo::{
WeightToFee, EXISTENTIAL_DEPOSIT, PAY_INBOUND_DISPATCH_FEE_WEIGHT, SESSION_LENGTH, VERSION,
};
pub use bp_rococo::{WeightToFee, EXISTENTIAL_DEPOSIT, PAY_INBOUND_DISPATCH_FEE_WEIGHT, VERSION};
/// Wococo Chain
pub type Wococo = PolkadotLike;
/// The target length of a session (how often authorities change) on Wococo measured in of number
/// of blocks.
///
/// Note that since this is a target sessions may change before/after this time depending on network
/// conditions.
pub const SESSION_LENGTH: BlockNumber = 1 * time_units::MINUTES;
// We use this to get the account on Wococo (target) which is derived from Rococo's (source)
// account.
pub fn derive_account_from_rococo_id(id: bp_runtime::SourceAccount<AccountId>) -> AccountId {