I want to use WEIGHT_PER_SECOND
in this code :
parameter_types! {
pub const BlockHashCount: BlockNumber = 2400;
pub const Version: RuntimeVersion = VERSION;
/// We allow for 2 seconds of compute with a 6 second average block time.
pub BlockWeights: frame_system::limits::BlockWeights = frame_system::limits::BlockWeights
::with_sensible_defaults(2 * WEIGHT_PER_SECOND, NORMAL_DISPATCH_RATIO);
pub BlockLength: frame_system::limits::BlockLength = frame_system::limits::BlockLength
::max_with_normal_ratio(5 * 1024 * 1024, NORMAL_DISPATCH_RATIO);
pub const SS58Prefix: u8 = 42;
}
and I use this code for import WEIGHT_PER_SECOND
:
pub use frame_support::{
traits::{
ConstU128, ConstU32, ConstU64, ConstBool,ConstU8, KeyOwnerProofSystem,Nothing, Randomness, StorageInfo,
},
weights::{
constants::{BlockExecutionWeight, ExtrinsicBaseWeight, RocksDbWeight, WEIGHT_PER_SECOND},
},
};
I used this part of code in previous versions of substrate but in this version I faced this problem.
What's the problem, and how can I solve it?