Skip to content

Commit 5413a4e

Browse files
authored
Fix StorageWeightReclaim usage after updating to polkadot 2503 (#1691)
1 parent b146521 commit 5413a4e

File tree

4 files changed

+15
-17
lines changed

4 files changed

+15
-17
lines changed

Cargo.lock

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

template/node/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,6 @@ fp-rpc = { workspace = true, features = ["default"] }
8181
frontier-template-runtime = { workspace = true, features = ["std"] }
8282

8383
# Cumulus primitives
84-
cumulus-pallet-weight-reclaim = { workspace = true }
8584
cumulus-primitives-proof-size-hostfunction = { workspace = true }
8685

8786
[build-dependencies]

template/node/src/benchmarking.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ pub fn create_benchmark_extrinsic(
121121
.checked_next_power_of_two()
122122
.map(|c| c / 2)
123123
.unwrap_or(2) as u64;
124-
let extra: runtime::SignedExtra = (
124+
let extra = runtime::SignedExtra::new((
125125
frame_system::CheckNonZeroSender::<runtime::Runtime>::new(),
126126
frame_system::CheckSpecVersion::<runtime::Runtime>::new(),
127127
frame_system::CheckTxVersion::<runtime::Runtime>::new(),
@@ -133,8 +133,7 @@ pub fn create_benchmark_extrinsic(
133133
frame_system::CheckNonce::<runtime::Runtime>::from(nonce),
134134
frame_system::CheckWeight::<runtime::Runtime>::new(),
135135
pallet_transaction_payment::ChargeTransactionPayment::<runtime::Runtime>::from(0),
136-
cumulus_pallet_weight_reclaim::StorageWeightReclaim::<runtime::Runtime, ()>::new(()),
137-
);
136+
));
138137

139138
let raw_payload = runtime::SignedPayload::from_raw(
140139
call.clone(),
@@ -148,7 +147,6 @@ pub fn create_benchmark_extrinsic(
148147
(),
149148
(),
150149
(),
151-
(),
152150
),
153151
);
154152
let signature = raw_payload.using_encoded(|e| sender.sign(e));

template/runtime/src/lib.rs

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -109,17 +109,19 @@ pub type SignedBlock = generic::SignedBlock<Block>;
109109
pub type BlockId = generic::BlockId<Block>;
110110

111111
/// The SignedExtension to the basic transaction logic.
112-
pub type SignedExtra = (
113-
frame_system::CheckNonZeroSender<Runtime>,
114-
frame_system::CheckSpecVersion<Runtime>,
115-
frame_system::CheckTxVersion<Runtime>,
116-
frame_system::CheckGenesis<Runtime>,
117-
frame_system::CheckEra<Runtime>,
118-
frame_system::CheckNonce<Runtime>,
119-
frame_system::CheckWeight<Runtime>,
120-
pallet_transaction_payment::ChargeTransactionPayment<Runtime>,
121-
cumulus_pallet_weight_reclaim::StorageWeightReclaim<Runtime, ()>,
122-
);
112+
pub type SignedExtra = cumulus_pallet_weight_reclaim::StorageWeightReclaim<
113+
Runtime,
114+
(
115+
frame_system::CheckNonZeroSender<Runtime>,
116+
frame_system::CheckSpecVersion<Runtime>,
117+
frame_system::CheckTxVersion<Runtime>,
118+
frame_system::CheckGenesis<Runtime>,
119+
frame_system::CheckEra<Runtime>,
120+
frame_system::CheckNonce<Runtime>,
121+
frame_system::CheckWeight<Runtime>,
122+
pallet_transaction_payment::ChargeTransactionPayment<Runtime>,
123+
),
124+
>;
123125

124126
/// Unchecked extrinsic type as expected by this runtime.
125127
pub type UncheckedExtrinsic =

0 commit comments

Comments
 (0)