Skip to content

Commit

Permalink
tmp fix: account for validation data size in the estimated PoV (2)
Browse files Browse the repository at this point in the history
  • Loading branch information
librelois authored and rimbi committed Sep 25, 2023
1 parent 0530277 commit 1698e0f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cumulus/pallets/parachain-system/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -494,8 +494,12 @@ pub mod pallet {
"ValidationData must be updated only once in a block",
);

let data_len = data.encoded_size() as u64;

// TODO: This is more than zero, but will need benchmarking to figure out what.
let mut total_weight = Weight::zero();
// MOONBEAM TODO: custom weight to account for validation data size is the PoV
// until https://github.com/paritytech/substrate/issues/13810 it's properly fix.
let mut total_weight = Weight::from_parts(0, data_len);

// NOTE: the inherent data is expected to be unique, even if this block is built
// in the context of the same relay parent as the previous one. In particular,
Expand Down

0 comments on commit 1698e0f

Please sign in to comment.