Skip to content
Snippets Groups Projects
Commit 2ae6ab0e authored by Alexander Popiak's avatar Alexander Popiak Committed by GitHub
Browse files

Update MILLISECS_PER_BLOCK comments (#7483)


* add doc comment to node template MILLISECS_PER_BLOCK

* add broken link comment

* update Babe block time link

Co-authored-by: default avatarAndré Silva <123550+andresilva@users.noreply.github.com>

Co-authored-by: default avatarAndré Silva <123550+andresilva@users.noreply.github.com>
parent ff6b603d
No related merge requests found
......@@ -102,6 +102,12 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
transaction_version: 1,
};
/// This determines the average expected block time that we are targetting.
/// Blocks will be produced at a minimum duration defined by `SLOT_DURATION`.
/// `SLOT_DURATION` is picked up by `pallet_timestamp` which is in turn picked
/// up by `pallet_aura` to implement `fn slot_duration()`.
///
/// Change this to adjust the block time.
pub const MILLISECS_PER_BLOCK: u64 = 6000;
pub const SLOT_DURATION: u64 = MILLISECS_PER_BLOCK;
......
......@@ -50,7 +50,7 @@ pub mod time {
/// always be assigned, in which case `MILLISECS_PER_BLOCK` and
/// `SLOT_DURATION` should have the same value.
///
/// <https://research.web3.foundation/en/latest/polkadot/BABE/Babe/#6-practical-results>
/// <https://research.web3.foundation/en/latest/polkadot/block-production/Babe.html#-6.-practical-results>
pub const MILLISECS_PER_BLOCK: Moment = 3000;
pub const SECS_PER_BLOCK: Moment = MILLISECS_PER_BLOCK / 1000;
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment