Page MenuHomePhabricator

Do not unpark children of blocks outside of the RPC
ClosedPublic

Authored by deadalnix on Nov 13 2018, 02:42.

Details

Summary

As per title. When unparking chain automatically, we do not want to unpark all children by default. Only the RPC should do this.

Depends on D2004

Test Plan
make check
./test/functional/test_runner.py --extended

Diff Detail

Repository
rABC Bitcoin ABC
Branch
unparkrefac
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 3878
Build 5829: Bitcoin ABC Buildbot (legacy)
Build 5828: arc lint + arc unit

Event Timeline

deadalnix changed the edit policy from "All Users" to "Restricted Project (Project)".
deadalnix changed the visibility from "Public (No Login Required)" to "Restricted Project (Project)".
jasonbcox requested changes to this revision.Nov 13 2018, 02:55
jasonbcox added a subscriber: jasonbcox.
jasonbcox added inline comments.
src/validation.cpp
2923

Seeing that both UnparkBlockAndChildren() and UnparkBlock() return true, it's probably better design-wise to make UnparkBlockImpl return bool type and have it return true at the end of the function. Then those two functions just return UnparkBlockImpl(...);

This revision now requires changes to proceed.Nov 13 2018, 02:55

Have UnparkBlockImpl return true

jasonbcox requested changes to this revision.Nov 13 2018, 03:18

Ideally this would come with a test. Something like node0: A -> B (parked) --------> C -> D (chaintip) B -> E (parked-parent and parked). node1 goes through IBD and E remains parked.

This revision now requires changes to proceed.Nov 13 2018, 03:18
deadalnix added a child revision: Restricted Differential Revision.Nov 13 2018, 16:11

Created a task to cover the test in the future: T484 (task has limited visibility)

This revision is now accepted and ready to land.Nov 18 2018, 01:19
deadalnix changed the visibility from "Restricted Project (Project)" to "Public (No Login Required)".Nov 20 2018, 16:28
This revision was automatically updated to reflect the committed changes.