Skip to content

Commit f5b4026

Browse files
authored
Merge pull request #2555 from codablock/pr_testnetreset_v12
Reset/Fork testnet to block 4000 and prepare v0.12.3.4 release
2 parents 0a93b0d + 0fca0e6 commit f5b4026

File tree

7 files changed

+139
-64
lines changed

7 files changed

+139
-64
lines changed

configure.ac

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ AC_PREREQ([2.60])
33
define(_CLIENT_VERSION_MAJOR, 0)
44
define(_CLIENT_VERSION_MINOR, 12)
55
define(_CLIENT_VERSION_REVISION, 3)
6-
define(_CLIENT_VERSION_BUILD, 3)
6+
define(_CLIENT_VERSION_BUILD, 4)
77
define(_CLIENT_VERSION_IS_RELEASE, true)
88
define(_COPYRIGHT_YEAR, 2018)
99
define(_COPYRIGHT_HOLDERS,[The %s developers])

doc/Doxyfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ PROJECT_NAME = "Dash Core"
4141
# could be handy for archiving the generated documentation or if some version
4242
# control system is used.
4343

44-
PROJECT_NUMBER = 0.12.3.3
44+
PROJECT_NUMBER = 0.12.3.4
4545

4646
# Using the PROJECT_BRIEF tag one can provide an optional one line description
4747
# for a project that appears at the top of each page and should give viewer a

doc/release-notes.md

+12-9
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
Dash Core version 0.12.3.3
1+
Dash Core version 0.12.3.4
22
==========================
33

44
Release is now available from:
55

66
<https://www.dash.org/downloads/#wallets>
77

8-
This is a critical bugfix release.
8+
This is an optional release and only contains changes for testnet. It is not required to update masternodes on mainnet.
99

1010
Please report bugs using the issue tracker at github:
1111

@@ -34,7 +34,7 @@ the database if you decide to use any pre-0.12.2.2 version.
3434

3535
Wallet forward or backward compatibility was not affected.
3636

37-
### Downgrade to 0.12.2.2/3, 0.12.3.1/2
37+
### Downgrade to 0.12.3.1/2/3
3838

3939
Downgrading to these versions does not require any additional actions, should be
4040
fully compatible.
@@ -43,16 +43,18 @@ fully compatible.
4343
Notable changes
4444
===============
4545

46-
Fix crash bug with duplicate inputs within a transaction
47-
--------------------------------------------------------
46+
Fork/Reset testnet at block 4001
47+
--------------------------------
4848

49-
There was a critical bug discovered in Bitcoin Core's codebase recently which
50-
can cause node receiving a block to crash https://github.com/bitcoin/bitcoin/pull/14247
49+
This release is NOT required on mainnet. It is intended to be deployed on testnet and will cause a fork at block 4001.
50+
The plan is to restart all testing for the v0.13.0.0 upgrade process.
5151

52-
0.12.3.3 Change log
52+
When deployed on testnet, it is required to start with a fresh data directory or call Dash Core with `-reindex-chainstate`.
53+
54+
0.12.3.4 Change log
5355
===================
5456

55-
See detailed [set of changes](https://github.com/dashpay/dash/compare/v0.12.3.2...dashpay:v0.12.3.3).
57+
See detailed [set of changes](https://github.com/dashpay/dash/compare/v0.12.3.3...dashpay:v0.12.3.4).
5658

5759
Credits
5860
=======
@@ -84,6 +86,7 @@ Dash Core tree 0.12.1.x was a fork of Bitcoin Core tree 0.12.
8486

8587
These release are considered obsolete. Old release notes can be found here:
8688

89+
- [v0.12.3.3](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.3.3.md) released Sep/19/2018
8790
- [v0.12.3.2](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.3.2.md) released Jul/09/2018
8891
- [v0.12.3.1](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.3.1.md) released Jul/03/2018
8992
- [v0.12.2.3](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.2.3.md) released Jan/12/2018
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
Dash Core version 0.12.3.3
2+
==========================
3+
4+
Release is now available from:
5+
6+
<https://www.dash.org/downloads/#wallets>
7+
8+
This is a critical bugfix release.
9+
10+
Please report bugs using the issue tracker at github:
11+
12+
<https://github.com/dashpay/dash/issues>
13+
14+
15+
Upgrading and downgrading
16+
=========================
17+
18+
How to Upgrade
19+
--------------
20+
21+
If you are running an older version, shut it down. Wait until it has completely
22+
shut down (which might take a few minutes for older versions), then run the
23+
installer (on Windows) or just copy over /Applications/Dash-Qt (on Mac) or
24+
dashd/dash-qt (on Linux).
25+
26+
Downgrade warning
27+
-----------------
28+
29+
### Downgrade to a version < 0.12.2.2
30+
31+
Because release 0.12.2.2 included the [per-UTXO fix](release-notes/dash/release-notes-0.12.2.2.md#per-utxo-fix)
32+
which changed the structure of the internal database, you will have to reindex
33+
the database if you decide to use any pre-0.12.2.2 version.
34+
35+
Wallet forward or backward compatibility was not affected.
36+
37+
### Downgrade to 0.12.2.2/3, 0.12.3.1/2
38+
39+
Downgrading to these versions does not require any additional actions, should be
40+
fully compatible.
41+
42+
43+
Notable changes
44+
===============
45+
46+
Fix crash bug with duplicate inputs within a transaction
47+
--------------------------------------------------------
48+
49+
There was a critical bug discovered in Bitcoin Core's codebase recently which
50+
can cause node receiving a block to crash https://github.com/bitcoin/bitcoin/pull/14247
51+
52+
0.12.3.3 Change log
53+
===================
54+
55+
See detailed [set of changes](https://github.com/dashpay/dash/compare/v0.12.3.2...dashpay:v0.12.3.3).
56+
57+
Credits
58+
=======
59+
60+
Thanks to everyone who directly contributed to this release,
61+
as well as everyone who submitted issues and reviewed pull requests.
62+
63+
64+
Older releases
65+
==============
66+
67+
Dash was previously known as Darkcoin.
68+
69+
Darkcoin tree 0.8.x was a fork of Litecoin tree 0.8, original name was XCoin
70+
which was first released on Jan/18/2014.
71+
72+
Darkcoin tree 0.9.x was the open source implementation of masternodes based on
73+
the 0.8.x tree and was first released on Mar/13/2014.
74+
75+
Darkcoin tree 0.10.x used to be the closed source implementation of Darksend
76+
which was released open source on Sep/25/2014.
77+
78+
Dash Core tree 0.11.x was a fork of Bitcoin Core tree 0.9,
79+
Darkcoin was rebranded to Dash.
80+
81+
Dash Core tree 0.12.0.x was a fork of Bitcoin Core tree 0.10.
82+
83+
Dash Core tree 0.12.1.x was a fork of Bitcoin Core tree 0.12.
84+
85+
These release are considered obsolete. Old release notes can be found here:
86+
87+
- [v0.12.3.2](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.3.2.md) released Jul/09/2018
88+
- [v0.12.3.1](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.3.1.md) released Jul/03/2018
89+
- [v0.12.2.3](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.2.3.md) released Jan/12/2018
90+
- [v0.12.2.2](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.2.2.md) released Dec/17/2017
91+
- [v0.12.2](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.2.md) released Nov/08/2017
92+
- [v0.12.1](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.1.md) released Feb/06/2017
93+
- [v0.12.0](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.12.0.md) released Jun/15/2015
94+
- [v0.11.2](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.11.2.md) released Mar/04/2015
95+
- [v0.11.1](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.11.1.md) released Feb/10/2015
96+
- [v0.11.0](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.11.0.md) released Jan/15/2015
97+
- [v0.10.x](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.10.0.md) released Sep/25/2014
98+
- [v0.9.x](https://github.com/dashpay/dash/blob/master/doc/release-notes/dash/release-notes-0.9.0.md) released Mar/13/2014
99+

src/chainparams.cpp

+14-16
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ class CTestNetParams : public CChainParams {
285285
consensus.nBudgetPaymentsCycleBlocks = 50;
286286
consensus.nBudgetPaymentsWindowBlocks = 10;
287287
consensus.nSuperblockStartBlock = 4200; // NOTE: Should satisfy nSuperblockStartBlock > nBudgetPeymentsStartBlock
288-
consensus.nSuperblockStartHash = uint256S("00000000cffabc0f646867fba0550afd6e30e0f4b0fc54e34d3e101a1552df5d");
288+
consensus.nSuperblockStartHash = uint256(); // do not check this on testnet
289289
consensus.nSuperblockCycle = 24; // Superblocks can be issued hourly on testnet
290290
consensus.nGovernanceMinQuorum = 1;
291291
consensus.nGovernanceFilterElements = 500;
@@ -300,8 +300,8 @@ class CTestNetParams : public CChainParams {
300300
consensus.nPowTargetSpacing = 2.5 * 60; // Dash: 2.5 minutes
301301
consensus.fPowAllowMinDifficultyBlocks = true;
302302
consensus.fPowNoRetargeting = false;
303-
consensus.nPowKGWHeight = 4001; // nPowKGWHeight >= nPowDGWHeight means "no KGW"
304-
consensus.nPowDGWHeight = 4001;
303+
consensus.nPowKGWHeight = 4002; // nPowKGWHeight >= nPowDGWHeight means "no KGW"
304+
consensus.nPowDGWHeight = 4002;
305305
consensus.nRuleChangeActivationThreshold = 1512; // 75% for testchains
306306
consensus.nMinerConfirmationWindow = 2016; // nPowTargetTimespan / nPowTargetSpacing
307307
consensus.vDeployments[Consensus::DEPLOYMENT_TESTDUMMY].bit = 28;
@@ -310,28 +310,28 @@ class CTestNetParams : public CChainParams {
310310

311311
// Deployment of BIP68, BIP112, and BIP113.
312312
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].bit = 0;
313-
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nStartTime = 1506556800; // September 28th, 2017
314-
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nTimeout = 1538092800; // September 28th, 2018
313+
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nStartTime = 1544655600; // Dec 13th, 2018
314+
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nTimeout = 1576191600; // Dec 13th, 2019
315315

316316
// Deployment of DIP0001
317317
consensus.vDeployments[Consensus::DEPLOYMENT_DIP0001].bit = 1;
318-
consensus.vDeployments[Consensus::DEPLOYMENT_DIP0001].nStartTime = 1505692800; // Sep 18th, 2017
319-
consensus.vDeployments[Consensus::DEPLOYMENT_DIP0001].nTimeout = 1537228800; // Sep 18th, 2018
318+
consensus.vDeployments[Consensus::DEPLOYMENT_DIP0001].nStartTime = 1544655600; // Dec 13th, 2018
319+
consensus.vDeployments[Consensus::DEPLOYMENT_DIP0001].nTimeout = 1576191600; // Dec 13th, 2019
320320
consensus.vDeployments[Consensus::DEPLOYMENT_DIP0001].nWindowSize = 100;
321321
consensus.vDeployments[Consensus::DEPLOYMENT_DIP0001].nThreshold = 50; // 50% of 100
322322

323323
// Deployment of BIP147
324324
consensus.vDeployments[Consensus::DEPLOYMENT_BIP147].bit = 2;
325-
consensus.vDeployments[Consensus::DEPLOYMENT_BIP147].nStartTime = 1517792400; // Feb 5th, 2018
326-
consensus.vDeployments[Consensus::DEPLOYMENT_BIP147].nTimeout = 1549328400; // Feb 5th, 2019
325+
consensus.vDeployments[Consensus::DEPLOYMENT_BIP147].nStartTime = 1544655600; // Dec 13th, 2018
326+
consensus.vDeployments[Consensus::DEPLOYMENT_BIP147].nTimeout = 1576191600; // Dec 13th, 2019
327327
consensus.vDeployments[Consensus::DEPLOYMENT_BIP147].nWindowSize = 100;
328328
consensus.vDeployments[Consensus::DEPLOYMENT_BIP147].nThreshold = 50; // 50% of 100
329329

330330
// The best chain should have at least this much work.
331-
consensus.nMinimumChainWork = uint256S("0x000000000000000000000000000000000000000000000000003be69c34b1244f"); // 143200
331+
consensus.nMinimumChainWork = uint256S("0x00000000000000000000000000000000000000000000000000000003cd72a542"); // 4000
332332

333333
// By default assume that the signatures in ancestors of this block are valid.
334-
consensus.defaultAssumeValid = uint256S("0x0000000004a7878409189b7a8f75b3815d9b8c45ee8f79955a6c727d83bddb04"); // 143200
334+
consensus.defaultAssumeValid = uint256S("0x00000ce22113f3eb8636e225d6a1691e132fdd587aed993e1bc9b07a0235eea4"); // 4000
335335

336336
pchMessageStart[0] = 0xce;
337337
pchMessageStart[1] = 0xe2;
@@ -383,13 +383,11 @@ class CTestNetParams : public CChainParams {
383383
( 261, uint256S("0x00000c26026d0815a7e2ce4fa270775f61403c040647ff2c3091f99e894a4618"))
384384
( 1999, uint256S("0x00000052e538d27fa53693efe6fb6892a0c1d26c0235f599171c48a3cce553b1"))
385385
( 2999, uint256S("0x0000024bc3f4f4cb30d29827c13d921ad77d2c6072e586c7f60d83c2722cdcc5"))
386-
( 100000, uint256S("0x0000000003aa53e24b6e60ef97642e4193611f2bcb75ea1fa8105f0b5ffd5242"))
387-
( 143200, uint256S("0x0000000004a7878409189b7a8f75b3815d9b8c45ee8f79955a6c727d83bddb04"))
388386
};
389387

390-
chainTxData = ChainTxData{
391-
1529294335, // * UNIX timestamp of last known number of transactions
392-
5810120, // * total number of transactions between genesis and that timestamp
388+
chainTxData = ChainTxData{
389+
1544707462, // * UNIX timestamp of last known number of transactions
390+
4100, // * total number of transactions between genesis and that timestamp
393391
// (the tx=... number in the SetBestChain debug.log lines)
394392
0.01 // * estimated number of transactions per second after that timestamp
395393
};

src/clientversion.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#define CLIENT_VERSION_MAJOR 0
1818
#define CLIENT_VERSION_MINOR 12
1919
#define CLIENT_VERSION_REVISION 3
20-
#define CLIENT_VERSION_BUILD 3
20+
#define CLIENT_VERSION_BUILD 4
2121

2222
//! Set to true for release, false for prerelease or test build
2323
#define CLIENT_VERSION_IS_RELEASE true

src/pow.cpp

+11-36
Original file line numberDiff line numberDiff line change
@@ -89,43 +89,18 @@ unsigned int static DarkGravityWave(const CBlockIndex* pindexLast, const CBlockH
8989
return bnPowLimit.GetCompact();
9090
}
9191

92-
if (params.fPowAllowMinDifficultyBlocks && (
93-
// testnet ...
94-
(params.hashDevnetGenesisBlock.IsNull() && pindexLast->nChainWork >= UintToArith256(uint256S("0x000000000000000000000000000000000000000000000000003e9ccfe0e03e01"))) ||
95-
// or devnet
96-
!params.hashDevnetGenesisBlock.IsNull())) {
97-
// NOTE: 000000000000000000000000000000000000000000000000003e9ccfe0e03e01 is the work of the "wrong" chain,
98-
// so this rule activates there immediately and new blocks with high diff from that chain are going
99-
// to be rejected by updated nodes. Note, that old nodes are going to reject blocks from updated nodes
100-
// after the "right" chain reaches this amount of work too. This is a temporary condition which should
101-
// be removed when we decide to hard-fork testnet again.
102-
// TODO: remove "testnet+work OR devnet" part on next testnet hard-fork
103-
// Special difficulty rule for testnet/devnet:
104-
// If the new block's timestamp is more than 2* 2.5 minutes
105-
// then allow mining of a min-difficulty block.
106-
107-
// start using smoother adjustment on testnet when total work hits
108-
// 000000000000000000000000000000000000000000000000003ff00000000000
109-
if (pindexLast->nChainWork >= UintToArith256(uint256S("0x000000000000000000000000000000000000000000000000003ff00000000000"))
110-
// and immediately on devnet
111-
|| !params.hashDevnetGenesisBlock.IsNull()) {
112-
// recent block is more than 2 hours old
113-
if (pblock->GetBlockTime() > pindexLast->GetBlockTime() + 2 * 60 * 60) {
114-
return bnPowLimit.GetCompact();
115-
}
116-
// recent block is more than 10 minutes old
117-
if (pblock->GetBlockTime() > pindexLast->GetBlockTime() + params.nPowTargetSpacing*4) {
118-
arith_uint256 bnNew = arith_uint256().SetCompact(pindexLast->nBits) * 10;
119-
if (bnNew > bnPowLimit) {
120-
bnNew = bnPowLimit;
121-
}
122-
return bnNew.GetCompact();
123-
}
124-
} else {
125-
// old stuff
126-
if (pblock->GetBlockTime() > pindexLast->GetBlockTime() + params.nPowTargetSpacing*2) {
127-
return bnPowLimit.GetCompact();
92+
if (params.fPowAllowMinDifficultyBlocks) {
93+
// recent block is more than 2 hours old
94+
if (pblock->GetBlockTime() > pindexLast->GetBlockTime() + 2 * 60 * 60) {
95+
return bnPowLimit.GetCompact();
96+
}
97+
// recent block is more than 10 minutes old
98+
if (pblock->GetBlockTime() > pindexLast->GetBlockTime() + params.nPowTargetSpacing * 4) {
99+
arith_uint256 bnNew = arith_uint256().SetCompact(pindexLast->nBits) * 10;
100+
if (bnNew > bnPowLimit) {
101+
bnNew = bnPowLimit;
128102
}
103+
return bnNew.GetCompact();
129104
}
130105
}
131106

0 commit comments

Comments
 (0)