Page MenuHomePhabricator

Merge #12861: [tests] Stop feature_block.py from blowing up memory.
ClosedPublic

Authored by markblundeberg on Jul 1 2019, 03:34.

Details

Summary

PR12861 backport https://github.com/bitcoin/bitcoin/pull/12861/files
89fe5feea2 [tests] Stop feature_block.py from blowing up memory. (John Newbery)

Pull request description:

The new P2PDataStore class was sending full blocks in headers messages,
which meant that calls to send_blocks_and_test() would blow up memory if
called with a large number of blocks. Fix that by only sending headers
in headers messages.

This means that python should use just over 1GB for feature_block.py (with bitcoind also using just over 1GB). That's the same as before the feature_block.py refactor.

Backporter note: our feature_block.py isn't updated to use this yet, so we
don't have the bug. But it's good to bring this fix in now.

Depends on D3494

Test Plan

test_runner.py

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision is now accepted and ready to land.Jul 1 2019, 21:14