where
- Suffix: TransactionExtensionSchema,
+ Suffix: SignedExtensionSchema,
{
fn from_params(
spec_version: u32,
@@ -326,9 +321,9 @@ where
genesis_hash: Hash,
nonce: Nonce,
tip: Balance,
- extra: (Suffix::Payload, Suffix::Implicit),
+ extra: (Suffix::Payload, Suffix::AdditionalSigned),
) -> Self {
- GenericTransactionExtension::new(
+ GenericSignedExtension::new(
(
(
(), // non-zero sender
@@ -370,7 +365,7 @@ where
}
/// Signed extension that is used by most chains.
-pub type CommonTransactionExtension = SuffixedCommonTransactionExtension<()>;
+pub type CommonSignedExtension = SuffixedCommonSignedExtension<()>;
#[cfg(test)]
mod tests {
diff --git a/bridges/primitives/runtime/src/extensions.rs b/bridges/primitives/runtime/src/extensions.rs
index a31e7b5bb47a64ec2333bbaba3e9c520aa53ef5a..d896bc92efffc4e8fcb427ffa7057dece6f17241 100644
--- a/bridges/primitives/runtime/src/extensions.rs
+++ b/bridges/primitives/runtime/src/extensions.rs
@@ -20,138 +20,135 @@ use codec::{Compact, Decode, Encode};
use impl_trait_for_tuples::impl_for_tuples;
use scale_info::{StaticTypeInfo, TypeInfo};
use sp_runtime::{
- impl_tx_ext_default,
- traits::{Dispatchable, TransactionExtension, TransactionExtensionBase},
+ traits::{DispatchInfoOf, SignedExtension},
transaction_validity::TransactionValidityError,
};
use sp_std::{fmt::Debug, marker::PhantomData};
-/// Trait that describes some properties of a `TransactionExtension` that are needed in order to
-/// send a transaction to the chain.
-pub trait TransactionExtensionSchema:
- Encode + Decode + Debug + Eq + Clone + StaticTypeInfo
-{
+/// Trait that describes some properties of a `SignedExtension` that are needed in order to send a
+/// transaction to the chain.
+pub trait SignedExtensionSchema: Encode + Decode + Debug + Eq + Clone + StaticTypeInfo {
/// A type of the data encoded as part of the transaction.
type Payload: Encode + Decode + Debug + Eq + Clone + StaticTypeInfo;
/// Parameters which are part of the payload used to produce transaction signature,
/// but don't end up in the transaction itself (i.e. inherent part of the runtime).
- type Implicit: Encode + Decode + Debug + Eq + Clone + StaticTypeInfo;
+ type AdditionalSigned: Encode + Debug + Eq + Clone + StaticTypeInfo;
}
-impl TransactionExtensionSchema for () {
+impl SignedExtensionSchema for () {
type Payload = ();
- type Implicit = ();
+ type AdditionalSigned = ();
}
-/// An implementation of `TransactionExtensionSchema` using generic params.
+/// An implementation of `SignedExtensionSchema` using generic params.
#[derive(Encode, Decode, Clone, Debug, PartialEq, Eq, TypeInfo)]
-pub struct GenericTransactionExtensionSchema(PhantomData<(P, S)>);
+pub struct GenericSignedExtensionSchema
(PhantomData<(P, S)>);
-impl
TransactionExtensionSchema for GenericTransactionExtensionSchema
+impl
SignedExtensionSchema for GenericSignedExtensionSchema
where
P: Encode + Decode + Debug + Eq + Clone + StaticTypeInfo,
- S: Encode + Decode + Debug + Eq + Clone + StaticTypeInfo,
+ S: Encode + Debug + Eq + Clone + StaticTypeInfo,
{
type Payload = P;
- type Implicit = S;
+ type AdditionalSigned = S;
}
-/// The `TransactionExtensionSchema` for `frame_system::CheckNonZeroSender`.
-pub type CheckNonZeroSender = GenericTransactionExtensionSchema<(), ()>;
+/// The `SignedExtensionSchema` for `frame_system::CheckNonZeroSender`.
+pub type CheckNonZeroSender = GenericSignedExtensionSchema<(), ()>;
-/// The `TransactionExtensionSchema` for `frame_system::CheckSpecVersion`.
-pub type CheckSpecVersion = GenericTransactionExtensionSchema<(), u32>;
+/// The `SignedExtensionSchema` for `frame_system::CheckSpecVersion`.
+pub type CheckSpecVersion = GenericSignedExtensionSchema<(), u32>;
-/// The `TransactionExtensionSchema` for `frame_system::CheckTxVersion`.
-pub type CheckTxVersion = GenericTransactionExtensionSchema<(), u32>;
+/// The `SignedExtensionSchema` for `frame_system::CheckTxVersion`.
+pub type CheckTxVersion = GenericSignedExtensionSchema<(), u32>;
-/// The `TransactionExtensionSchema` for `frame_system::CheckGenesis`.
-pub type CheckGenesis = GenericTransactionExtensionSchema<(), Hash>;
+/// The `SignedExtensionSchema` for `frame_system::CheckGenesis`.
+pub type CheckGenesis = GenericSignedExtensionSchema<(), Hash>;
-/// The `TransactionExtensionSchema` for `frame_system::CheckEra`.
-pub type CheckEra = GenericTransactionExtensionSchema;
+/// The `SignedExtensionSchema` for `frame_system::CheckEra`.
+pub type CheckEra = GenericSignedExtensionSchema;
-/// The `TransactionExtensionSchema` for `frame_system::CheckNonce`.
-pub type CheckNonce = GenericTransactionExtensionSchema, ()>;
+/// The `SignedExtensionSchema` for `frame_system::CheckNonce`.
+pub type CheckNonce = GenericSignedExtensionSchema, ()>;
-/// The `TransactionExtensionSchema` for `frame_system::CheckWeight`.
-pub type CheckWeight = GenericTransactionExtensionSchema<(), ()>;
+/// The `SignedExtensionSchema` for `frame_system::CheckWeight`.
+pub type CheckWeight = GenericSignedExtensionSchema<(), ()>;
-/// The `TransactionExtensionSchema` for `pallet_transaction_payment::ChargeTransactionPayment`.
-pub type ChargeTransactionPayment =
- GenericTransactionExtensionSchema, ()>;
+/// The `SignedExtensionSchema` for `pallet_transaction_payment::ChargeTransactionPayment`.
+pub type ChargeTransactionPayment = GenericSignedExtensionSchema, ()>;
-/// The `TransactionExtensionSchema` for `polkadot-runtime-common::PrevalidateAttests`.
-pub type PrevalidateAttests = GenericTransactionExtensionSchema<(), ()>;
+/// The `SignedExtensionSchema` for `polkadot-runtime-common::PrevalidateAttests`.
+pub type PrevalidateAttests = GenericSignedExtensionSchema<(), ()>;
-/// The `TransactionExtensionSchema` for `BridgeRejectObsoleteHeadersAndMessages`.
-pub type BridgeRejectObsoleteHeadersAndMessages = GenericTransactionExtensionSchema<(), ()>;
+/// The `SignedExtensionSchema` for `BridgeRejectObsoleteHeadersAndMessages`.
+pub type BridgeRejectObsoleteHeadersAndMessages = GenericSignedExtensionSchema<(), ()>;
-/// The `TransactionExtensionSchema` for `RefundBridgedParachainMessages`.
+/// The `SignedExtensionSchema` for `RefundBridgedParachainMessages`.
/// This schema is dedicated for `RefundBridgedParachainMessages` signed extension as
/// wildcard/placeholder, which relies on the scale encoding for `()` or `((), ())`, or `((), (),
/// ())` is the same. So runtime can contains any kind of tuple:
/// `(BridgeRefundBridgeHubRococoMessages)`
/// `(BridgeRefundBridgeHubRococoMessages, BridgeRefundBridgeHubWestendMessages)`
/// `(BridgeRefundParachainMessages1, ..., BridgeRefundParachainMessagesN)`
-pub type RefundBridgedParachainMessagesSchema = GenericTransactionExtensionSchema<(), ()>;
+pub type RefundBridgedParachainMessagesSchema = GenericSignedExtensionSchema<(), ()>;
#[impl_for_tuples(1, 12)]
-impl TransactionExtensionSchema for Tuple {
+impl SignedExtensionSchema for Tuple {
for_tuples!( type Payload = ( #( Tuple::Payload ),* ); );
- for_tuples!( type Implicit = ( #( Tuple::Implicit ),* ); );
+ for_tuples!( type AdditionalSigned = ( #( Tuple::AdditionalSigned ),* ); );
}
/// A simplified version of signed extensions meant for producing signed transactions
/// and signed payloads in the client code.
#[derive(Encode, Decode, Debug, PartialEq, Eq, Clone, TypeInfo)]
-pub struct GenericTransactionExtension {
+pub struct GenericSignedExtension {
/// A payload that is included in the transaction.
pub payload: S::Payload,
#[codec(skip)]
// It may be set to `None` if extensions are decoded. We are never reconstructing transactions
- // (and it makes no sense to do that) => decoded version of `TransactionExtensions` is only
- // used to read fields of the `payload`. And when resigning transaction, we're reconstructing
- // `TransactionExtensions` from scratch.
- implicit: Option,
+ // (and it makes no sense to do that) => decoded version of `SignedExtensions` is only used to
+ // read fields of the `payload`. And when resigning transaction, we're reconstructing
+ // `SignedExtensions` from scratch.
+ additional_signed: Option,
}
-impl GenericTransactionExtension {
- /// Create new `GenericTransactionExtension` object.
- pub fn new(payload: S::Payload, implicit: Option) -> Self {
- Self { payload, implicit }
+impl GenericSignedExtension {
+ /// Create new `GenericSignedExtension` object.
+ pub fn new(payload: S::Payload, additional_signed: Option) -> Self {
+ Self { payload, additional_signed }
}
}
-impl TransactionExtensionBase for GenericTransactionExtension
+impl SignedExtension for GenericSignedExtension
where
- S: TransactionExtensionSchema,
+ S: SignedExtensionSchema,
S::Payload: Send + Sync,
- S::Implicit: Send + Sync,
+ S::AdditionalSigned: Send + Sync,
{
const IDENTIFIER: &'static str = "Not needed.";
- type Implicit = S::Implicit;
+ type AccountId = ();
+ type Call = ();
+ type AdditionalSigned = S::AdditionalSigned;
+ type Pre = ();
- fn implicit(&self) -> Result {
+ fn additional_signed(&self) -> Result {
// we shall not ever see this error in relay, because we are never signing decoded
// transactions. Instead we're constructing and signing new transactions. So the error code
// is kinda random here
- self.implicit
- .clone()
- .ok_or(frame_support::unsigned::TransactionValidityError::Unknown(
+ self.additional_signed.clone().ok_or(
+ frame_support::unsigned::TransactionValidityError::Unknown(
frame_support::unsigned::UnknownTransaction::Custom(0xFF),
- ))
+ ),
+ )
}
-}
-impl TransactionExtension for GenericTransactionExtension
-where
- C: Dispatchable,
- S: TransactionExtensionSchema,
- S::Payload: Send + Sync,
- S::Implicit: Send + Sync,
-{
- type Pre = ();
- type Val = ();
- impl_tx_ext_default!(C; Context; validate prepare);
+ fn pre_dispatch(
+ self,
+ _who: &Self::AccountId,
+ _call: &Self::Call,
+ _info: &DispatchInfoOf,
+ _len: usize,
+ ) -> Result {
+ Ok(())
+ }
}
diff --git a/bridges/primitives/test-utils/src/lib.rs b/bridges/primitives/test-utils/src/lib.rs
index f23ddd1a10d3681900b024999aef279ea6fcb91d..1d80890779bf8310b393d585749e96f9577196a1 100644
--- a/bridges/primitives/test-utils/src/lib.rs
+++ b/bridges/primitives/test-utils/src/lib.rs
@@ -129,7 +129,7 @@ pub fn make_justification_for_header(
votes_ancestries.push(child.clone());
}
- // The header we need to use when pre-commiting is the one at the highest height
+ // The header we need to use when pre-committing is the one at the highest height
// on our chain.
let precommit_candidate = chain.last().map(|h| (h.hash(), *h.number())).unwrap();
unsigned_precommits.push(precommit_candidate);
diff --git a/bridges/snowbridge/runtime/test-common/Cargo.toml b/bridges/snowbridge/runtime/test-common/Cargo.toml
index 5f169e82f49346742bd97028da583105bf02335d..4e8b311cb97812bb94140aa02405b3a174064a8f 100644
--- a/bridges/snowbridge/runtime/test-common/Cargo.toml
+++ b/bridges/snowbridge/runtime/test-common/Cargo.toml
@@ -181,7 +181,6 @@ runtime-benchmarks = [
"pallet-message-queue/runtime-benchmarks",
"pallet-multisig/runtime-benchmarks",
"pallet-timestamp/runtime-benchmarks",
- "pallet-transaction-payment/runtime-benchmarks",
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
diff --git a/bridges/testing/tests/0001-asset-transfer/roc-reaches-westend.zndsl b/bridges/testing/tests/0001-asset-transfer/roc-reaches-westend.zndsl
index a58520ccea65b50dd0db1f67a72f6f8a4c5cdb38..cdb7d28e940cf1ac90562e761cdbad00e95e1748 100644
--- a/bridges/testing/tests/0001-asset-transfer/roc-reaches-westend.zndsl
+++ b/bridges/testing/tests/0001-asset-transfer/roc-reaches-westend.zndsl
@@ -6,7 +6,7 @@ Creds: config
asset-hub-westend-collator1: run {{ENV_PATH}}/helper.sh with "reserve-transfer-assets-from-asset-hub-rococo-local 5000000000000" within 120 seconds
# check that //Alice received at least 4.8 ROC on Westend AH
-asset-hub-westend-collator1: js-script {{FRAMEWORK_PATH}}/js-helpers/wrapped-assets-balance.js with "5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY,4800000000000,Rococo" within 300 seconds
+asset-hub-westend-collator1: js-script {{FRAMEWORK_PATH}}/js-helpers/wrapped-assets-balance.js with "5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY,4800000000000,Rococo" within 600 seconds
# check that the relayer //Charlie is rewarded by Westend AH
bridge-hub-westend-collator1: js-script {{FRAMEWORK_PATH}}/js-helpers/relayer-rewards.js with "5FLSigC9HGRKVhB9FiEo4Y3koPsNmBmLJbpXg2mp1hXcS59Y,0x00000002,0x6268726F,ThisChain,0" within 30 seconds
diff --git a/bridges/testing/tests/0001-asset-transfer/wnd-reaches-rococo.zndsl b/bridges/testing/tests/0001-asset-transfer/wnd-reaches-rococo.zndsl
index fedb78cc2103555a1d15c446dd2f08fca94643e1..dbc03864e2b6e5e10636532ad965860b381fa8f2 100644
--- a/bridges/testing/tests/0001-asset-transfer/wnd-reaches-rococo.zndsl
+++ b/bridges/testing/tests/0001-asset-transfer/wnd-reaches-rococo.zndsl
@@ -6,7 +6,7 @@ Creds: config
asset-hub-rococo-collator1: run {{ENV_PATH}}/helper.sh with "reserve-transfer-assets-from-asset-hub-westend-local 5000000000000" within 120 seconds
# check that //Alice received at least 4.8 WND on Rococo AH
-asset-hub-rococo-collator1: js-script {{FRAMEWORK_PATH}}/js-helpers/wrapped-assets-balance.js with "5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY,4800000000000,Westend" within 300 seconds
+asset-hub-rococo-collator1: js-script {{FRAMEWORK_PATH}}/js-helpers/wrapped-assets-balance.js with "5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY,4800000000000,Westend" within 600 seconds
# check that the relayer //Charlie is rewarded by Rococo AH
bridge-hub-rococo-collator1: js-script {{FRAMEWORK_PATH}}/js-helpers/relayer-rewards.js with "5FLSigC9HGRKVhB9FiEo4Y3koPsNmBmLJbpXg2mp1hXcS59Y,0x00000002,0x62687764,ThisChain,0" within 30 seconds
diff --git a/bridges/testing/tests/0001-asset-transfer/wroc-reaches-rococo.zndsl b/bridges/testing/tests/0001-asset-transfer/wroc-reaches-rococo.zndsl
index 68b888b6858e86b8fe846b887bc101e221b2f21d..9967732cabe15e020060eb0a53fd8ce1440180e5 100644
--- a/bridges/testing/tests/0001-asset-transfer/wroc-reaches-rococo.zndsl
+++ b/bridges/testing/tests/0001-asset-transfer/wroc-reaches-rococo.zndsl
@@ -7,4 +7,4 @@ asset-hub-rococo-collator1: run {{ENV_PATH}}/helper.sh with "withdraw-reserve-as
# check that //Alice received at least 2.8 wROC on Rococo AH
# (we wait until //Alice account increases here - there are no other transactions that may increase it)
-asset-hub-rococo-collator1: js-script {{FRAMEWORK_PATH}}/js-helpers/native-assets-balance-increased.js with "5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY,2800000000000" within 300 seconds
+asset-hub-rococo-collator1: js-script {{FRAMEWORK_PATH}}/js-helpers/native-assets-balance-increased.js with "5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY,2800000000000" within 600 seconds
diff --git a/bridges/testing/tests/0001-asset-transfer/wwnd-reaches-westend.zndsl b/bridges/testing/tests/0001-asset-transfer/wwnd-reaches-westend.zndsl
index 1a8a161819542e281094aed0681d52167aaea8e6..2037b0baf3c0aac2a0e1a8f297c6baa155ac680f 100644
--- a/bridges/testing/tests/0001-asset-transfer/wwnd-reaches-westend.zndsl
+++ b/bridges/testing/tests/0001-asset-transfer/wwnd-reaches-westend.zndsl
@@ -7,4 +7,4 @@ asset-hub-westend-collator1: run {{ENV_PATH}}/helper.sh with "withdraw-reserve-a
# check that //Alice received at least 2.8 wWND on Westend AH
# (we wait until //Alice account increases here - there are no other transactions that may increase it)
-asset-hub-westend-collator1: js-script {{FRAMEWORK_PATH}}/js-helpers/native-assets-balance-increased.js with "5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY,2800000000000" within 300 seconds
+asset-hub-westend-collator1: js-script {{FRAMEWORK_PATH}}/js-helpers/native-assets-balance-increased.js with "5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY,2800000000000" within 600 seconds
diff --git a/cumulus/client/parachain-inherent/src/lib.rs b/cumulus/client/parachain-inherent/src/lib.rs
index 57353638e197acf255b73080c6802e94647c2090..051eb6764c8ce97a8305a07bdddb8f06f61fe4bc 100644
--- a/cumulus/client/parachain-inherent/src/lib.rs
+++ b/cumulus/client/parachain-inherent/src/lib.rs
@@ -159,7 +159,7 @@ impl ParachainInherentDataProvider {
target: LOG_TARGET,
relay_parent = ?relay_parent,
error = ?e,
- "An error occured during requesting the downward messages.",
+ "An error occurred during requesting the downward messages.",
);
})
.ok()?;
@@ -171,7 +171,7 @@ impl ParachainInherentDataProvider {
target: LOG_TARGET,
relay_parent = ?relay_parent,
error = ?e,
- "An error occured during requesting the inbound HRMP messages.",
+ "An error occurred during requesting the inbound HRMP messages.",
);
})
.ok()?;
diff --git a/cumulus/pallets/collator-selection/src/benchmarking.rs b/cumulus/pallets/collator-selection/src/benchmarking.rs
index 2c40f4dd0eac4a8a2ad3aed7f162a4379ccdbc93..e2af74a6e60ef00ca9d1111518d86df3fdfb0656 100644
--- a/cumulus/pallets/collator-selection/src/benchmarking.rs
+++ b/cumulus/pallets/collator-selection/src/benchmarking.rs
@@ -22,9 +22,7 @@ use super::*;
#[allow(unused)]
use crate::Pallet as CollatorSelection;
use codec::Decode;
-use frame_benchmarking::{
- account, impl_benchmark_test_suite, v2::*, whitelisted_caller, BenchmarkError,
-};
+use frame_benchmarking::{account, v2::*, whitelisted_caller, BenchmarkError};
use frame_support::traits::{Currency, EnsureOrigin, Get, ReservableCurrency};
use frame_system::{pallet_prelude::BlockNumberFor, EventRecord, RawOrigin};
use pallet_authorship::EventHandler;
diff --git a/cumulus/pallets/collator-selection/src/lib.rs b/cumulus/pallets/collator-selection/src/lib.rs
index fb4c4a445df296b3650901326db9edccbbbd61cf..62c00737f91a4aac25f2e1972a0c5aade5e0eed2 100644
--- a/cumulus/pallets/collator-selection/src/lib.rs
+++ b/cumulus/pallets/collator-selection/src/lib.rs
@@ -495,7 +495,11 @@ pub mod pallet {
})
.unwrap_or_default();
Self::deposit_event(Event::NewCandidacyBond { bond_amount: bond });
- Ok(Some(T::WeightInfo::set_candidacy_bond(initial_len as u32, kicked as u32)).into())
+ Ok(Some(T::WeightInfo::set_candidacy_bond(
+ bond_increased.then(|| initial_len as u32).unwrap_or_default(),
+ kicked as u32,
+ ))
+ .into())
}
/// Register this account as a collator candidate. The account must (a) already have
diff --git a/cumulus/parachains/integration-tests/emulated/common/src/impls.rs b/cumulus/parachains/integration-tests/emulated/common/src/impls.rs
index 4bbb4701e43918f5f34b250a23c4c483f2b2d4d1..c93484829fe8193c69a4d9475e81201e3607796c 100644
--- a/cumulus/parachains/integration-tests/emulated/common/src/impls.rs
+++ b/cumulus/parachains/integration-tests/emulated/common/src/impls.rs
@@ -265,7 +265,7 @@ macro_rules! impl_assert_events_helpers_for_relay_chain {
$crate::impls::assert_expected_events!(
Self,
vec![
- // XCM is succesfully received and proccessed
+ // XCM is successfully received and proccessed
[<$chain RuntimeEvent>]::::MessageQueue($crate::impls::pallet_message_queue::Event::Processed {
origin: $crate::impls::AggregateMessageOrigin::Ump($crate::impls::UmpQueueId::Para(id)),
weight_used,
diff --git a/cumulus/parachains/pallets/collective-content/src/benchmarking.rs b/cumulus/parachains/pallets/collective-content/src/benchmarking.rs
index 943386a842766129c2b5d429dc3a9648249ea73f..3d6bf073778a294e39287285ddb8379d57d36c8f 100644
--- a/cumulus/parachains/pallets/collective-content/src/benchmarking.rs
+++ b/cumulus/parachains/pallets/collective-content/src/benchmarking.rs
@@ -16,7 +16,7 @@
//! The pallet benchmarks.
use super::{Pallet as CollectiveContent, *};
-use frame_benchmarking::{impl_benchmark_test_suite, v2::*};
+use frame_benchmarking::v2::*;
use frame_support::traits::EnsureOrigin;
fn assert_last_event, I: 'static>(generic_event: >::RuntimeEvent) {
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-rococo/Cargo.toml b/cumulus/parachains/runtimes/assets/asset-hub-rococo/Cargo.toml
index 3eb63a24b74e9eee4ded63cc591ec6ba8adb136b..05936e93993231429d738edf15acc48150bcc542 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-rococo/Cargo.toml
+++ b/cumulus/parachains/runtimes/assets/asset-hub-rococo/Cargo.toml
@@ -119,7 +119,6 @@ runtime-benchmarks = [
"frame-support/runtime-benchmarks",
"frame-system-benchmarking/runtime-benchmarks",
"frame-system/runtime-benchmarks",
- "pallet-asset-conversion-tx-payment/runtime-benchmarks",
"pallet-asset-conversion/runtime-benchmarks",
"pallet-assets/runtime-benchmarks",
"pallet-balances/runtime-benchmarks",
@@ -131,7 +130,6 @@ runtime-benchmarks = [
"pallet-proxy/runtime-benchmarks",
"pallet-state-trie-migration/runtime-benchmarks",
"pallet-timestamp/runtime-benchmarks",
- "pallet-transaction-payment/runtime-benchmarks",
"pallet-uniques/runtime-benchmarks",
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/lib.rs b/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/lib.rs
index 32966ab6341d7bf4b2efae0cf008cfa6dfb67275..17a12dd2f6f763f5d3bc22364b8f83fe3e401d44 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/lib.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/lib.rs
@@ -178,7 +178,6 @@ impl frame_system::Config for Runtime {
type Version = Version;
type AccountData = pallet_balances::AccountData;
type SystemWeightInfo = weights::frame_system::WeightInfo;
- type ExtensionsWeightInfo = weights::frame_system_extensions::WeightInfo;
type SS58Prefix = SS58Prefix;
type OnSetCode = cumulus_pallet_parachain_system::ParachainSetCode;
type MaxConsumers = frame_support::traits::ConstU32<16>;
@@ -235,7 +234,6 @@ impl pallet_transaction_payment::Config for Runtime {
type LengthToFee = ConstantMultiplier;
type FeeMultiplierUpdate = SlowAdjustingFeeUpdate;
type OperationalFeeMultiplier = ConstU8<5>;
- type WeightInfo = weights::pallet_transaction_payment::WeightInfo;
}
parameter_types! {
@@ -763,9 +761,6 @@ impl pallet_asset_conversion_tx_payment::Config for Runtime {
type Fungibles = LocalAndForeignAssets;
type OnChargeAssetTransaction =
AssetConversionAdapter;
- type WeightInfo = weights::pallet_asset_conversion_tx_payment::WeightInfo;
- #[cfg(feature = "runtime-benchmarks")]
- type BenchmarkHelper = AssetConversionTxHelper;
}
parameter_types! {
@@ -953,8 +948,8 @@ pub type Block = generic::Block;
pub type SignedBlock = generic::SignedBlock;
/// BlockId type as expected by this runtime.
pub type BlockId = generic::BlockId;
-/// The extension to the basic transaction logic.
-pub type TxExtension = (
+/// The SignedExtension to the basic transaction logic.
+pub type SignedExtra = (
frame_system::CheckNonZeroSender,
frame_system::CheckSpecVersion,
frame_system::CheckTxVersion,
@@ -966,7 +961,7 @@ pub type TxExtension = (
);
/// Unchecked extrinsic type as expected by this runtime.
pub type UncheckedExtrinsic =
- generic::UncheckedExtrinsic;
+ generic::UncheckedExtrinsic;
/// Migrations to apply on runtime upgrade.
pub type Migrations = (
pallet_collator_selection::migration::v1::MigrateToV1,
@@ -1039,77 +1034,14 @@ pub type Executive = frame_executive::Executive<
Migrations,
>;
-#[cfg(feature = "runtime-benchmarks")]
-pub struct AssetConversionTxHelper;
-
-#[cfg(feature = "runtime-benchmarks")]
-impl
- pallet_asset_conversion_tx_payment::BenchmarkHelperTrait<
- AccountId,
- xcm::v3::MultiLocation,
- xcm::v3::MultiLocation,
- > for AssetConversionTxHelper
-{
- fn create_asset_id_parameter(seed: u32) -> (xcm::v3::MultiLocation, xcm::v3::MultiLocation) {
- // Use a different parachain' foreign assets pallet so that the asset is indeed foreign.
- let asset_id = xcm::v3::MultiLocation::new(
- 1,
- xcm::v3::Junctions::X3(
- xcm::v3::Junction::Parachain(3000),
- xcm::v3::Junction::PalletInstance(53),
- xcm::v3::Junction::GeneralIndex(seed.into()),
- ),
- );
- (asset_id, asset_id)
- }
-
- fn setup_balances_and_pool(asset_id: xcm::v3::MultiLocation, account: AccountId) {
- use frame_support::{assert_ok, traits::fungibles::Mutate};
- assert_ok!(ForeignAssets::force_create(
- RuntimeOrigin::root(),
- asset_id.into(),
- account.clone().into(), /* owner */
- true, /* is_sufficient */
- 1,
- ));
-
- let lp_provider = account.clone();
- use frame_support::traits::Currency;
- let _ = Balances::deposit_creating(&lp_provider, u64::MAX.into());
- assert_ok!(ForeignAssets::mint_into(asset_id.into(), &lp_provider, u64::MAX.into()));
-
- let token_native = Box::new(TokenLocationV3::get());
- let token_second = Box::new(asset_id);
-
- assert_ok!(AssetConversion::create_pool(
- RuntimeOrigin::signed(lp_provider.clone()),
- token_native.clone(),
- token_second.clone()
- ));
-
- assert_ok!(AssetConversion::add_liquidity(
- RuntimeOrigin::signed(lp_provider.clone()),
- token_native,
- token_second,
- (u32::MAX / 8).into(), // 1 desired
- u32::MAX.into(), // 2 desired
- 1, // 1 min
- 1, // 2 min
- lp_provider,
- ));
- }
-}
-
#[cfg(feature = "runtime-benchmarks")]
mod benches {
frame_benchmarking::define_benchmarks!(
[frame_system, SystemBench::]
- [frame_system_extensions, SystemExtensionsBench::]
[pallet_assets, Local]
[pallet_assets, Foreign]
[pallet_assets, Pool]
[pallet_asset_conversion, AssetConversion]
- [pallet_asset_conversion_tx_payment, AssetTxPayment]
[pallet_balances, Balances]
[pallet_message_queue, MessageQueue]
[pallet_multisig, Multisig]
@@ -1120,7 +1052,6 @@ mod benches {
[pallet_uniques, Uniques]
[pallet_utility, Utility]
[pallet_timestamp, Timestamp]
- [pallet_transaction_payment, TransactionPayment]
[pallet_collator_selection, CollatorSelection]
[cumulus_pallet_parachain_system, ParachainSystem]
[cumulus_pallet_xcmp_queue, XcmpQueue]
@@ -1371,7 +1302,6 @@ impl_runtime_apis! {
use frame_benchmarking::{Benchmarking, BenchmarkList};
use frame_support::traits::StorageInfoTrait;
use frame_system_benchmarking::Pallet as SystemBench;
- use frame_system_benchmarking::extensions::Pallet as SystemExtensionsBench;
use cumulus_pallet_session_benchmarking::Pallet as SessionBench;
use pallet_xcm::benchmarking::Pallet as PalletXcmExtrinsicsBenchmark;
use pallet_xcm_bridge_hub_router::benchmarking::Pallet as XcmBridgeHubRouterBench;
@@ -1406,7 +1336,6 @@ impl_runtime_apis! {
use sp_storage::TrackedStorageKey;
use frame_system_benchmarking::Pallet as SystemBench;
- use frame_system_benchmarking::extensions::Pallet as SystemExtensionsBench;
impl frame_system_benchmarking::Config for Runtime {
fn setup_set_code_requirements(code: &sp_std::vec::Vec) -> Result<(), BenchmarkError> {
ParachainSystem::initialize_for_set_code_benchmark(code.len() as u32);
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/frame_system_extensions.rs b/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/frame_system_extensions.rs
deleted file mode 100644
index ed2c5f3056e3c44601fee945ccda3eab35444e12..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/frame_system_extensions.rs
+++ /dev/null
@@ -1,121 +0,0 @@
-// Copyright (C) Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Cumulus is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Cumulus. If not, see .
-
-//! Autogenerated weights for `frame_system_extensions`
-//!
-//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
-//! DATE: 2023-12-21, STEPS: `2`, REPEAT: `2`, LOW RANGE: `[]`, HIGH RANGE: `[]`
-//! WORST CASE MAP SIZE: `1000000`
-//! HOSTNAME: `gleipnir`, CPU: `AMD Ryzen 9 7900X 12-Core Processor`
-//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("asset-hub-rococo-dev")`, DB CACHE: 1024
-
-// Executed Command:
-// ./target/release/polkadot-parachain
-// benchmark
-// pallet
-// --wasm-execution=compiled
-// --pallet=frame_system_extensions
-// --no-storage-info
-// --no-median-slopes
-// --no-min-squares
-// --extrinsic=*
-// --steps=2
-// --repeat=2
-// --json
-// --header=./cumulus/file_header.txt
-// --output=./cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/
-// --chain=asset-hub-rococo-dev
-
-#![cfg_attr(rustfmt, rustfmt_skip)]
-#![allow(unused_parens)]
-#![allow(unused_imports)]
-#![allow(missing_docs)]
-
-use frame_support::{traits::Get, weights::Weight};
-use core::marker::PhantomData;
-
-/// Weight functions for `frame_system_extensions`.
-pub struct WeightInfo(PhantomData);
-impl frame_system::ExtensionsWeightInfo for WeightInfo {
- /// Storage: `System::BlockHash` (r:1 w:0)
- /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`)
- fn check_genesis() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `54`
- // Estimated: `3509`
- // Minimum execution time: 3_637_000 picoseconds.
- Weight::from_parts(6_382_000, 0)
- .saturating_add(Weight::from_parts(0, 3509))
- .saturating_add(T::DbWeight::get().reads(1))
- }
- /// Storage: `System::BlockHash` (r:1 w:0)
- /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`)
- fn check_mortality() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `92`
- // Estimated: `3509`
- // Minimum execution time: 5_841_000 picoseconds.
- Weight::from_parts(8_776_000, 0)
- .saturating_add(Weight::from_parts(0, 3509))
- .saturating_add(T::DbWeight::get().reads(1))
- }
- fn check_non_zero_sender() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 561_000 picoseconds.
- Weight::from_parts(2_705_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_nonce() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 3_316_000 picoseconds.
- Weight::from_parts(5_771_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_spec_version() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 511_000 picoseconds.
- Weight::from_parts(2_575_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_tx_version() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 501_000 picoseconds.
- Weight::from_parts(2_595_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- /// Storage: `System::AllExtrinsicsLen` (r:1 w:1)
- /// Proof: `System::AllExtrinsicsLen` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
- /// Storage: `System::BlockWeight` (r:1 w:1)
- /// Proof: `System::BlockWeight` (`max_values`: Some(1), `max_size`: Some(48), added: 543, mode: `MaxEncodedLen`)
- fn check_weight() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `24`
- // Estimated: `1533`
- // Minimum execution time: 3_687_000 picoseconds.
- Weight::from_parts(6_192_000, 0)
- .saturating_add(Weight::from_parts(0, 1533))
- .saturating_add(T::DbWeight::get().reads(2))
- .saturating_add(T::DbWeight::get().writes(2))
- }
-}
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/mod.rs b/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/mod.rs
index 134b5341a401ca0f0918d3f04a79d2a4d1d9622d..fa9e86102c619c9ff68316cae2a27a7f79fea2e6 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/mod.rs
@@ -19,9 +19,7 @@ pub mod cumulus_pallet_parachain_system;
pub mod cumulus_pallet_xcmp_queue;
pub mod extrinsic_weights;
pub mod frame_system;
-pub mod frame_system_extensions;
pub mod pallet_asset_conversion;
-pub mod pallet_asset_conversion_tx_payment;
pub mod pallet_assets_foreign;
pub mod pallet_assets_local;
pub mod pallet_assets_pool;
@@ -34,7 +32,6 @@ pub mod pallet_nfts;
pub mod pallet_proxy;
pub mod pallet_session;
pub mod pallet_timestamp;
-pub mod pallet_transaction_payment;
pub mod pallet_uniques;
pub mod pallet_utility;
pub mod pallet_xcm;
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/pallet_asset_conversion_tx_payment.rs b/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/pallet_asset_conversion_tx_payment.rs
deleted file mode 100644
index 0a639b368af2248bdaf1efa7538d58a935dbe2e0..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/pallet_asset_conversion_tx_payment.rs
+++ /dev/null
@@ -1,92 +0,0 @@
-// Copyright (C) Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Cumulus is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Cumulus. If not, see .
-
-//! Autogenerated weights for `pallet_asset_conversion_tx_payment`
-//!
-//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
-//! DATE: 2024-01-04, STEPS: `2`, REPEAT: `2`, LOW RANGE: `[]`, HIGH RANGE: `[]`
-//! WORST CASE MAP SIZE: `1000000`
-//! HOSTNAME: `Georges-MacBook-Pro.local`, CPU: ``
-//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("asset-hub-rococo-dev")`, DB CACHE: 1024
-
-// Executed Command:
-// ./target/debug/polkadot-parachain
-// benchmark
-// pallet
-// --wasm-execution=compiled
-// --pallet=pallet_asset_conversion_tx_payment
-// --no-storage-info
-// --no-median-slopes
-// --no-min-squares
-// --extrinsic=*
-// --steps=2
-// --repeat=2
-// --json
-// --header=./cumulus/file_header.txt
-// --output=./cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/
-// --chain=asset-hub-rococo-dev
-
-#![cfg_attr(rustfmt, rustfmt_skip)]
-#![allow(unused_parens)]
-#![allow(unused_imports)]
-#![allow(missing_docs)]
-
-use frame_support::{traits::Get, weights::Weight};
-use core::marker::PhantomData;
-
-/// Weight functions for `pallet_asset_conversion_tx_payment`.
-pub struct WeightInfo(PhantomData);
-impl pallet_asset_conversion_tx_payment::WeightInfo for WeightInfo {
- fn charge_asset_tx_payment_zero() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 7_000_000 picoseconds.
- Weight::from_parts(10_000_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- /// Storage: `TransactionPayment::NextFeeMultiplier` (r:1 w:0)
- /// Proof: `TransactionPayment::NextFeeMultiplier` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`)
- /// Storage: `System::Account` (r:1 w:0)
- /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
- fn charge_asset_tx_payment_native() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `4`
- // Estimated: `3593`
- // Minimum execution time: 209_000_000 picoseconds.
- Weight::from_parts(212_000_000, 0)
- .saturating_add(Weight::from_parts(0, 3593))
- .saturating_add(T::DbWeight::get().reads(2))
- }
- /// Storage: `TransactionPayment::NextFeeMultiplier` (r:1 w:0)
- /// Proof: `TransactionPayment::NextFeeMultiplier` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`)
- /// Storage: `ForeignAssets::Asset` (r:1 w:1)
- /// Proof: `ForeignAssets::Asset` (`max_values`: None, `max_size`: Some(808), added: 3283, mode: `MaxEncodedLen`)
- /// Storage: `ForeignAssets::Account` (r:2 w:2)
- /// Proof: `ForeignAssets::Account` (`max_values`: None, `max_size`: Some(732), added: 3207, mode: `MaxEncodedLen`)
- /// Storage: `System::Account` (r:2 w:1)
- /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
- fn charge_asset_tx_payment_asset() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `631`
- // Estimated: `7404`
- // Minimum execution time: 1_228_000_000 picoseconds.
- Weight::from_parts(1_268_000_000, 0)
- .saturating_add(Weight::from_parts(0, 7404))
- .saturating_add(T::DbWeight::get().reads(6))
- .saturating_add(T::DbWeight::get().writes(4))
- }
-}
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/pallet_transaction_payment.rs b/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/pallet_transaction_payment.rs
deleted file mode 100644
index 035f9a6dbe5167cb651736f705b817d4ba9027c4..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/pallet_transaction_payment.rs
+++ /dev/null
@@ -1,67 +0,0 @@
-// Copyright (C) Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Cumulus is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Cumulus. If not, see .
-
-//! Autogenerated weights for `pallet_transaction_payment`
-//!
-//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
-//! DATE: 2023-12-21, STEPS: `2`, REPEAT: `2`, LOW RANGE: `[]`, HIGH RANGE: `[]`
-//! WORST CASE MAP SIZE: `1000000`
-//! HOSTNAME: `gleipnir`, CPU: `AMD Ryzen 9 7900X 12-Core Processor`
-//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("asset-hub-rococo-dev")`, DB CACHE: 1024
-
-// Executed Command:
-// ./target/release/polkadot-parachain
-// benchmark
-// pallet
-// --wasm-execution=compiled
-// --pallet=pallet_transaction_payment
-// --no-storage-info
-// --no-median-slopes
-// --no-min-squares
-// --extrinsic=*
-// --steps=2
-// --repeat=2
-// --json
-// --header=./cumulus/file_header.txt
-// --output=./cumulus/parachains/runtimes/assets/asset-hub-rococo/src/weights/
-// --chain=asset-hub-rococo-dev
-
-#![cfg_attr(rustfmt, rustfmt_skip)]
-#![allow(unused_parens)]
-#![allow(unused_imports)]
-#![allow(missing_docs)]
-
-use frame_support::{traits::Get, weights::Weight};
-use core::marker::PhantomData;
-
-/// Weight functions for `pallet_transaction_payment`.
-pub struct WeightInfo(PhantomData);
-impl pallet_transaction_payment::WeightInfo for WeightInfo {
- /// Storage: `TransactionPayment::NextFeeMultiplier` (r:1 w:0)
- /// Proof: `TransactionPayment::NextFeeMultiplier` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`)
- /// Storage: `System::Account` (r:1 w:1)
- /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
- fn charge_transaction_payment() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `4`
- // Estimated: `3593`
- // Minimum execution time: 33_363_000 picoseconds.
- Weight::from_parts(38_793_000, 0)
- .saturating_add(Weight::from_parts(0, 3593))
- .saturating_add(T::DbWeight::get().reads(2))
- .saturating_add(T::DbWeight::get().writes(1))
- }
-}
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/Cargo.toml b/cumulus/parachains/runtimes/assets/asset-hub-westend/Cargo.toml
index c10e02bd8a6c54d36969ca1f259892ce685b2665..78c48507a7a44efadd39ab7729f9cadfe681cf8a 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/Cargo.toml
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/Cargo.toml
@@ -110,7 +110,6 @@ runtime-benchmarks = [
"frame-system-benchmarking/runtime-benchmarks",
"frame-system/runtime-benchmarks",
"hex-literal",
- "pallet-asset-conversion-tx-payment/runtime-benchmarks",
"pallet-asset-conversion/runtime-benchmarks",
"pallet-assets/runtime-benchmarks",
"pallet-balances/runtime-benchmarks",
@@ -121,7 +120,6 @@ runtime-benchmarks = [
"pallet-nfts/runtime-benchmarks",
"pallet-proxy/runtime-benchmarks",
"pallet-timestamp/runtime-benchmarks",
- "pallet-transaction-payment/runtime-benchmarks",
"pallet-uniques/runtime-benchmarks",
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/lib.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/lib.rs
index 5246828da310ad51e167756b0f12fe814acc6fff..1ead28978550ca653c22df12f2588f406ce67f7f 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/lib.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/lib.rs
@@ -162,7 +162,6 @@ impl frame_system::Config for Runtime {
type Version = Version;
type AccountData = pallet_balances::AccountData;
type SystemWeightInfo = weights::frame_system::WeightInfo;
- type ExtensionsWeightInfo = weights::frame_system_extensions::WeightInfo;
type SS58Prefix = SS58Prefix;
type OnSetCode = cumulus_pallet_parachain_system::ParachainSetCode;
type MaxConsumers = frame_support::traits::ConstU32<16>;
@@ -219,7 +218,6 @@ impl pallet_transaction_payment::Config for Runtime {
type LengthToFee = ConstantMultiplier;
type FeeMultiplierUpdate = SlowAdjustingFeeUpdate;
type OperationalFeeMultiplier = ConstU8<5>;
- type WeightInfo = weights::pallet_transaction_payment::WeightInfo;
}
parameter_types! {
@@ -737,9 +735,6 @@ impl pallet_asset_conversion_tx_payment::Config for Runtime {
type Fungibles = LocalAndForeignAssets;
type OnChargeAssetTransaction =
AssetConversionAdapter;
- type WeightInfo = weights::pallet_asset_conversion_tx_payment::WeightInfo;
- #[cfg(feature = "runtime-benchmarks")]
- type BenchmarkHelper = AssetConversionTxHelper;
}
parameter_types! {
@@ -925,8 +920,8 @@ pub type Block = generic::Block;
pub type SignedBlock = generic::SignedBlock;
/// BlockId type as expected by this runtime.
pub type BlockId = generic::BlockId;
-/// The extension to the basic transaction logic.
-pub type TxExtension = (
+/// The SignedExtension to the basic transaction logic.
+pub type SignedExtra = (
frame_system::CheckNonZeroSender,
frame_system::CheckSpecVersion,
frame_system::CheckTxVersion,
@@ -938,7 +933,7 @@ pub type TxExtension = (
);
/// Unchecked extrinsic type as expected by this runtime.
pub type UncheckedExtrinsic =
- generic::UncheckedExtrinsic;
+ generic::UncheckedExtrinsic;
/// Migrations to apply on runtime upgrade.
pub type Migrations = (
@@ -1070,77 +1065,14 @@ pub type Executive = frame_executive::Executive<
Migrations,
>;
-#[cfg(feature = "runtime-benchmarks")]
-pub struct AssetConversionTxHelper;
-
-#[cfg(feature = "runtime-benchmarks")]
-impl
- pallet_asset_conversion_tx_payment::BenchmarkHelperTrait<
- AccountId,
- xcm::v3::MultiLocation,
- xcm::v3::MultiLocation,
- > for AssetConversionTxHelper
-{
- fn create_asset_id_parameter(seed: u32) -> (xcm::v3::MultiLocation, xcm::v3::MultiLocation) {
- // Use a different parachain' foreign assets pallet so that the asset is indeed foreign.
- let asset_id = xcm::v3::MultiLocation::new(
- 1,
- xcm::v3::Junctions::X3(
- xcm::v3::Junction::Parachain(3000),
- xcm::v3::Junction::PalletInstance(53),
- xcm::v3::Junction::GeneralIndex(seed.into()),
- ),
- );
- (asset_id, asset_id)
- }
-
- fn setup_balances_and_pool(asset_id: xcm::v3::MultiLocation, account: AccountId) {
- use frame_support::{assert_ok, traits::fungibles::Mutate};
- assert_ok!(ForeignAssets::force_create(
- RuntimeOrigin::root(),
- asset_id.into(),
- account.clone().into(), /* owner */
- true, /* is_sufficient */
- 1,
- ));
-
- let lp_provider = account.clone();
- use frame_support::traits::Currency;
- let _ = Balances::deposit_creating(&lp_provider, u64::MAX.into());
- assert_ok!(ForeignAssets::mint_into(asset_id.into(), &lp_provider, u64::MAX.into()));
-
- let token_native = Box::new(xcm::v3::MultiLocation::new(1, xcm::v3::Junctions::Here));
- let token_second = Box::new(asset_id);
-
- assert_ok!(AssetConversion::create_pool(
- RuntimeOrigin::signed(lp_provider.clone()),
- token_native.clone(),
- token_second.clone()
- ));
-
- assert_ok!(AssetConversion::add_liquidity(
- RuntimeOrigin::signed(lp_provider.clone()),
- token_native,
- token_second,
- (u32::MAX / 2).into(), // 1 desired
- u32::MAX.into(), // 2 desired
- 1, // 1 min
- 1, // 2 min
- lp_provider,
- ));
- }
-}
-
#[cfg(feature = "runtime-benchmarks")]
mod benches {
frame_benchmarking::define_benchmarks!(
[frame_system, SystemBench::]
- [frame_system_extensions, SystemExtensionsBench::]
[pallet_assets, Local]
[pallet_assets, Foreign]
[pallet_assets, Pool]
[pallet_asset_conversion, AssetConversion]
- [pallet_asset_conversion_tx_payment, AssetTxPayment]
[pallet_balances, Balances]
[pallet_message_queue, MessageQueue]
[pallet_multisig, Multisig]
@@ -1151,7 +1083,6 @@ mod benches {
[pallet_uniques, Uniques]
[pallet_utility, Utility]
[pallet_timestamp, Timestamp]
- [pallet_transaction_payment, TransactionPayment]
[pallet_collator_selection, CollatorSelection]
[cumulus_pallet_parachain_system, ParachainSystem]
[cumulus_pallet_xcmp_queue, XcmpQueue]
@@ -1448,7 +1379,6 @@ impl_runtime_apis! {
use frame_benchmarking::{Benchmarking, BenchmarkList};
use frame_support::traits::StorageInfoTrait;
use frame_system_benchmarking::Pallet as SystemBench;
- use frame_system_benchmarking::extensions::Pallet as SystemExtensionsBench;
use cumulus_pallet_session_benchmarking::Pallet as SessionBench;
use pallet_xcm::benchmarking::Pallet as PalletXcmExtrinsicsBenchmark;
use pallet_xcm_bridge_hub_router::benchmarking::Pallet as XcmBridgeHubRouterBench;
@@ -1483,7 +1413,6 @@ impl_runtime_apis! {
use sp_storage::TrackedStorageKey;
use frame_system_benchmarking::Pallet as SystemBench;
- use frame_system_benchmarking::extensions::Pallet as SystemExtensionsBench;
impl frame_system_benchmarking::Config for Runtime {
fn setup_set_code_requirements(code: &sp_std::vec::Vec) -> Result<(), BenchmarkError> {
ParachainSystem::initialize_for_set_code_benchmark(code.len() as u32);
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/frame_system_extensions.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/frame_system_extensions.rs
deleted file mode 100644
index 46f4f2bfd9668ce7316bf1a4a7a0c71833fd7f7d..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/frame_system_extensions.rs
+++ /dev/null
@@ -1,121 +0,0 @@
-// Copyright (C) Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Cumulus is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Cumulus. If not, see .
-
-//! Autogenerated weights for `frame_system_extensions`
-//!
-//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
-//! DATE: 2023-12-21, STEPS: `2`, REPEAT: `2`, LOW RANGE: `[]`, HIGH RANGE: `[]`
-//! WORST CASE MAP SIZE: `1000000`
-//! HOSTNAME: `gleipnir`, CPU: `AMD Ryzen 9 7900X 12-Core Processor`
-//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("asset-hub-westend-dev")`, DB CACHE: 1024
-
-// Executed Command:
-// ./target/release/polkadot-parachain
-// benchmark
-// pallet
-// --wasm-execution=compiled
-// --pallet=frame_system_extensions
-// --no-storage-info
-// --no-median-slopes
-// --no-min-squares
-// --extrinsic=*
-// --steps=2
-// --repeat=2
-// --json
-// --header=./cumulus/file_header.txt
-// --output=./cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/
-// --chain=asset-hub-westend-dev
-
-#![cfg_attr(rustfmt, rustfmt_skip)]
-#![allow(unused_parens)]
-#![allow(unused_imports)]
-#![allow(missing_docs)]
-
-use frame_support::{traits::Get, weights::Weight};
-use core::marker::PhantomData;
-
-/// Weight functions for `frame_system_extensions`.
-pub struct WeightInfo(PhantomData);
-impl frame_system::ExtensionsWeightInfo for WeightInfo {
- /// Storage: `System::BlockHash` (r:1 w:0)
- /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`)
- fn check_genesis() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `54`
- // Estimated: `3509`
- // Minimum execution time: 3_206_000 picoseconds.
- Weight::from_parts(6_212_000, 0)
- .saturating_add(Weight::from_parts(0, 3509))
- .saturating_add(T::DbWeight::get().reads(1))
- }
- /// Storage: `System::BlockHash` (r:1 w:0)
- /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`)
- fn check_mortality() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `92`
- // Estimated: `3509`
- // Minimum execution time: 5_851_000 picoseconds.
- Weight::from_parts(8_847_000, 0)
- .saturating_add(Weight::from_parts(0, 3509))
- .saturating_add(T::DbWeight::get().reads(1))
- }
- fn check_non_zero_sender() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 631_000 picoseconds.
- Weight::from_parts(3_086_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_nonce() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 3_446_000 picoseconds.
- Weight::from_parts(5_911_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_spec_version() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 481_000 picoseconds.
- Weight::from_parts(2_916_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_tx_version() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 501_000 picoseconds.
- Weight::from_parts(2_595_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- /// Storage: `System::AllExtrinsicsLen` (r:1 w:1)
- /// Proof: `System::AllExtrinsicsLen` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
- /// Storage: `System::BlockWeight` (r:1 w:1)
- /// Proof: `System::BlockWeight` (`max_values`: Some(1), `max_size`: Some(48), added: 543, mode: `MaxEncodedLen`)
- fn check_weight() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `24`
- // Estimated: `1533`
- // Minimum execution time: 3_927_000 picoseconds.
- Weight::from_parts(6_613_000, 0)
- .saturating_add(Weight::from_parts(0, 1533))
- .saturating_add(T::DbWeight::get().reads(2))
- .saturating_add(T::DbWeight::get().writes(2))
- }
-}
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/mod.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/mod.rs
index 691ed2e57304a1829de76b030a4ef5ed4b3f436f..2f1fcfb05f39151e018d74e8587faa0e79afd8b6 100644
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/mod.rs
@@ -18,9 +18,7 @@ pub mod cumulus_pallet_parachain_system;
pub mod cumulus_pallet_xcmp_queue;
pub mod extrinsic_weights;
pub mod frame_system;
-pub mod frame_system_extensions;
pub mod pallet_asset_conversion;
-pub mod pallet_asset_conversion_tx_payment;
pub mod pallet_assets_foreign;
pub mod pallet_assets_local;
pub mod pallet_assets_pool;
@@ -33,7 +31,6 @@ pub mod pallet_nfts;
pub mod pallet_proxy;
pub mod pallet_session;
pub mod pallet_timestamp;
-pub mod pallet_transaction_payment;
pub mod pallet_uniques;
pub mod pallet_utility;
pub mod pallet_xcm;
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_asset_conversion_tx_payment.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_asset_conversion_tx_payment.rs
deleted file mode 100644
index 8fe302630fb9510d0e1c01ca9de37a1bd0be3a4f..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_asset_conversion_tx_payment.rs
+++ /dev/null
@@ -1,92 +0,0 @@
-// Copyright (C) Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Cumulus is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Cumulus. If not, see .
-
-//! Autogenerated weights for `pallet_asset_conversion_tx_payment`
-//!
-//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
-//! DATE: 2024-01-04, STEPS: `2`, REPEAT: `2`, LOW RANGE: `[]`, HIGH RANGE: `[]`
-//! WORST CASE MAP SIZE: `1000000`
-//! HOSTNAME: `Georges-MacBook-Pro.local`, CPU: ``
-//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("asset-hub-westend-dev")`, DB CACHE: 1024
-
-// Executed Command:
-// ./target/debug/polkadot-parachain
-// benchmark
-// pallet
-// --wasm-execution=compiled
-// --pallet=pallet_asset_conversion_tx_payment
-// --no-storage-info
-// --no-median-slopes
-// --no-min-squares
-// --extrinsic=*
-// --steps=2
-// --repeat=2
-// --json
-// --header=./cumulus/file_header.txt
-// --output=./cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/
-// --chain=asset-hub-westend-dev
-
-#![cfg_attr(rustfmt, rustfmt_skip)]
-#![allow(unused_parens)]
-#![allow(unused_imports)]
-#![allow(missing_docs)]
-
-use frame_support::{traits::Get, weights::Weight};
-use core::marker::PhantomData;
-
-/// Weight functions for `pallet_asset_conversion_tx_payment`.
-pub struct WeightInfo(PhantomData);
-impl pallet_asset_conversion_tx_payment::WeightInfo for WeightInfo {
- fn charge_asset_tx_payment_zero() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 8_000_000 picoseconds.
- Weight::from_parts(9_000_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- /// Storage: `TransactionPayment::NextFeeMultiplier` (r:1 w:0)
- /// Proof: `TransactionPayment::NextFeeMultiplier` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`)
- /// Storage: `System::Account` (r:1 w:0)
- /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
- fn charge_asset_tx_payment_native() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `4`
- // Estimated: `3593`
- // Minimum execution time: 214_000_000 picoseconds.
- Weight::from_parts(219_000_000, 0)
- .saturating_add(Weight::from_parts(0, 3593))
- .saturating_add(T::DbWeight::get().reads(2))
- }
- /// Storage: `TransactionPayment::NextFeeMultiplier` (r:1 w:0)
- /// Proof: `TransactionPayment::NextFeeMultiplier` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`)
- /// Storage: `ForeignAssets::Asset` (r:1 w:1)
- /// Proof: `ForeignAssets::Asset` (`max_values`: None, `max_size`: Some(808), added: 3283, mode: `MaxEncodedLen`)
- /// Storage: `ForeignAssets::Account` (r:2 w:2)
- /// Proof: `ForeignAssets::Account` (`max_values`: None, `max_size`: Some(732), added: 3207, mode: `MaxEncodedLen`)
- /// Storage: `System::Account` (r:2 w:1)
- /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
- fn charge_asset_tx_payment_asset() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `631`
- // Estimated: `7404`
- // Minimum execution time: 1_211_000_000 picoseconds.
- Weight::from_parts(1_243_000_000, 0)
- .saturating_add(Weight::from_parts(0, 7404))
- .saturating_add(T::DbWeight::get().reads(6))
- .saturating_add(T::DbWeight::get().writes(4))
- }
-}
diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_transaction_payment.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_transaction_payment.rs
deleted file mode 100644
index b4c78a78b489073648156133730bd39cd3c68497..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_transaction_payment.rs
+++ /dev/null
@@ -1,67 +0,0 @@
-// Copyright (C) Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Cumulus is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Cumulus. If not, see .
-
-//! Autogenerated weights for `pallet_transaction_payment`
-//!
-//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
-//! DATE: 2023-12-21, STEPS: `2`, REPEAT: `2`, LOW RANGE: `[]`, HIGH RANGE: `[]`
-//! WORST CASE MAP SIZE: `1000000`
-//! HOSTNAME: `gleipnir`, CPU: `AMD Ryzen 9 7900X 12-Core Processor`
-//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("asset-hub-westend-dev")`, DB CACHE: 1024
-
-// Executed Command:
-// ./target/release/polkadot-parachain
-// benchmark
-// pallet
-// --wasm-execution=compiled
-// --pallet=pallet_transaction_payment
-// --no-storage-info
-// --no-median-slopes
-// --no-min-squares
-// --extrinsic=*
-// --steps=2
-// --repeat=2
-// --json
-// --header=./cumulus/file_header.txt
-// --output=./cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/
-// --chain=asset-hub-westend-dev
-
-#![cfg_attr(rustfmt, rustfmt_skip)]
-#![allow(unused_parens)]
-#![allow(unused_imports)]
-#![allow(missing_docs)]
-
-use frame_support::{traits::Get, weights::Weight};
-use core::marker::PhantomData;
-
-/// Weight functions for `pallet_transaction_payment`.
-pub struct WeightInfo(PhantomData);
-impl pallet_transaction_payment::WeightInfo for WeightInfo {
- /// Storage: `TransactionPayment::NextFeeMultiplier` (r:1 w:0)
- /// Proof: `TransactionPayment::NextFeeMultiplier` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`)
- /// Storage: `System::Account` (r:1 w:1)
- /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
- fn charge_transaction_payment() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `4`
- // Estimated: `3593`
- // Minimum execution time: 40_847_000 picoseconds.
- Weight::from_parts(49_674_000, 0)
- .saturating_add(Weight::from_parts(0, 3593))
- .saturating_add(T::DbWeight::get().reads(2))
- .saturating_add(T::DbWeight::get().writes(1))
- }
-}
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/Cargo.toml b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/Cargo.toml
index 242627815d3a5ced13a99d9f7f7c075e55c63200..7a1951fd24bd2d74ae722eef31b81dfdb28c8d9b 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/Cargo.toml
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/Cargo.toml
@@ -242,7 +242,6 @@ runtime-benchmarks = [
"pallet-message-queue/runtime-benchmarks",
"pallet-multisig/runtime-benchmarks",
"pallet-timestamp/runtime-benchmarks",
- "pallet-transaction-payment/runtime-benchmarks",
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
"pallet-xcm-bridge-hub/runtime-benchmarks",
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_to_bulletin_config.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_to_bulletin_config.rs
index 323e6ed65e69c22ae6be6f80bb26b4e6455bbb94..6dbf96edc2ab0360385b8e04bf1dc52732abd9ca 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_to_bulletin_config.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_to_bulletin_config.rs
@@ -40,7 +40,7 @@ use bridge_runtime_common::{
XcmBlobMessageDispatch, XcmVersionOfDestAndRemoteBridge,
},
refund_relayer_extension::{
- ActualFeeRefund, RefundBridgedGrandpaMessages, RefundTransactionExtensionAdapter,
+ ActualFeeRefund, RefundBridgedGrandpaMessages, RefundSignedExtensionAdapter,
RefundableMessagesLane,
},
};
@@ -168,7 +168,7 @@ impl messages::BridgedChainWithMessages for RococoBulletin {}
/// Signed extension that refunds relayers that are delivering messages from the Rococo Bulletin
/// chain.
-pub type OnBridgeHubRococoRefundRococoBulletinMessages = RefundTransactionExtensionAdapter<
+pub type OnBridgeHubRococoRefundRococoBulletinMessages = RefundSignedExtensionAdapter<
RefundBridgedGrandpaMessages<
Runtime,
BridgeGrandpaRococoBulletinInstance,
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_to_westend_config.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_to_westend_config.rs
index 05d1aa188d2d3abd114431e6ee388473dca8f982..5d55d7afbacfdb22f6939c88e87eaf64321945ff 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_to_westend_config.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/bridge_to_westend_config.rs
@@ -39,7 +39,7 @@ use bridge_runtime_common::{
XcmBlobMessageDispatch, XcmVersionOfDestAndRemoteBridge,
},
refund_relayer_extension::{
- ActualFeeRefund, RefundBridgedParachainMessages, RefundTransactionExtensionAdapter,
+ ActualFeeRefund, RefundBridgedParachainMessages, RefundSignedExtensionAdapter,
RefundableMessagesLane, RefundableParachain,
},
};
@@ -173,7 +173,7 @@ impl UnderlyingChainProvider for BridgeHubWestend {
impl messages::BridgedChainWithMessages for BridgeHubWestend {}
/// Signed extension that refunds relayers that are delivering messages from the Westend parachain.
-pub type OnBridgeHubRococoRefundBridgeHubWestendMessages = RefundTransactionExtensionAdapter<
+pub type OnBridgeHubRococoRefundBridgeHubWestendMessages = RefundSignedExtensionAdapter<
RefundBridgedParachainMessages<
Runtime,
RefundableParachain<
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/lib.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/lib.rs
index 16e3b2e8600f6df3721926b3ab597023d443bccc..0b48d1717fa96c4854371e44ae792d0ce41dc2e2 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/lib.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/lib.rs
@@ -115,8 +115,8 @@ pub type SignedBlock = generic::SignedBlock;
/// BlockId type as expected by this runtime.
pub type BlockId = generic::BlockId;
-/// The TransactionExtension to the basic transaction logic.
-pub type TxExtension = (
+/// The SignedExtension to the basic transaction logic.
+pub type SignedExtra = (
frame_system::CheckNonZeroSender,
frame_system::CheckSpecVersion,
frame_system::CheckTxVersion,
@@ -134,7 +134,7 @@ pub type TxExtension = (
/// Unchecked extrinsic type as expected by this runtime.
pub type UncheckedExtrinsic =
- generic::UncheckedExtrinsic;
+ generic::UncheckedExtrinsic;
/// Migrations to apply on runtime upgrade.
pub type Migrations = (
@@ -262,8 +262,6 @@ impl frame_system::Config for Runtime {
type DbWeight = RocksDbWeight;
/// Weight information for the extrinsics of this pallet.
type SystemWeightInfo = weights::frame_system::WeightInfo;
- /// Weight information for the extensions of this pallet.
- type ExtensionsWeightInfo = weights::frame_system_extensions::WeightInfo;
/// Block & extrinsics weights: base values and limits.
type BlockWeights = RuntimeBlockWeights;
/// The maximum length of a block (in bytes).
@@ -326,7 +324,6 @@ impl pallet_transaction_payment::Config for Runtime {
type WeightToFee = WeightToFee;
type LengthToFee = ConstantMultiplier;
type FeeMultiplierUpdate = SlowAdjustingFeeUpdate;
- type WeightInfo = weights::pallet_transaction_payment::WeightInfo;
}
parameter_types! {
@@ -762,14 +759,12 @@ bridge_runtime_common::generate_bridge_reject_obsolete_headers_and_messages! {
mod benches {
frame_benchmarking::define_benchmarks!(
[frame_system, SystemBench::]
- [frame_system_extensions, SystemExtensionsBench::]
[pallet_balances, Balances]
[pallet_message_queue, MessageQueue]
[pallet_multisig, Multisig]
[pallet_session, SessionBench::]
[pallet_utility, Utility]
[pallet_timestamp, Timestamp]
- [pallet_transaction_payment, TransactionPayment]
[pallet_collator_selection, CollatorSelection]
[cumulus_pallet_parachain_system, ParachainSystem]
[cumulus_pallet_xcmp_queue, XcmpQueue]
@@ -1070,7 +1065,6 @@ impl_runtime_apis! {
use frame_benchmarking::{Benchmarking, BenchmarkList};
use frame_support::traits::StorageInfoTrait;
use frame_system_benchmarking::Pallet as SystemBench;
- use frame_system_benchmarking::extensions::Pallet as SystemExtensionsBench;
use cumulus_pallet_session_benchmarking::Pallet as SessionBench;
use pallet_xcm::benchmarking::Pallet as PalletXcmExtrinsicsBenchmark;
@@ -1101,7 +1095,6 @@ impl_runtime_apis! {
use sp_storage::TrackedStorageKey;
use frame_system_benchmarking::Pallet as SystemBench;
- use frame_system_benchmarking::extensions::Pallet as SystemExtensionsBench;
impl frame_system_benchmarking::Config for Runtime {
fn setup_set_code_requirements(code: &sp_std::vec::Vec) -> Result<(), BenchmarkError> {
ParachainSystem::initialize_for_set_code_benchmark(code.len() as u32);
@@ -1485,16 +1478,16 @@ mod tests {
use codec::Encode;
use sp_runtime::{
generic::Era,
- traits::{TransactionExtensionBase, Zero},
+ traits::{SignedExtension, Zero},
};
#[test]
fn ensure_signed_extension_definition_is_compatible_with_relay() {
- use bp_polkadot_core::SuffixedCommonTransactionExtensionExt;
+ use bp_polkadot_core::SuffixedCommonSignedExtensionExt;
sp_io::TestExternalities::default().execute_with(|| {
frame_system::BlockHash::::insert(BlockNumber::zero(), Hash::default());
- let payload: TxExtension = (
+ let payload: SignedExtra = (
frame_system::CheckNonZeroSender::new(),
frame_system::CheckSpecVersion::new(),
frame_system::CheckTxVersion::new(),
@@ -1508,11 +1501,11 @@ mod tests {
bridge_to_westend_config::OnBridgeHubRococoRefundBridgeHubWestendMessages::default(),
bridge_to_bulletin_config::OnBridgeHubRococoRefundRococoBulletinMessages::default(),
)
- ).into();
+ );
// for BridgeHubRococo
{
- let bhr_indirect_payload = bp_bridge_hub_rococo::TransactionExtension::from_params(
+ let bhr_indirect_payload = bp_bridge_hub_rococo::SignedExtension::from_params(
VERSION.spec_version,
VERSION.transaction_version,
bp_runtime::TransactionEra::Immortal,
@@ -1523,8 +1516,8 @@ mod tests {
);
assert_eq!(payload.encode(), bhr_indirect_payload.encode());
assert_eq!(
- payload.implicit().unwrap().encode(),
- bhr_indirect_payload.implicit().unwrap().encode()
+ payload.additional_signed().unwrap().encode(),
+ bhr_indirect_payload.additional_signed().unwrap().encode()
)
}
});
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/frame_system_extensions.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/frame_system_extensions.rs
deleted file mode 100644
index 99e3d6aeba02349af3f4413a2e35d5a81a2a5073..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/frame_system_extensions.rs
+++ /dev/null
@@ -1,121 +0,0 @@
-// Copyright (C) Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Cumulus is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Cumulus. If not, see .
-
-//! Autogenerated weights for `frame_system_extensions`
-//!
-//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
-//! DATE: 2023-12-21, STEPS: `2`, REPEAT: `2`, LOW RANGE: `[]`, HIGH RANGE: `[]`
-//! WORST CASE MAP SIZE: `1000000`
-//! HOSTNAME: `gleipnir`, CPU: `AMD Ryzen 9 7900X 12-Core Processor`
-//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("bridge-hub-rococo-dev")`, DB CACHE: 1024
-
-// Executed Command:
-// ./target/release/polkadot-parachain
-// benchmark
-// pallet
-// --wasm-execution=compiled
-// --pallet=frame_system_extensions
-// --no-storage-info
-// --no-median-slopes
-// --no-min-squares
-// --extrinsic=*
-// --steps=2
-// --repeat=2
-// --json
-// --header=./cumulus/file_header.txt
-// --output=./cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/
-// --chain=bridge-hub-rococo-dev
-
-#![cfg_attr(rustfmt, rustfmt_skip)]
-#![allow(unused_parens)]
-#![allow(unused_imports)]
-#![allow(missing_docs)]
-
-use frame_support::{traits::Get, weights::Weight};
-use core::marker::PhantomData;
-
-/// Weight functions for `frame_system_extensions`.
-pub struct WeightInfo(PhantomData);
-impl frame_system::ExtensionsWeightInfo for WeightInfo {
- /// Storage: `System::BlockHash` (r:1 w:0)
- /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`)
- fn check_genesis() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `54`
- // Estimated: `3509`
- // Minimum execution time: 3_136_000 picoseconds.
- Weight::from_parts(5_842_000, 0)
- .saturating_add(Weight::from_parts(0, 3509))
- .saturating_add(T::DbWeight::get().reads(1))
- }
- /// Storage: `System::BlockHash` (r:1 w:0)
- /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`)
- fn check_mortality() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `92`
- // Estimated: `3509`
- // Minimum execution time: 5_771_000 picoseconds.
- Weight::from_parts(8_857_000, 0)
- .saturating_add(Weight::from_parts(0, 3509))
- .saturating_add(T::DbWeight::get().reads(1))
- }
- fn check_non_zero_sender() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 732_000 picoseconds.
- Weight::from_parts(2_875_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_nonce() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 3_627_000 picoseconds.
- Weight::from_parts(6_322_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_spec_version() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 471_000 picoseconds.
- Weight::from_parts(2_455_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_tx_version() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 491_000 picoseconds.
- Weight::from_parts(2_916_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- /// Storage: `System::AllExtrinsicsLen` (r:1 w:1)
- /// Proof: `System::AllExtrinsicsLen` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
- /// Storage: `System::BlockWeight` (r:1 w:1)
- /// Proof: `System::BlockWeight` (`max_values`: Some(1), `max_size`: Some(48), added: 543, mode: `MaxEncodedLen`)
- fn check_weight() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `24`
- // Estimated: `1533`
- // Minimum execution time: 3_798_000 picoseconds.
- Weight::from_parts(6_272_000, 0)
- .saturating_add(Weight::from_parts(0, 1533))
- .saturating_add(T::DbWeight::get().reads(2))
- .saturating_add(T::DbWeight::get().writes(2))
- }
-}
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/mod.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/mod.rs
index d97a30db9541bb01919f0a7a054f42d95816e875..aac39a4564fb600d9c4f623aa3ba27c78fc8f5fc 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/mod.rs
@@ -25,7 +25,6 @@ pub mod cumulus_pallet_parachain_system;
pub mod cumulus_pallet_xcmp_queue;
pub mod extrinsic_weights;
pub mod frame_system;
-pub mod frame_system_extensions;
pub mod pallet_balances;
pub mod pallet_bridge_grandpa;
pub mod pallet_bridge_messages_rococo_to_rococo_bulletin;
@@ -37,7 +36,6 @@ pub mod pallet_message_queue;
pub mod pallet_multisig;
pub mod pallet_session;
pub mod pallet_timestamp;
-pub mod pallet_transaction_payment;
pub mod pallet_utility;
pub mod pallet_xcm;
pub mod paritydb_weights;
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_transaction_payment.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_transaction_payment.rs
deleted file mode 100644
index 71d17e7259f72c023be3d75f37300c1a45c41d6f..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/pallet_transaction_payment.rs
+++ /dev/null
@@ -1,67 +0,0 @@
-// Copyright (C) Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Cumulus is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Cumulus. If not, see .
-
-//! Autogenerated weights for `pallet_transaction_payment`
-//!
-//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
-//! DATE: 2023-12-21, STEPS: `2`, REPEAT: `2`, LOW RANGE: `[]`, HIGH RANGE: `[]`
-//! WORST CASE MAP SIZE: `1000000`
-//! HOSTNAME: `gleipnir`, CPU: `AMD Ryzen 9 7900X 12-Core Processor`
-//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("bridge-hub-rococo-dev")`, DB CACHE: 1024
-
-// Executed Command:
-// ./target/release/polkadot-parachain
-// benchmark
-// pallet
-// --wasm-execution=compiled
-// --pallet=pallet_transaction_payment
-// --no-storage-info
-// --no-median-slopes
-// --no-min-squares
-// --extrinsic=*
-// --steps=2
-// --repeat=2
-// --json
-// --header=./cumulus/file_header.txt
-// --output=./cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/src/weights/
-// --chain=bridge-hub-rococo-dev
-
-#![cfg_attr(rustfmt, rustfmt_skip)]
-#![allow(unused_parens)]
-#![allow(unused_imports)]
-#![allow(missing_docs)]
-
-use frame_support::{traits::Get, weights::Weight};
-use core::marker::PhantomData;
-
-/// Weight functions for `pallet_transaction_payment`.
-pub struct WeightInfo(PhantomData);
-impl pallet_transaction_payment::WeightInfo for WeightInfo {
- /// Storage: `TransactionPayment::NextFeeMultiplier` (r:1 w:0)
- /// Proof: `TransactionPayment::NextFeeMultiplier` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`)
- /// Storage: `System::Account` (r:1 w:1)
- /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
- fn charge_transaction_payment() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `3`
- // Estimated: `3593`
- // Minimum execution time: 34_956_000 picoseconds.
- Weight::from_parts(40_788_000, 0)
- .saturating_add(Weight::from_parts(0, 3593))
- .saturating_add(T::DbWeight::get().reads(2))
- .saturating_add(T::DbWeight::get().writes(1))
- }
-}
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/snowbridge.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/snowbridge.rs
index 46c5df18a1586e77d0bc0f9eb5f9ed19fa689f59..239bd946e759b1c8aa1e892912b5bce8093bde00 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/snowbridge.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/snowbridge.rs
@@ -22,7 +22,7 @@ use bridge_hub_rococo_runtime::{
bridge_to_westend_config::OnBridgeHubRococoRefundBridgeHubWestendMessages,
xcm_config::XcmConfig, AllPalletsWithoutSystem, BridgeRejectObsoleteHeadersAndMessages,
Executive, MessageQueueServiceWeight, Runtime, RuntimeCall, RuntimeEvent, SessionKeys,
- TxExtension, UncheckedExtrinsic,
+ SignedExtra, UncheckedExtrinsic,
};
use codec::{Decode, Encode};
use cumulus_primitives_core::XcmError::{FailedToTransactAsset, NotHoldingFees};
@@ -171,7 +171,7 @@ fn construct_extrinsic(
call: RuntimeCall,
) -> UncheckedExtrinsic {
let account_id = AccountId32::from(sender.public());
- let tx_ext: TxExtension = (
+ let extra: SignedExtra = (
frame_system::CheckNonZeroSender::::new(),
frame_system::CheckSpecVersion::::new(),
frame_system::CheckTxVersion::::new(),
@@ -188,13 +188,13 @@ fn construct_extrinsic(
OnBridgeHubRococoRefundRococoBulletinMessages::default(),
),
);
- let payload = SignedPayload::new(call.clone(), tx_ext.clone()).unwrap();
+ let payload = SignedPayload::new(call.clone(), extra.clone()).unwrap();
let signature = payload.using_encoded(|e| sender.sign(e));
UncheckedExtrinsic::new_signed(
call,
account_id.into(),
Signature::Sr25519(signature.clone()),
- tx_ext,
+ extra,
)
}
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/tests.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/tests.rs
index 565343c55a5b66d4e2510cda01ba521ba6eee850..f11954cf165fdae2ee36377456b2bc4b2d6755a6 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/tests.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-rococo/tests/tests.rs
@@ -22,7 +22,7 @@ use bridge_hub_rococo_runtime::{
xcm_config::{RelayNetwork, TokenLocation, XcmConfig},
AllPalletsWithoutSystem, BridgeRejectObsoleteHeadersAndMessages, EthereumGatewayAddress,
Executive, ExistentialDeposit, ParachainSystem, PolkadotXcm, Runtime, RuntimeCall,
- RuntimeEvent, RuntimeOrigin, SessionKeys, TransactionPayment, TxExtension, UncheckedExtrinsic,
+ RuntimeEvent, RuntimeOrigin, SessionKeys, SignedExtra, TransactionPayment, UncheckedExtrinsic,
};
use bridge_hub_test_utils::SlotDurations;
use codec::{Decode, Encode};
@@ -48,7 +48,7 @@ fn construct_extrinsic(
call: RuntimeCall,
) -> UncheckedExtrinsic {
let account_id = AccountId32::from(sender.public());
- let tx_ext: TxExtension = (
+ let extra: SignedExtra = (
frame_system::CheckNonZeroSender::::new(),
frame_system::CheckSpecVersion::::new(),
frame_system::CheckTxVersion::::new(),
@@ -64,15 +64,14 @@ fn construct_extrinsic(
bridge_to_westend_config::OnBridgeHubRococoRefundBridgeHubWestendMessages::default(),
bridge_to_bulletin_config::OnBridgeHubRococoRefundRococoBulletinMessages::default(),
),
- )
- .into();
- let payload = SignedPayload::new(call.clone(), tx_ext.clone()).unwrap();
+ );
+ let payload = SignedPayload::new(call.clone(), extra.clone()).unwrap();
let signature = payload.using_encoded(|e| sender.sign(e));
UncheckedExtrinsic::new_signed(
call,
account_id.into(),
Signature::Sr25519(signature.clone()),
- tx_ext,
+ extra,
)
}
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/Cargo.toml b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/Cargo.toml
index b5fe093b8be79c21e3298548e07b8327004d2a26..8623f7cb366ecf3930b25563d6a912e53240d999 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/Cargo.toml
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/Cargo.toml
@@ -204,7 +204,6 @@ runtime-benchmarks = [
"pallet-message-queue/runtime-benchmarks",
"pallet-multisig/runtime-benchmarks",
"pallet-timestamp/runtime-benchmarks",
- "pallet-transaction-payment/runtime-benchmarks",
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
"pallet-xcm-bridge-hub/runtime-benchmarks",
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/bridge_to_rococo_config.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/bridge_to_rococo_config.rs
index 934dce5c2c481092fed1a73162e3f7b1f0967a11..bce722aa5f87d006af0ec71429d6c84eeab4972d 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/bridge_to_rococo_config.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/bridge_to_rococo_config.rs
@@ -36,7 +36,7 @@ use bridge_runtime_common::{
XcmBlobMessageDispatch, XcmVersionOfDestAndRemoteBridge,
},
refund_relayer_extension::{
- ActualFeeRefund, RefundBridgedParachainMessages, RefundTransactionExtensionAdapter,
+ ActualFeeRefund, RefundBridgedParachainMessages, RefundSignedExtensionAdapter,
RefundableMessagesLane, RefundableParachain,
},
};
@@ -190,7 +190,7 @@ impl ThisChainWithMessages for BridgeHubWestend {
}
/// Signed extension that refunds relayers that are delivering messages from the Rococo parachain.
-pub type OnBridgeHubWestendRefundBridgeHubRococoMessages = RefundTransactionExtensionAdapter<
+pub type OnBridgeHubWestendRefundBridgeHubRococoMessages = RefundSignedExtensionAdapter<
RefundBridgedParachainMessages<
Runtime,
RefundableParachain,
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/lib.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/lib.rs
index 86ed8b2f488c1c7d9ac389582754d05019a3e45c..e1344fce63dc9bad063c5b7f0d620a9a10bbf666 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/lib.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/lib.rs
@@ -97,8 +97,8 @@ pub type SignedBlock = generic::SignedBlock;
/// BlockId type as expected by this runtime.
pub type BlockId = generic::BlockId;
-/// The TransactionExtension to the basic transaction logic.
-pub type TxExtension = (
+/// The SignedExtension to the basic transaction logic.
+pub type SignedExtra = (
frame_system::CheckNonZeroSender,
frame_system::CheckSpecVersion,
frame_system::CheckTxVersion,
@@ -113,7 +113,7 @@ pub type TxExtension = (
/// Unchecked extrinsic type as expected by this runtime.
pub type UncheckedExtrinsic =
- generic::UncheckedExtrinsic;
+ generic::UncheckedExtrinsic;
/// Migrations to apply on runtime upgrade.
pub type Migrations = (
@@ -298,7 +298,6 @@ impl pallet_transaction_payment::Config for Runtime {
type WeightToFee = WeightToFee;
type LengthToFee = ConstantMultiplier;
type FeeMultiplierUpdate = SlowAdjustingFeeUpdate;
- type WeightInfo = weights::pallet_transaction_payment::WeightInfo;
}
parameter_types! {
@@ -516,14 +515,12 @@ bridge_runtime_common::generate_bridge_reject_obsolete_headers_and_messages! {
mod benches {
frame_benchmarking::define_benchmarks!(
[frame_system, SystemBench::]
- [frame_system_extensions, SystemExtensionsBench::]
[pallet_balances, Balances]
[pallet_message_queue, MessageQueue]
[pallet_multisig, Multisig]
[pallet_session, SessionBench::]
[pallet_utility, Utility]
[pallet_timestamp, Timestamp]
- [pallet_transaction_payment, TransactionPayment]
[pallet_collator_selection, CollatorSelection]
[cumulus_pallet_parachain_system, ParachainSystem]
[cumulus_pallet_xcmp_queue, XcmpQueue]
@@ -764,7 +761,6 @@ impl_runtime_apis! {
use frame_benchmarking::{Benchmarking, BenchmarkList};
use frame_support::traits::StorageInfoTrait;
use frame_system_benchmarking::Pallet as SystemBench;
- use frame_system_benchmarking::extensions::Pallet as SystemExtensionsBench;
use cumulus_pallet_session_benchmarking::Pallet as SessionBench;
use pallet_xcm::benchmarking::Pallet as PalletXcmExtrinsicsBenchmark;
@@ -794,7 +790,6 @@ impl_runtime_apis! {
use sp_storage::TrackedStorageKey;
use frame_system_benchmarking::Pallet as SystemBench;
- use frame_system_benchmarking::extensions::Pallet as SystemExtensionsBench;
impl frame_system_benchmarking::Config for Runtime {
fn setup_set_code_requirements(code: &sp_std::vec::Vec) -> Result<(), BenchmarkError> {
ParachainSystem::initialize_for_set_code_benchmark(code.len() as u32);
@@ -1140,16 +1135,16 @@ mod tests {
use codec::Encode;
use sp_runtime::{
generic::Era,
- traits::{TransactionExtensionBase, Zero},
+ traits::{SignedExtension, Zero},
};
#[test]
fn ensure_signed_extension_definition_is_compatible_with_relay() {
- use bp_polkadot_core::SuffixedCommonTransactionExtensionExt;
+ use bp_polkadot_core::SuffixedCommonSignedExtensionExt;
sp_io::TestExternalities::default().execute_with(|| {
frame_system::BlockHash::::insert(BlockNumber::zero(), Hash::default());
- let payload: TxExtension = (
+ let payload: SignedExtra = (
frame_system::CheckNonZeroSender::new(),
frame_system::CheckSpecVersion::new(),
frame_system::CheckTxVersion::new(),
@@ -1162,10 +1157,10 @@ mod tests {
(
bridge_to_rococo_config::OnBridgeHubWestendRefundBridgeHubRococoMessages::default(),
),
- ).into();
+ );
{
- let bh_indirect_payload = bp_bridge_hub_westend::TransactionExtension::from_params(
+ let bh_indirect_payload = bp_bridge_hub_westend::SignedExtension::from_params(
VERSION.spec_version,
VERSION.transaction_version,
bp_runtime::TransactionEra::Immortal,
@@ -1176,8 +1171,8 @@ mod tests {
);
assert_eq!(payload.encode(), bh_indirect_payload.encode());
assert_eq!(
- payload.implicit().unwrap().encode(),
- bh_indirect_payload.implicit().unwrap().encode()
+ payload.additional_signed().unwrap().encode(),
+ bh_indirect_payload.additional_signed().unwrap().encode()
)
}
});
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/frame_system_extensions.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/frame_system_extensions.rs
deleted file mode 100644
index 06f1114b4dea90cc9d830ff1f492428f3672b202..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/frame_system_extensions.rs
+++ /dev/null
@@ -1,121 +0,0 @@
-// Copyright (C) Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Cumulus is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Cumulus. If not, see .
-
-//! Autogenerated weights for `frame_system_extensions`
-//!
-//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
-//! DATE: 2023-12-21, STEPS: `2`, REPEAT: `2`, LOW RANGE: `[]`, HIGH RANGE: `[]`
-//! WORST CASE MAP SIZE: `1000000`
-//! HOSTNAME: `gleipnir`, CPU: `AMD Ryzen 9 7900X 12-Core Processor`
-//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("bridge-hub-westend-dev")`, DB CACHE: 1024
-
-// Executed Command:
-// ./target/release/polkadot-parachain
-// benchmark
-// pallet
-// --wasm-execution=compiled
-// --pallet=frame_system_extensions
-// --no-storage-info
-// --no-median-slopes
-// --no-min-squares
-// --extrinsic=*
-// --steps=2
-// --repeat=2
-// --json
-// --header=./cumulus/file_header.txt
-// --output=./cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/
-// --chain=bridge-hub-westend-dev
-
-#![cfg_attr(rustfmt, rustfmt_skip)]
-#![allow(unused_parens)]
-#![allow(unused_imports)]
-#![allow(missing_docs)]
-
-use frame_support::{traits::Get, weights::Weight};
-use core::marker::PhantomData;
-
-/// Weight functions for `frame_system_extensions`.
-pub struct WeightInfo(PhantomData);
-impl frame_system::ExtensionsWeightInfo for WeightInfo {
- /// Storage: `System::BlockHash` (r:1 w:0)
- /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`)
- fn check_genesis() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `54`
- // Estimated: `3509`
- // Minimum execution time: 3_166_000 picoseconds.
- Weight::from_parts(6_021_000, 0)
- .saturating_add(Weight::from_parts(0, 3509))
- .saturating_add(T::DbWeight::get().reads(1))
- }
- /// Storage: `System::BlockHash` (r:1 w:0)
- /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`)
- fn check_mortality() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `92`
- // Estimated: `3509`
- // Minimum execution time: 5_651_000 picoseconds.
- Weight::from_parts(9_177_000, 0)
- .saturating_add(Weight::from_parts(0, 3509))
- .saturating_add(T::DbWeight::get().reads(1))
- }
- fn check_non_zero_sender() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 601_000 picoseconds.
- Weight::from_parts(2_805_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_nonce() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 3_727_000 picoseconds.
- Weight::from_parts(6_051_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_spec_version() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 471_000 picoseconds.
- Weight::from_parts(2_494_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- fn check_tx_version() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `0`
- // Estimated: `0`
- // Minimum execution time: 521_000 picoseconds.
- Weight::from_parts(2_655_000, 0)
- .saturating_add(Weight::from_parts(0, 0))
- }
- /// Storage: `System::AllExtrinsicsLen` (r:1 w:1)
- /// Proof: `System::AllExtrinsicsLen` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
- /// Storage: `System::BlockWeight` (r:1 w:1)
- /// Proof: `System::BlockWeight` (`max_values`: Some(1), `max_size`: Some(48), added: 543, mode: `MaxEncodedLen`)
- fn check_weight() -> Weight {
- // Proof Size summary in bytes:
- // Measured: `24`
- // Estimated: `1533`
- // Minimum execution time: 3_808_000 picoseconds.
- Weight::from_parts(6_402_000, 0)
- .saturating_add(Weight::from_parts(0, 1533))
- .saturating_add(T::DbWeight::get().reads(2))
- .saturating_add(T::DbWeight::get().writes(2))
- }
-}
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/mod.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/mod.rs
index e23033e0dfd313c60fe53f64a49ad2237477ecb5..a65ee31d3e55ff8135fdd7dec35120e0a463409b 100644
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/mod.rs
+++ b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/mod.rs
@@ -25,7 +25,6 @@ pub mod cumulus_pallet_parachain_system;
pub mod cumulus_pallet_xcmp_queue;
pub mod extrinsic_weights;
pub mod frame_system;
-pub mod frame_system_extensions;
pub mod pallet_balances;
pub mod pallet_bridge_grandpa;
pub mod pallet_bridge_messages;
@@ -36,7 +35,6 @@ pub mod pallet_message_queue;
pub mod pallet_multisig;
pub mod pallet_session;
pub mod pallet_timestamp;
-pub mod pallet_transaction_payment;
pub mod pallet_utility;
pub mod pallet_xcm;
pub mod paritydb_weights;
diff --git a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/pallet_transaction_payment.rs b/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/pallet_transaction_payment.rs
deleted file mode 100644
index 92c53b918792257ddf932148fa10a4ba8016653f..0000000000000000000000000000000000000000
--- a/cumulus/parachains/runtimes/bridge-hubs/bridge-hub-westend/src/weights/pallet_transaction_payment.rs
+++ /dev/null
@@ -1,67 +0,0 @@
-// Copyright (C) Parity Technologies (UK) Ltd.
-// This file is part of Cumulus.
-
-// Cumulus is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Cumulus is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Cumulus. If not, see