Skip to content
Snippets Groups Projects
Commit fec47e37 authored by Éloïs's avatar Éloïs
Browse files

fix(weights): use SubstrateWeight for all substrate pallets that have

parent dda527e4
No related branches found
No related tags found
1 merge request!47Set manually all weights for ğdev
...@@ -69,7 +69,7 @@ macro_rules! pallets_config { ...@@ -69,7 +69,7 @@ macro_rules! pallets_config {
/// The data to be stored in an account. /// The data to be stored in an account.
type AccountData = pallet_duniter_account::AccountData<Balance>; type AccountData = pallet_duniter_account::AccountData<Balance>;
/// Weight information for the extrinsics of this pallet. /// Weight information for the extrinsics of this pallet.
type SystemWeightInfo = (); type SystemWeightInfo = frame_system::weights::SubstrateWeight<Runtime>;
/// This is used as an identifier of the chain. 42 is the generic substrate prefix. /// This is used as an identifier of the chain. 42 is the generic substrate prefix.
type SS58Prefix = SS58Prefix; type SS58Prefix = SS58Prefix;
/// The set code logic, just the default since we're not a parachain. /// The set code logic, just the default since we're not a parachain.
...@@ -142,7 +142,7 @@ macro_rules! pallets_config { ...@@ -142,7 +142,7 @@ macro_rules! pallets_config {
type Moment = u64; type Moment = u64;
type OnTimestampSet = Babe; type OnTimestampSet = Babe;
type MinimumPeriod = MinimumPeriod; type MinimumPeriod = MinimumPeriod;
type WeightInfo = (); type WeightInfo = pallet_timestamp::weights::SubstrateWeight<Runtime>;
} }
// MONEY MANAGEMENT // // MONEY MANAGEMENT //
...@@ -158,7 +158,7 @@ macro_rules! pallets_config { ...@@ -158,7 +158,7 @@ macro_rules! pallets_config {
type DustRemoval = (); type DustRemoval = ();
type ExistentialDeposit = ExistentialDeposit; type ExistentialDeposit = ExistentialDeposit;
type AccountStore = Account; type AccountStore = Account;
type WeightInfo = common_runtime::weights::pallet_balances::WeightInfo<Runtime>; type WeightInfo = pallet_balances::weights::SubstrateWeight<Runtime>;
} }
pub struct HandleFees; pub struct HandleFees;
...@@ -211,7 +211,7 @@ macro_rules! pallets_config { ...@@ -211,7 +211,7 @@ macro_rules! pallets_config {
type NextSessionRotation = Babe; type NextSessionRotation = Babe;
type ReportUnresponsiveness = Offences; type ReportUnresponsiveness = Offences;
type UnsignedPriority = ImOnlineUnsignedPriority; type UnsignedPriority = ImOnlineUnsignedPriority;
type WeightInfo = (); type WeightInfo = pallet_im_online::weights::SubstrateWeight<Runtime>;
type MaxKeys = MaxAuthorities; type MaxKeys = MaxAuthorities;
type MaxPeerInHeartbeats = MaxPeerInHeartbeats; type MaxPeerInHeartbeats = MaxPeerInHeartbeats;
type MaxPeerDataEncodingSize = MaxPeerDataEncodingSize; type MaxPeerDataEncodingSize = MaxPeerDataEncodingSize;
...@@ -230,7 +230,7 @@ macro_rules! pallets_config { ...@@ -230,7 +230,7 @@ macro_rules! pallets_config {
type SessionManager = pallet_session::historical::NoteHistoricalRoot<Self, AuthorityMembers>; type SessionManager = pallet_session::historical::NoteHistoricalRoot<Self, AuthorityMembers>;
type SessionHandler = <opaque::SessionKeys as OpaqueKeys>::KeyTypeIdProviders; type SessionHandler = <opaque::SessionKeys as OpaqueKeys>::KeyTypeIdProviders;
type Keys = opaque::SessionKeys; type Keys = opaque::SessionKeys;
type WeightInfo = (); type WeightInfo = pallet_session::weights::SubstrateWeight<Runtime>;
} }
impl pallet_session::historical::Config for Runtime { impl pallet_session::historical::Config for Runtime {
type FullIdentification = ValidatorFullIdentification; type FullIdentification = ValidatorFullIdentification;
...@@ -464,7 +464,7 @@ macro_rules! pallets_config { ...@@ -464,7 +464,7 @@ macro_rules! pallets_config {
type MaxMembers = frame_support::pallet_prelude::ConstU32<1_000>; type MaxMembers = frame_support::pallet_prelude::ConstU32<1_000>;
type MembersStorage = SmithMembersStorage; type MembersStorage = SmithMembersStorage;
type DefaultVote = SmithMembersDefaultVote; type DefaultVote = SmithMembersDefaultVote;
type WeightInfo = (); type WeightInfo = pallet_collective::weights::SubstrateWeight<Runtime>;
} }
}; };
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment