Skip to content

Commit 672cd76

Browse files
authored
HIP32 epoch activation and new sharding config (#4769)
* 2151 epoch as 2024-10-30 19:50 UTC. * Mainnet v5 with new sharding config
1 parent 1588c05 commit 672cd76

File tree

2 files changed

+14
-2
lines changed

2 files changed

+14
-2
lines changed

Diff for: internal/configs/sharding/mainnet.go

+11
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,8 @@ type mainnetSchedule struct{}
7373

7474
func (ms mainnetSchedule) InstanceForEpoch(epoch *big.Int) Instance {
7575
switch {
76+
case params.MainnetChainConfig.IsHIP32(epoch):
77+
return mainnetV5
7678
case params.MainnetChainConfig.IsHIP30(epoch):
7779
return mainnetV4
7880
case params.MainnetChainConfig.IsFeeCollectEpoch(epoch):
@@ -376,4 +378,13 @@ var (
376378
hip30CollectionAddress, mainnetReshardingEpoch,
377379
MainnetSchedule.BlocksPerEpoch(),
378380
)
381+
mainnetV5 = MustNewInstance(
382+
2, 200, 2, 0.06,
383+
numeric.MustNewDecFromStr("0.01"),
384+
genesis.HarmonyAccountsPostHIP30,
385+
genesis.FoundationalNodeAccountsV1_5, emptyAllowlist,
386+
feeCollectorsMainnet, numeric.MustNewDecFromStr("0.25"),
387+
hip30CollectionAddress, mainnetReshardingEpoch,
388+
MainnetSchedule.BlocksPerEpoch(),
389+
)
379390
)

Diff for: internal/params/config.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,8 @@ var (
6969
SlotsLimitedEpoch: big.NewInt(999), // Around Fri, 27 May 2022 09:41:02 UTC with 2s block time
7070
CrossShardXferPrecompileEpoch: big.NewInt(1323), // Around Wed 8 Feb 11:30PM UTC
7171
AllowlistEpoch: EpochTBD,
72-
LeaderRotationInternalValidatorsEpoch: EpochTBD,
73-
LeaderRotationExternalValidatorsEpoch: EpochTBD,
72+
LeaderRotationInternalValidatorsEpoch: big.NewInt(2151), // 2024-10-30 19:50 UTC
73+
LeaderRotationExternalValidatorsEpoch: big.NewInt(2151), // 2024-10-30 19:50 UTC
7474
FeeCollectEpoch: big.NewInt(1535), // 2023-07-20 05:51:07+00:00
7575
ValidatorCodeFixEpoch: big.NewInt(1535), // 2023-07-20 05:51:07+00:00
7676
HIP30Epoch: big.NewInt(1673), // 2023-11-02 17:30:00+00:00
@@ -79,6 +79,7 @@ var (
7979
MaxRateEpoch: big.NewInt(1733), // 2023-12-17 12:20:15+00:00
8080
DevnetExternalEpoch: EpochTBD,
8181
TestnetExternalEpoch: EpochTBD,
82+
HIP32Epoch: big.NewInt(2151), // 2024-10-30 19:50 UTC
8283
}
8384

8485
// TestnetChainConfig contains the chain parameters to run a node on the harmony test network.

0 commit comments

Comments
 (0)