forked from dashpay/dash
-
Notifications
You must be signed in to change notification settings - Fork 720
[Consensus] Start new Testnet (v5) #2069
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Fuzzbawls
merged 5 commits into
PIVX-Project:master
from
random-zebra:202012_testnet5_rebased
Dec 19, 2020
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
763b531
BUG: Miner don't check for PoS activation at negative height
random-zebra cb1f9a0
Params: change testnet datadir to testnet5
random-zebra b05ed1c
Params: Update testnet params - remove unused ones
random-zebra 2ebb986
Params: Fix PoS block value for testnet to 5
random-zebra ff82174
Params: clear testnet checkpoints
random-zebra File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -99,16 +99,12 @@ static const Checkpoints::CCheckpointData data = { | |
|
|
||
| static Checkpoints::MapCheckpoints mapCheckpointsTestnet = | ||
| boost::assign::map_list_of | ||
| (0, uint256S("0x001")) | ||
| (1016800, uint256S("6ae7d52092fd918c8ac8d9b1334400387d3057997e6e927a88e57186dc395231")) | ||
| (1106100, uint256S("c54b3e7e8b710e4075da1806adf2d508ae722627d5bcc43f594cf64d5eef8b30")) //!< zc public spend activation height | ||
| (1112700, uint256S("2ad8d507dbe3d3841b9f8a29c3878d570228e9361c3e057362d7915777bbc849")) | ||
| (1347000, uint256S("30c173ffc09a13f288bf6e828216107037ce5b79536b1cebd750a014f4939882")) //!< First v7 block | ||
| (1608352, uint256S("34a1ae222b2794f34b13e87b34c6ab1b0849c80c372ca0070ceab77a83534f15")); //!< PIVX v4.1.1 enforced | ||
| (0, uint256S("0x001")); | ||
| //(201, uint256S("6ae7d52092fd918c8ac8d9b1334400387d3057997e6e927a88e57186dc395231")); // v5 activation (PoS/Sapling) | ||
| static const Checkpoints::CCheckpointData dataTestnet = { | ||
| &mapCheckpointsTestnet, | ||
| 1591225230, | ||
| 3501914, | ||
| 1454124731, | ||
| 0, | ||
| 3000}; | ||
|
|
||
| static Checkpoints::MapCheckpoints mapCheckpointsRegtest = | ||
|
|
@@ -256,7 +252,7 @@ class CMainParams : public CChainParams | |
| static CMainParams mainParams; | ||
|
|
||
| /** | ||
| * Testnet (v3) | ||
| * Testnet (v5) | ||
| */ | ||
| class CTestNetParams : public CMainParams | ||
| { | ||
|
|
@@ -278,11 +274,6 @@ class CTestNetParams : public CMainParams | |
| consensus.nBudgetCycleBlocks = 144; // approx 10 cycles per day | ||
| consensus.nBudgetFeeConfirmations = 3; // (only 8-blocks window for finalization on testnet) | ||
| consensus.nCoinbaseMaturity = 15; | ||
| consensus.nFutureTimeDriftPoW = 7200; | ||
| consensus.nFutureTimeDriftPoS = 180; | ||
| consensus.nMasternodeCountDrift = 4; // num of MN we allow the see-saw payments to be off by | ||
| consensus.nMaxMoneyOut = 43199500 * COIN; | ||
| consensus.nPoolMaxTransactions = 2; | ||
| consensus.nProposalEstablishmentTime = 60 * 5; // at least 5 min old to make it into a budget | ||
| consensus.nStakeMinAge = 60 * 60; | ||
| consensus.nStakeMinDepth = 100; | ||
|
|
@@ -298,67 +289,38 @@ class CTestNetParams : public CMainParams | |
| consensus.nTime_RejectOldSporkKey = 1569538800; //!> September 26, 2019 11:00:00 PM GMT | ||
|
|
||
| // height based activations | ||
| consensus.height_last_ZC_AccumCheckpoint = 1106090; | ||
| consensus.height_last_ZC_AccumCheckpoint = -1; | ||
| consensus.height_last_ZC_WrappedSerials = -1; | ||
| consensus.height_start_InvalidUTXOsCheck = 999999999; | ||
| consensus.height_start_ZC_InvalidSerials = 999999999; | ||
| consensus.height_start_ZC_SerialRangeCheck = 1; | ||
| consensus.height_ZC_RecalcAccumulators = 999999999; | ||
|
|
||
| // validation by-pass | ||
| consensus.nPivxBadBlockTime = 1489001494; // Skip nBit validation of Block 201 per PR #915 | ||
| consensus.nPivxBadBlockBits = 0x1e0a20bd; // Skip nBit validation of Block 201 per PR #915 | ||
|
|
||
| // Zerocoin-related params | ||
| consensus.ZC_Modulus = "25195908475657893494027183240048398571429282126204032027777137836043662020707595556264018525880784" | ||
| "4069182906412495150821892985591491761845028084891200728449926873928072877767359714183472702618963750149718246911" | ||
| "6507761337985909570009733045974880842840179742910064245869181719511874612151517265463228221686998754918242243363" | ||
| "7259085141865462043576798423387184774447920739934236584823824281198163815010674810451660377306056201619676256133" | ||
| "8441436038339044149526344321901146575444541784240209246165157233507787077498171257724679629263863563732899121548" | ||
| "31438167899885040445364023527381951378636564391212010397122822120720357"; | ||
| consensus.ZC_MaxPublicSpendsPerTx = 637; // Assume about 220 bytes each input | ||
| consensus.ZC_MaxSpendsPerTx = 7; // Assume about 20kb each input | ||
| consensus.ZC_MinMintConfirmations = 20; | ||
| consensus.ZC_MinMintFee = 1 * CENT; | ||
| consensus.ZC_MinStakeDepth = 200; | ||
| consensus.ZC_TimeStart = 1501776000; | ||
|
|
||
| // Network upgrades | ||
| consensus.vUpgrades[Consensus::BASE_NETWORK].nActivationHeight = | ||
| Consensus::NetworkUpgrade::ALWAYS_ACTIVE; | ||
| consensus.vUpgrades[Consensus::UPGRADE_TESTDUMMY].nActivationHeight = | ||
| Consensus::NetworkUpgrade::NO_ACTIVATION_HEIGHT; | ||
| consensus.vUpgrades[Consensus::UPGRADE_POS].nActivationHeight = 201; | ||
| consensus.vUpgrades[Consensus::UPGRADE_POS_V2].nActivationHeight = 51197; | ||
| consensus.vUpgrades[Consensus::UPGRADE_ZC].nActivationHeight = 201576; | ||
| consensus.vUpgrades[Consensus::UPGRADE_ZC_V2].nActivationHeight = 444020; | ||
| consensus.vUpgrades[Consensus::UPGRADE_BIP65].nActivationHeight = 851019; | ||
| consensus.vUpgrades[Consensus::UPGRADE_ZC_PUBLIC].nActivationHeight = 1106100; | ||
| consensus.vUpgrades[Consensus::UPGRADE_V3_4].nActivationHeight = 1214000; | ||
| consensus.vUpgrades[Consensus::UPGRADE_V4_0].nActivationHeight = 1347000; | ||
| consensus.vUpgrades[Consensus::UPGRADE_V5_0].nActivationHeight = 1873550; | ||
|
|
||
| consensus.vUpgrades[Consensus::UPGRADE_ZC].hashActivationBlock = | ||
| uint256S("0x258c489f42f03cb97db2255e47938da4083eee4e242853c2d48bae2b1d0110a6"); | ||
| consensus.vUpgrades[Consensus::UPGRADE_ZC_V2].hashActivationBlock = | ||
| uint256S("0xfcc6a4c1da22e4db2ada87d257d6eef5e6922347ca1bb7879edfee27d24f64b5"); | ||
| consensus.vUpgrades[Consensus::UPGRADE_BIP65].hashActivationBlock = | ||
| uint256S("0xc54b3e7e8b710e4075da1806adf2d508ae722627d5bcc43f594cf64d5eef8b30"); | ||
| consensus.vUpgrades[Consensus::UPGRADE_V3_4].hashActivationBlock = | ||
| uint256S("0x1822577176173752aea33d1f60607cefe9e0b1c54ebaa77eb40201a385506199"); | ||
| consensus.vUpgrades[Consensus::UPGRADE_V4_0].hashActivationBlock = | ||
| uint256S("0x30c173ffc09a13f288bf6e828216107037ce5b79536b1cebd750a014f4939882"); | ||
| consensus.vUpgrades[Consensus::UPGRADE_POS_V2].nActivationHeight = 201; | ||
| consensus.vUpgrades[Consensus::UPGRADE_ZC].nActivationHeight = 201; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why not use |
||
| consensus.vUpgrades[Consensus::UPGRADE_ZC_V2].nActivationHeight = 201; | ||
| consensus.vUpgrades[Consensus::UPGRADE_BIP65].nActivationHeight = 201; | ||
| consensus.vUpgrades[Consensus::UPGRADE_ZC_PUBLIC].nActivationHeight = 201; | ||
| consensus.vUpgrades[Consensus::UPGRADE_V3_4].nActivationHeight = 201; | ||
| consensus.vUpgrades[Consensus::UPGRADE_V4_0].nActivationHeight = 201; | ||
| consensus.vUpgrades[Consensus::UPGRADE_V5_0].nActivationHeight = 201; | ||
|
|
||
| /** | ||
| * The message start string is designed to be unlikely to occur in normal data. | ||
| * The characters are rarely used upper ASCII, not valid as UTF-8, and produce | ||
| * a large 4-byte int at any alignment. | ||
| */ | ||
|
|
||
| pchMessageStart[0] = 0x45; | ||
| pchMessageStart[1] = 0x76; | ||
| pchMessageStart[2] = 0x65; | ||
| pchMessageStart[3] = 0xba; | ||
| pchMessageStart[0] = 0xf5; | ||
| pchMessageStart[1] = 0xe6; | ||
| pchMessageStart[2] = 0xd5; | ||
| pchMessageStart[3] = 0xca; | ||
| nDefaultPort = 51474; | ||
|
|
||
| vFixedSeeds.clear(); | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now that testnet5 is running, would be good to add the first post v5 enforcement checkpoint.