Fix vote route cleanup racing with dispatched votes and blocks The vote router looks a route up under its lock and releases it before delivering the vote, so a vote can reach an election after the route it was dispatched through has been pruned: either the last supporting vote for an evicted fork moved away, or a publish evicted the unsupported block. The election then records a current vote for an unheld hash that nothing routes, and later votes for it fall back to the vote cache. An accepted vote for an unheld hash now routes it again, so both orderings converge on the same routes. Erasing a live election left it able to accept blocks and votes already dispatched to it and to register routes after its disconnect. The erase now cancels the election before disconnecting it, and the cancel reports the state it found so stats and logs describe the election as it was erased.
__________
Type: commit
Hash: d924a9ed450144ae71bc25b80a2fd35a333dfac0
Created: yesterday
__________
gr0v1ty/nano-node:d924a9ed450144ae71bc25b80a2fd35a333dfac0
| Test Case | Status | Duration | Median Deviation | Log | Graph |
|---|