-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Don't use fixed nominator count for report_equivocation weight calculation #14471
Don't use fixed nominator count for report_equivocation weight calculation #14471
Conversation
I struggle a bit with the idea that a consensus algorithm is so strictly bound to a staking concept such as nominators (that in practice is not mandatory to be used). Isn't better to set this once and read from some external source? (Just an idea) What about providing a |
@davxy I agree that currently the weight implementation is highly coupled with the existing staking implementation. We can probably abstract it in a way to decrease this coupling, although TBH I'm not sure how valuable that would be. Moving this to the staking pallet would make it depend on the internals of GRANDPA (basically reversing the coupling). And the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
bot merge |
…ation (paritytech#14471) * babe: fix report_equivocation weight calculation * grandpa: fix report_equivocation weight calculation * beefy: fix report_equivocation weight calculation * runtime: add missing MaxNominators constant
…ation (#14471) * babe: fix report_equivocation weight calculation * grandpa: fix report_equivocation weight calculation * beefy: fix report_equivocation weight calculation * runtime: add missing MaxNominators constant
This PR changes the
report_equivocation
weight calculation to take into account the runtime configured maximum number of nominators per validator, rather than using a constant value.polkadot companion: paritytech/polkadot#7432