mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 17:31:03 +00:00
@@ -37,7 +37,7 @@ pub use self::runtime::logger_hook;
|
||||
|
||||
/// Export a dummy logger hook when the `runtime-metrics` feature is not enabled.
|
||||
#[cfg(not(feature = "runtime-metrics"))]
|
||||
pub fn logger_hook() -> impl FnOnce(&mut sc_cli::LoggerBuilder, &sc_service::Configuration) -> () {
|
||||
pub fn logger_hook() -> impl FnOnce(&mut sc_cli::LoggerBuilder, &sc_service::Configuration) {
|
||||
|_logger_builder, _config| {}
|
||||
}
|
||||
|
||||
|
||||
@@ -38,9 +38,10 @@ pub mod currency {
|
||||
/// Time and blocks.
|
||||
pub mod time {
|
||||
use primitives::v2::{BlockNumber, Moment};
|
||||
use runtime_common::prod_or_fast;
|
||||
pub const MILLISECS_PER_BLOCK: Moment = 6000;
|
||||
pub const SLOT_DURATION: Moment = MILLISECS_PER_BLOCK;
|
||||
pub const EPOCH_DURATION_IN_SLOTS: BlockNumber = 1 * HOURS;
|
||||
pub const EPOCH_DURATION_IN_SLOTS: BlockNumber = prod_or_fast!(1 * HOURS, 1 * MINUTES);
|
||||
|
||||
// These time units are defined in number of blocks.
|
||||
pub const MINUTES: BlockNumber = 60_000 / (MILLISECS_PER_BLOCK as BlockNumber);
|
||||
|
||||
@@ -40,9 +40,10 @@ pub mod currency {
|
||||
/// Time and blocks.
|
||||
pub mod time {
|
||||
use primitives::v2::{BlockNumber, Moment};
|
||||
use runtime_common::prod_or_fast;
|
||||
pub const MILLISECS_PER_BLOCK: Moment = 6000;
|
||||
pub const SLOT_DURATION: Moment = MILLISECS_PER_BLOCK;
|
||||
pub const EPOCH_DURATION_IN_SLOTS: BlockNumber = 4 * HOURS;
|
||||
pub const EPOCH_DURATION_IN_SLOTS: BlockNumber = prod_or_fast!(4 * HOURS, 1 * MINUTES);
|
||||
|
||||
// These time units are defined in number of blocks.
|
||||
pub const MINUTES: BlockNumber = 60_000 / (MILLISECS_PER_BLOCK as BlockNumber);
|
||||
|
||||
Reference in New Issue
Block a user