Preserve failed validator incentive vesting payments instead of dropping them#12615
Preserve failed validator incentive vesting payments instead of dropping them#12615andreitrand wants to merge 5 commits into
Conversation
Vested payments that can't be processed due to insufficient vesting capacity now get stored into a staging account unique to that validator. Vesting data (start and duration) get discarded. The staged amount is colleted and paid together with the very next vested payment, inheriting the latter's start and duration.
c61afd8 to
b2ea5d9
Compare
|
One philosophical question: if I get it right, recovery is coupled to a future successful payout. |
That's correct - we depend on staking to make at least 1 more successful vested payout after a failed one in order to also grab the latter's balance. This is in line with what we discussed together with @Ank4n, but now that you mention it, it doesn't look ideal. We could also change the architecture to use a global buffer (a |
Another random idea: what if on a capacity failure, we merge the amount into the validator's most-recent existing |
This is a really good idea. Its less logic as well. Should have just tests to ensure validators don't get any advantage when merging to older schedule. @andreitrand wdyt? |
I've updated the logic to now merge a failed vesting schedule's amount with the existing schedule with the closest schedule end. This means that a schedule that can't be added due to capacity now always succeeds, albeit at a potentially different vesting rate. Also, note that this logic applies only to System (trusted) vesting schedules, which remain completely disjoint from public schedules. In the case of the latter, failures due to insufficient capacity still occur but lead to a very visible extrinsic failure. |
|
All GitHub workflows were cancelled due to failure one of the required jobs. |
The current solution from #12210 is to have vested system payments for validators dropped if there is no vesting capacity available. This was deemed to not be an acceptable solution (see this comment) so this PR proposes an alternative: