mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-31 02:51:01 +00:00
Rococo: Build two versions of the wasm binary (#2229)
One for local networks with `fast-runtime` feature activated (1 minute sessions) and one without the feature activated that will be the default that runs with 1 hour long sessions.
This commit is contained in:
@@ -37,14 +37,15 @@ pub mod currency {
|
||||
|
||||
/// Time and blocks.
|
||||
pub mod time {
|
||||
use runtime_common::prod_or_fast;
|
||||
|
||||
use primitives::{BlockNumber, Moment};
|
||||
pub const MILLISECS_PER_BLOCK: Moment = 6000;
|
||||
pub const SLOT_DURATION: Moment = MILLISECS_PER_BLOCK;
|
||||
|
||||
frame_support::parameter_types! {
|
||||
pub storage EpochDurationInBlocks: BlockNumber = option_env!("ROCOCO_EPOCH_DURATION")
|
||||
.map(|s| s.parse().expect("`ROCOCO_EPOCH_DURATION` is not a valid `BlockNumber`"))
|
||||
.unwrap_or(1 * MINUTES);
|
||||
pub EpochDurationInBlocks: BlockNumber =
|
||||
prod_or_fast!(1 * HOURS, 1 * MINUTES, "ROCOCO_EPOCH_DURATION");
|
||||
}
|
||||
|
||||
// These time units are defined in number of blocks.
|
||||
|
||||
Reference in New Issue
Block a user