dynafed: Support changing mainnet dynafed activation

This should obviously only be done by blocksigners. The flag used is not
documented.
This commit is contained in:
Steven Roose 2021-02-09 13:10:04 +01:00
parent 0f9b1a2ed1
commit ae54a1bad4
No known key found for this signature in database
GPG key ID: 2F2A88D7F8D68E87
2 changed files with 5 additions and 2 deletions

View file

@ -882,9 +882,10 @@ public:
consensus.vDeployments[Consensus::DEPLOYMENT_TESTDUMMY].nStartTime = 0;
consensus.vDeployments[Consensus::DEPLOYMENT_TESTDUMMY].nTimeout = Consensus::BIP9Deployment::NO_TIMEOUT;
// Not active yet.
// Activated from block 1,000,000.
consensus.vDeployments[Consensus::DEPLOYMENT_DYNA_FED].bit = 25;
consensus.vDeployments[Consensus::DEPLOYMENT_DYNA_FED].nStartTime = 1000000;
// Allow blocksigners to delay activation.
consensus.vDeployments[Consensus::DEPLOYMENT_DYNA_FED].nStartTime = gArgs.GetArg("-con_dyna_deploy_start", 1000000);
consensus.vDeployments[Consensus::DEPLOYMENT_DYNA_FED].nTimeout = Consensus::BIP9Deployment::NO_TIMEOUT;

View file

@ -66,6 +66,8 @@ class DynaFedTest(BitcoinTestFramework):
self.extra_args = [["-con_dyna_deploy_start=1000", "-enforce_pak=1", "-con_parent_chain_signblockscript=51", "-peginconfirmationdepth=1", "-parentscriptprefix=75", "-parent_bech32_hrp=ert"] for i in range(self.num_nodes)]
# second node will not mine transactions
self.extra_args[1].append("-blocksonly=1")
# Make sure nothing breaks if peers have a different activation.
self.extra_args[1][0] = "-con_dyna_deploy_start=937"
def skip_test_if_missing_module(self):
self.skip_if_no_wallet()