Skip to content
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

Add mainnet merge epoch and ttd #11207

Merged
merged 26 commits into from
Aug 17, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
381a4a7
Add tentative mainnet merge epoch and ttd
terencechain Aug 12, 2022
5897221
Update minimal
terencechain Aug 12, 2022
38ef433
Update commit
terencechain Aug 15, 2022
80edb67
Merge branch 'develop' of github.com:prysmaticlabs/prysm into merge-m…
terencechain Aug 16, 2022
5dc5672
Update WORKSPACE
terencechain Aug 16, 2022
2a0b65b
Merge branch 'develop' into merge-mainnet
terencechain Aug 16, 2022
d0c9438
Update spec tests
terencechain Aug 16, 2022
199bf01
Merge branch 'merge-mainnet' of github.com:prysmaticlabs/prysm into m…
terencechain Aug 16, 2022
9c24422
Add eip4844 place holders
terencechain Aug 16, 2022
3498be6
Skip lightclient types
terencechain Aug 16, 2022
3736ded
Merge branch 'develop' into merge-mainnet
terencechain Aug 16, 2022
0836bd5
Merge branch 'develop' into merge-mainnet
terencechain Aug 16, 2022
d90d917
Skip lightclient types
terencechain Aug 16, 2022
05419e9
Merge branch 'merge-mainnet' of github.com:prysmaticlabs/prysm into m…
terencechain Aug 16, 2022
1426fa1
Merge branch 'develop' into merge-mainnet
terencechain Aug 17, 2022
4958547
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
85e2986
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
e983ea1
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
6c0221c
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
a8f70b4
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
4177768
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
efe9174
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
c9b714f
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
02e363e
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
c737767
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
2b896b2
Merge refs/heads/develop into merge-mainnet
prylabs-bulldozer[bot] Aug 17, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ filegroup(
url = "https://github.com/eth-clients/slashing-protection-interchange-tests/archive/b8413ca42dc92308019d0d4db52c87e9e125c4e9.tar.gz",
)

consensus_spec_version = "v1.2.0-rc.1"
consensus_spec_version = "v1.2.0-rc.2"

bls_test_version = "v0.1.1"

Expand All @@ -231,7 +231,7 @@ filegroup(
visibility = ["//visibility:public"],
)
""",
sha256 = "9c93f87378aaa6d6fe1c67b396eac2aacc9594af2a83f028cb99c95dea5b81df",
sha256 = "eff52923eebbed6e37a5282db5290abe67c68d6aa54302e3db2b0718c3edf867",
url = "https://github.com/ethereum/consensus-spec-tests/releases/download/%s/general.tar.gz" % consensus_spec_version,
)

Expand All @@ -247,7 +247,7 @@ filegroup(
visibility = ["//visibility:public"],
)
""",
sha256 = "52f2c52415228cee8a4de5a09abff785f439a77dfef8f03e834e4e16857673c1",
sha256 = "6183d39d40ae659347e8bcfa435cbbe6de8c19ab327b61d47f906bb087bc7a67",
url = "https://github.com/ethereum/consensus-spec-tests/releases/download/%s/minimal.tar.gz" % consensus_spec_version,
)

Expand All @@ -263,7 +263,7 @@ filegroup(
visibility = ["//visibility:public"],
)
""",
sha256 = "022dcc0d6de7dd27b337a0d1b945077eaf5ee47000700395a693fc25e12f96df",
sha256 = "894d16608d7d37a8f6206165e6c2b6ffcc45b13152b5f411e9283b005ca9793f",
url = "https://github.com/ethereum/consensus-spec-tests/releases/download/%s/mainnet.tar.gz" % consensus_spec_version,
)

Expand All @@ -278,7 +278,7 @@ filegroup(
visibility = ["//visibility:public"],
)
""",
sha256 = "0a9c110305cbd6ebbe0d942f0f33e6ce22dd484ce4ceed277bf185a091941cde",
sha256 = "006674e5d7eee613f1155e154ab97f6b57589ec92e6e3e5f7affd2b53581e907",
strip_prefix = "consensus-specs-" + consensus_spec_version[1:],
url = "https://github.com/ethereum/consensus-specs/archive/refs/tags/%s.tar.gz" % consensus_spec_version,
)
Expand Down Expand Up @@ -309,9 +309,9 @@ filegroup(
visibility = ["//visibility:public"],
)
""",
sha256 = "126b615e3853e29b61f082f6c89c8bc1c38cd92fb84b0004396fc49e7acc8d9f",
strip_prefix = "eth2-networks-f3ccbe0cf5798d5cd23e4e6e7119aefa043c0935",
url = "https://github.com/eth-clients/eth2-networks/archive/f3ccbe0cf5798d5cd23e4e6e7119aefa043c0935.tar.gz",
sha256 = "82b01a48b143fe0f2fb7fb5f5dd385c1f934335a12d7954f08b1d45d77427b5e",
strip_prefix = "eth2-networks-674f7a1d01d9c18345456eab76e3871b3df2126b",
url = "https://github.com/eth-clients/eth2-networks/archive/674f7a1d01d9c18345456eab76e3871b3df2126b.tar.gz",
)

http_archive(
Expand Down
2 changes: 1 addition & 1 deletion config/params/loader_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
"gopkg.in/yaml.v2"
)

var placeholderFields = []string{"UPDATE_TIMEOUT", "INTERVALS_PER_SLOT"}
var placeholderFields = []string{"UPDATE_TIMEOUT", "INTERVALS_PER_SLOT", "EIP4844_FORK_EPOCH", "EIP4844_FORK_VERSION"}

func TestLoadConfigFile(t *testing.T) {
// See https://media.githubusercontent.com/media/ethereum/consensus-spec-tests/master/tests/minimal/config/phase0.yaml
Expand Down
6 changes: 3 additions & 3 deletions config/params/mainnet_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ const (
genesisForkEpoch = 0
// Altair Fork Epoch for mainnet config.
mainnetAltairForkEpoch = 74240 // Oct 27, 2021, 10:56:23am UTC
// Placeholder for the merge epoch until it is decided
mainnetBellatrixForkEpoch = math.MaxUint64
// Bellatrix Fork Epoch for mainnet config.
mainnetBellatrixForkEpoch = 144896 // Sept 6, 2022, 11:34:47am UTC
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Checks out. Did

genesis_time=1606824023
bellatrix_fork_epoch=144896
seconds_since_genesis=bellatrix_fork_epoch3212
genesis_time+seconds_since_genesis=1662464087

Put it into a unix converter and got
Screen Shot 2022-08-17 at 11 15 15 AM

)

var mainnetNetworkConfig = &NetworkConfig{
Expand Down Expand Up @@ -248,7 +248,7 @@ var mainnetBeaconConfig = &BeaconChainConfig{
// Bellatrix
TerminalBlockHashActivationEpoch: 18446744073709551615,
TerminalBlockHash: [32]byte{},
TerminalTotalDifficulty: "115792089237316195423570985008687907853269984665640564039457584007913129638912",
TerminalTotalDifficulty: "58750000000000000000000", // Estimated: Sept 15, 2022
EthBurnAddressHex: "0x0000000000000000000000000000000000000000",
DefaultBuilderGasLimit: uint64(30000000),

Expand Down
2 changes: 2 additions & 0 deletions config/params/minimal_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@ func MinimalSpecConfig() *BeaconChainConfig {
minimalConfig.DepositChainID = 5 // Chain ID of eth1 goerli.
minimalConfig.DepositNetworkID = 5 // Network ID of eth1 goerli.
minimalConfig.DepositContractAddress = "0x1234567890123456789012345678901234567890"
// 2**256-2**10 for fake minimal network
minimalConfig.TerminalTotalDifficulty = "115792089237316195423570985008687907853269984665640564039457584007913129638912"

minimalConfig.ConfigName = MinimalName
minimalConfig.PresetBase = "minimal"
Expand Down
9 changes: 9 additions & 0 deletions testing/spectest/shared/altair/ssz_static/ssz_static.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,15 @@ func unmarshalledSSZ(t *testing.T, serializedBytes []byte, folderName string) (i
obj = &ethpb.SyncAggregatorSelectionData{}
case "SyncCommittee":
obj = &ethpb.SyncCommittee{}
case "LightClientOptimisticUpdate":
t.Skip("not a beacon node type, this is a light node type")
return nil, nil
case "LightClientFinalityUpdate":
t.Skip("not a beacon node type, this is a light node type")
return nil, nil
case "LightClientBootstrap":
t.Skip("not a beacon node type, this is a light node type")
return nil, nil
case "LightClientSnapshot":
t.Skip("not a beacon node type, this is a light node type")
return nil, nil
Expand Down
9 changes: 9 additions & 0 deletions testing/spectest/shared/bellatrix/ssz_static/ssz_static.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,15 @@ func unmarshalledSSZ(t *testing.T, serializedBytes []byte, folderName string) (i
obj = &ethpb.SyncAggregatorSelectionData{}
case "SyncCommittee":
obj = &ethpb.SyncCommittee{}
case "LightClientOptimisticUpdate":
t.Skip("not a beacon node type, this is a light node type")
return nil, nil
case "LightClientFinalityUpdate":
t.Skip("not a beacon node type, this is a light node type")
return nil, nil
case "LightClientBootstrap":
t.Skip("not a beacon node type, this is a light node type")
return nil, nil
case "LightClientSnapshot":
t.Skip("not a beacon node type, this is a light node type")
return nil, nil
Expand Down