From f8b1dc8f5e68633176d6febc6612616cb6667ed9 Mon Sep 17 00:00:00 2001 From: Neil Date: Tue, 29 Aug 2023 02:37:31 +0100 Subject: [PATCH 1/2] Update chain data --- src/chainparams.cpp | 34 ++++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/src/chainparams.cpp b/src/chainparams.cpp index 54cd6adbe3..9692686af2 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -119,8 +119,8 @@ class CMainParams : public CChainParams { // Replace 0xffffc0 with the activation block number consensus.vDeployments[Consensus::DEPLOYMENT_TAPROOT].min_activation_height = 2080512; - consensus.nMinimumChainWork = uint256S("0x00000000000000000000000000000000000000000000046da696c11a1b820988"); // 2636000 - consensus.defaultAssumeValid = uint256S("0x4844cfb8403cdee4994acaab4bf1168339bce5ccd65496d4d9ffc1d262b0d79a"); // 2636000 + consensus.nMinimumChainWork = uint256S("0x0000000000000000000000000000000000000000000004edc867995369c4f3cf"); // 3142000 + consensus.defaultAssumeValid = uint256S("0x3dc42fcf2e731093ee9b3cbaa2df07d8b8638cdea77758bb28b1130f504a7f43"); // 3142000 /** * The message start string is designed to be unlikely to occur in normal data. @@ -133,7 +133,7 @@ class CMainParams : public CChainParams { pchMessageStart[3] = 0xd3; nDefaultPort = 3888; nPruneAfterHeight = 100000; - m_assumed_blockchain_size = 18; + m_assumed_blockchain_size = 21; m_assumed_chain_state_size = 1; genesis = CreateGenesisBlock(1504695029, 8026361, 0x1f00ffff, 1, 50 * COIN); @@ -183,7 +183,8 @@ class CMainParams : public CChainParams { { 888000, uint256S("0x02caf7a26b995e5054462715a4d31e1a7ff220c53fead7c06de720ac54510433")}, { 1405000, uint256S("0x8ef924fb7d2a28e0420c8731fb34301c204d15fe8d1e68461e5ebe959df011f2")}, { 1883974, uint256S("0xefe5b66cd0963b19ed64850884f039ff4d98c49cd63b9ec763d5c336619d5a6d")}, - { 2636000, uint256S("4844cfb8403cdee4994acaab4bf1168339bce5ccd65496d4d9ffc1d262b0d79a")}, + { 2636000, uint256S("0x4844cfb8403cdee4994acaab4bf1168339bce5ccd65496d4d9ffc1d262b0d79a")}, + { 3142000, uint256S("0x3dc42fcf2e731093ee9b3cbaa2df07d8b8638cdea77758bb28b1130f504a7f43")}, } }; @@ -192,10 +193,10 @@ class CMainParams : public CChainParams { }; chainTxData = ChainTxData{ - // Data as of block 2250aa6ed692895f7d3a7840e37bdc383584f18e0c7a9e7982521f9b47d6fd6c (height 1885982) - .nTime = 1677137204, // * UNIX timestamp of last known number of transactions - .nTxCount = 9233597, // * total number of transactions between genesis and that timestamp - .dTxRate = 0.07037814963941287, // * estimated number of transactions per second after that timestamp + // Data as of block 3dc42fcf2e731093ee9b3cbaa2df07d8b8638cdea77758bb28b1130f504a7f43 (height 3142000) + .nTime = 1693268288, // * UNIX timestamp of last known number of transactions + .nTxCount = 10429839, // * total number of transactions between genesis and that timestamp + .dTxRate = 0.07664262206369668, // * estimated number of transactions per second after that timestamp }; consensus.nBlocktimeDownscaleFactor = 4; @@ -277,8 +278,8 @@ class CTestNetParams : public CChainParams { // Replace 0xffffc0 with the activation block number consensus.vDeployments[Consensus::DEPLOYMENT_TAPROOT].min_activation_height = 1967616; - consensus.nMinimumChainWork = uint256S("0x0000000000000000000000000000000000000000000001c6bc764db929bf2dc1"); // 2686000 - consensus.defaultAssumeValid = uint256S("0xc12594feff0dfae05f5a056cd9248ff5e6fc42d37c4bedf37b212eb17dccb486"); // 2686000 + consensus.nMinimumChainWork = uint256S("0x000000000000000000000000000000000000000000000213cff04c2108ab7d5a"); // 3180000 + consensus.defaultAssumeValid = uint256S("0xde6afcb300f7036b67b7446933b8aa7986850058d5927e07ce5df1e270069ef2"); // 3180000 pchMessageStart[0] = 0x0d; pchMessageStart[1] = 0x22; @@ -286,7 +287,7 @@ class CTestNetParams : public CChainParams { pchMessageStart[3] = 0x06; nDefaultPort = 13888; nPruneAfterHeight = 1000; - m_assumed_blockchain_size = 8; + m_assumed_blockchain_size = 10; m_assumed_chain_state_size = 1; genesis = CreateGenesisBlock(1504695029, 7349697, 0x1f00ffff, 1, 50 * COIN); @@ -329,7 +330,8 @@ class CTestNetParams : public CChainParams { {944000, uint256S("0x6bb6312088d81ca5484460b3466c66c01ff7d1cd4ef91e1dc9555a15b51d025d")}, {1405000, uint256S("0xaff1f9c768e83f90d10a55306993e9042b5740251abc1afdde1429d09e95fa66")}, {1930000, uint256S("0xf4836510a70e25d5c70554abbbcb346abd66af540f616d806fb1c20335c1e874")}, - {2686000, uint256S("c12594feff0dfae05f5a056cd9248ff5e6fc42d37c4bedf37b212eb17dccb486")}, + {2686000, uint256S("0xc12594feff0dfae05f5a056cd9248ff5e6fc42d37c4bedf37b212eb17dccb486")}, + {3180000, uint256S("0xde6afcb300f7036b67b7446933b8aa7986850058d5927e07ce5df1e270069ef2")}, } }; @@ -338,10 +340,10 @@ class CTestNetParams : public CChainParams { }; chainTxData = ChainTxData{ - // Data as of block f948d21fffc54b511638b4c2c73dfa8f1c50661fbf3187a553bf939c361116ea (height 1935143) - .nTime = 1677137416, - .nTxCount = 5556700, - .dTxRate = 0.0624360428132865, + // Data as of block 0xde6afcb300f7036b67b7446933b8aa7986850058d5927e07ce5df1e270069ef2 (height 3180000) + .nTime = 1692923320, + .nTxCount = 6552961, + .dTxRate = 0.06299127541669518, }; consensus.nBlocktimeDownscaleFactor = 4; From 785c1fdb71176eebce29d310a2a94d63e29b72e6 Mon Sep 17 00:00:00 2001 From: Neil Date: Tue, 29 Aug 2023 02:43:57 +0100 Subject: [PATCH 2/2] Set Shanghai EVM fork heights --- src/chainparams.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/chainparams.cpp b/src/chainparams.cpp index 9692686af2..4bea2f999f 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -91,7 +91,7 @@ class CMainParams : public CChainParams { consensus.nReduceBlocktimeHeight = 845000; consensus.nMuirGlacierHeight = 845000; consensus.nLondonHeight = 2080512; - consensus.nShanghaiHeight = 0x7fffffff; + consensus.nShanghaiHeight = 3385122; consensus.powLimit = uint256S("0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"); consensus.posLimit = uint256S("00000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff"); consensus.QIP9PosLimit = uint256S("0000000000001fffffffffffffffffffffffffffffffffffffffffffffffffff"); // The new POS-limit activated after QIP9 @@ -250,7 +250,7 @@ class CTestNetParams : public CChainParams { consensus.nReduceBlocktimeHeight = 806600; consensus.nMuirGlacierHeight = 806600; consensus.nLondonHeight = 1967616; - consensus.nShanghaiHeight = 0x7fffffff; + consensus.nShanghaiHeight = 3298892; consensus.powLimit = uint256S("0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"); consensus.posLimit = uint256S("0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"); consensus.QIP9PosLimit = uint256S("0000000000001fffffffffffffffffffffffffffffffffffffffffffffffffff"); // The new POS-limit activated after QIP9