Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

ExtrinsicSuccess reports wrong weight consumption #12252

Closed
ggwpez opened this issue Sep 13, 2022 · 0 comments · Fixed by #12329
Closed

ExtrinsicSuccess reports wrong weight consumption #12252

ggwpez opened this issue Sep 13, 2022 · 0 comments · Fixed by #12329
Labels
I3-bug The node fails to follow expected behavior. U2-some_time_soon Issue is worth doing soon.

Comments

@ggwpez
Copy link
Member

ggwpez commented Sep 13, 2022

Observation

The weight that ExtrinsicSuccess reports does not contain the ExtrinsicBaseWeight.
Example output from PolkadotJS after setting System.Remark weight to 0:

wrong weight return

This should report the ExtrinsicBaseWeight of ~86µs but just shows 0 instead.
The System::extract_actual_weight does not account for this. It is being respected in check_block_weight and also in the fee logic, so more of a "cosmetic" issue. Querying System.BlockWeight also reports the correct value.

Thanks to @notlesh for bringing attention to this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
I3-bug The node fails to follow expected behavior. U2-some_time_soon Issue is worth doing soon.
Projects
Development

Successfully merging a pull request may close this issue.

1 participant