Skip to content

Commit

Permalink
fix(vara): Update MAXIMUM_BLOCK_WEIGHT to 1 sec (#3164)
Browse files Browse the repository at this point in the history
  • Loading branch information
ukint-vs authored Aug 24, 2023
1 parent 89b4188 commit 8c7b689
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions runtime/vara/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -164,9 +164,11 @@ const_assert!((WEIGHT_REF_TIME_PER_SECOND / 3).checked_mul(2).is_some());

/// We allow for 1/3 of block time for computations, with maximum proof size.
///
/// It's 2/3 sec for vara runtime with 2 second block duration.
const MAXIMUM_BLOCK_WEIGHT: Weight =
Weight::from_parts(WEIGHT_REF_TIME_PER_SECOND * 2 / 3, u64::MAX);
/// It's 3/3 sec for vara runtime with 3 second block duration.
const MAXIMUM_BLOCK_WEIGHT: Weight = Weight::from_parts(
WEIGHT_REF_TIME_PER_MILLIS * MILLISECS_PER_BLOCK / 3,
u64::MAX,
);

/// The version information used to identify this runtime when compiled natively.
#[cfg(feature = "std")]
Expand Down

0 comments on commit 8c7b689

Please sign in to comment.