Page MenuHomePhabricator

Read in consensus defaults.
ClosedPublic

Authored by freetrader on Jul 9 2017, 14:41.

Details

Summary

Now that we have a get_srcdir() utility function,
we can determine the location of consensus.h more reliably.

Avoids duplication of these default definitions.

Test Plan

../qa/pull-tester/rpc-tests.py -extended

Diff Detail

Repository
rABC Bitcoin ABC
Branch
fix_cdefs_reading_from_consensus
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 471
Build 471: arc lint + arc unit

Event Timeline

Herald added 1 blocking reviewer(s): Restricted Project. · View Herald TranscriptJul 9 2017, 14:41
deadalnix added inline comments.
qa/rpc-tests/test_framework/cdefs.py
31

Don't use eval. Parse the int.

This revision is now accepted and ready to land.Jul 9 2017, 18:19
This revision was automatically updated to reflect the committed changes.
qa/rpc-tests/test_framework/cdefs.py
35 ↗(On Diff #763)

Going to change this one to use int parsing.

31

Parsing the int would work for DEFAULT_UAHF_START_TIME, but not for DEFAULT_MAX_BLOCK_SIZE unless we change the C++ definition to an integer instead of the expression 8 * ONE_MEGABYTE.