Fixes #29860
As a result of node1 receiving a block, it sends out SENDCMPCT messages to some of its peers to update the high-bandwidth status. We need to wait until those are received and processed by the peers to avoid intermittent failures. Before, we’d only wait until all peers have synced with the new block (within generate
) which is not sufficient.
I could reproduce the failure by adding a std::this_thread::sleep_for(std::chrono::milliseconds(1000));
sleep to the net_processing code that processes NetMsgType::SENDCMPCT
.