[stable2409] Backport #6973#7160
Conversation
There is a problem on restart where nodes will not trigger their needed assignment if they were offline while the time of the assignment passed. That happens because after restart we will hit this condition https://github.com/paritytech/polkadot-sdk/blob/4e805ca05067f6ed970f33f9be51483185b0cc0b/polkadot/node/core/approval-voting/src/lib.rs#L2495 and considered will be `tick_now` which is already higher than the tick of our assignment. The fix is to schedule a wakeup for untriggered assignments at restart and let the logic of processing an wakeup decide if it needs to trigger the assignment or not. One thing that we need to be careful here is to make sure we don't schedule the wake up immediately after restart because, the node would still be behind with all the assignments that should have received and might make it wrongfully decide it needs to trigger its assignment, so I added a `RESTART_WAKEUP_DELAY: Tick = 12` which should be more than enough for the node to catch up. --------- Signed-off-by: Alexandru Gheorghe <alexandru.gheorghe@parity.io> Co-authored-by: ordian <write@reusable.software> Co-authored-by: Andrei Eres <eresav@me.com> (cherry picked from commit d38bb95)
|
This pull request is amending an existing release. Please proceed with extreme caution,
Emergency Bypass
If you really need to bypass this check: add |
|
The CI pipeline was cancelled due to failure one of the required jobs. |
|
@alexggh Alex, could you please double check the failing tests: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/8016751 |
Signed-off-by: Alexandru Gheorghe <alexandru.gheorghe@parity.io>
it was a unnittest that was using functions added later, I fixed it. |
Backport #6973 into
stable2409from alexggh.See the documentation on how to use this bot.