Commit 5137f3b7 authored by George C. Knee's avatar George C. Knee Committed by GitHub

Update dependency on superchain-registry (#9929)

* go get github.com/ethereum-optimism/superchain-registry/superchain@52d3dbd1605dd43f419e838584abd0ec163d462b

* make mod-tidy

* remove goerli chaincfg

* op-program: replace references to goerli with sepolia

* op-node: remove references to goerli or replace with sepolia

* remove unused var

* go: update op-geth to latest v1.101308.4-rc.1

* op-node: remove Goerli references & config overrides

---------
Co-authored-by: default avatarSebastian Stammler <seb@oplabs.co>
parent a039f5a7
...@@ -11,7 +11,7 @@ require ( ...@@ -11,7 +11,7 @@ require (
github.com/crate-crypto/go-kzg-4844 v0.7.0 github.com/crate-crypto/go-kzg-4844 v0.7.0
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0
github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3 github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3
github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240306093353-c557df8e6f41 github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240318114348-52d3dbd1605d
github.com/ethereum/go-ethereum v1.13.8 github.com/ethereum/go-ethereum v1.13.8
github.com/fsnotify/fsnotify v1.7.0 github.com/fsnotify/fsnotify v1.7.0
github.com/go-chi/chi/v5 v5.0.12 github.com/go-chi/chi/v5 v5.0.12
...@@ -217,7 +217,7 @@ require ( ...@@ -217,7 +217,7 @@ require (
rsc.io/tmplfunc v0.0.3 // indirect rsc.io/tmplfunc v0.0.3 // indirect
) )
replace github.com/ethereum/go-ethereum v1.13.8 => github.com/ethereum-optimism/op-geth v1.101308.3-rc.1 replace github.com/ethereum/go-ethereum v1.13.8 => github.com/ethereum-optimism/op-geth v1.101308.4-rc.1
// replace github.com/ethereum-optimism/superchain-registry/superchain => ../superchain-registry/superchain // replace github.com/ethereum-optimism/superchain-registry/superchain => ../superchain-registry/superchain
......
...@@ -170,10 +170,10 @@ github.com/elastic/gosigar v0.14.2 h1:Dg80n8cr90OZ7x+bAax/QjoW/XqTI11RmA79ZwIm9/ ...@@ -170,10 +170,10 @@ github.com/elastic/gosigar v0.14.2 h1:Dg80n8cr90OZ7x+bAax/QjoW/XqTI11RmA79ZwIm9/
github.com/elastic/gosigar v0.14.2/go.mod h1:iXRIGg2tLnu7LBdpqzyQfGDEidKCfWcCMS0WKyPWoMs= github.com/elastic/gosigar v0.14.2/go.mod h1:iXRIGg2tLnu7LBdpqzyQfGDEidKCfWcCMS0WKyPWoMs=
github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3 h1:RWHKLhCrQThMfch+QJ1Z8veEq5ZO3DfIhZ7xgRP9WTc= github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3 h1:RWHKLhCrQThMfch+QJ1Z8veEq5ZO3DfIhZ7xgRP9WTc=
github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3/go.mod h1:QziizLAiF0KqyLdNJYD7O5cpDlaFMNZzlxYNcWsJUxs= github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3/go.mod h1:QziizLAiF0KqyLdNJYD7O5cpDlaFMNZzlxYNcWsJUxs=
github.com/ethereum-optimism/op-geth v1.101308.3-rc.1 h1:mC8PrDNTZJr7sYcm+FgaWFUy/LOZ0sS8+BxkglUoPkg= github.com/ethereum-optimism/op-geth v1.101308.4-rc.1 h1:sicj4EhLW8gJffoIRrtLl7Zgv+be8i/L1AZ0xxgInJY=
github.com/ethereum-optimism/op-geth v1.101308.3-rc.1/go.mod h1:k0UbrLuOITLD8goCyA2xWebAL03n2BZUCfwos0rxz60= github.com/ethereum-optimism/op-geth v1.101308.4-rc.1/go.mod h1:eFb6HyjixYhM8b0r0imIYKKfhPKx+xIvTqbkIipoBig=
github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240306093353-c557df8e6f41 h1:WKJvsRyW/YNgyT0P2x5U530ITOY8Dv9TrZnbliqSXd8= github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240318114348-52d3dbd1605d h1:K7HdD/ZAcSFhcqqnUAbvU+8vsg0DzL8pvetHw5vRLCc=
github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240306093353-c557df8e6f41/go.mod h1:7xh2awFQqsiZxFrHKTgEd+InVfDRrkKVUIuK8SAFHp0= github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240318114348-52d3dbd1605d/go.mod h1:7xh2awFQqsiZxFrHKTgEd+InVfDRrkKVUIuK8SAFHp0=
github.com/ethereum/c-kzg-4844 v0.4.0 h1:3MS1s4JtA868KpJxroZoepdV0ZKBp3u/O5HcZ7R3nlY= github.com/ethereum/c-kzg-4844 v0.4.0 h1:3MS1s4JtA868KpJxroZoepdV0ZKBp3u/O5HcZ7R3nlY=
github.com/ethereum/c-kzg-4844 v0.4.0/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0= github.com/ethereum/c-kzg-4844 v0.4.0/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0=
github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w= github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w=
......
...@@ -22,7 +22,7 @@ var ( ...@@ -22,7 +22,7 @@ var (
l1Beacon = "http://example.com:9000" l1Beacon = "http://example.com:9000"
gameFactoryAddressValue = "0xbb00000000000000000000000000000000000000" gameFactoryAddressValue = "0xbb00000000000000000000000000000000000000"
cannonNetwork = "op-mainnet" cannonNetwork = "op-mainnet"
otherCannonNetwork = "op-goerli" otherCannonNetwork = "op-sepolia"
cannonBin = "./bin/cannon" cannonBin = "./bin/cannon"
cannonServer = "./bin/op-program" cannonServer = "./bin/op-program"
cannonPreState = "./pre.json" cannonPreState = "./pre.json"
......
...@@ -9,7 +9,7 @@ import ( ...@@ -9,7 +9,7 @@ import (
"github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-node/rollup"
) )
var Mainnet, Goerli, Sepolia *rollup.Config var Mainnet, Sepolia *rollup.Config
func init() { func init() {
mustCfg := func(name string) *rollup.Config { mustCfg := func(name string) *rollup.Config {
...@@ -20,7 +20,6 @@ func init() { ...@@ -20,7 +20,6 @@ func init() {
return cfg return cfg
} }
Mainnet = mustCfg("op-mainnet") Mainnet = mustCfg("op-mainnet")
Goerli = mustCfg("op-goerli")
Sepolia = mustCfg("op-sepolia") Sepolia = mustCfg("op-sepolia")
} }
...@@ -43,8 +42,6 @@ func AvailableNetworks() []string { ...@@ -43,8 +42,6 @@ func AvailableNetworks() []string {
func handleLegacyName(name string) string { func handleLegacyName(name string) string {
switch name { switch name {
case "goerli":
return "op-goerli"
case "mainnet": case "mainnet":
return "op-mainnet" return "op-mainnet"
case "sepolia": case "sepolia":
......
...@@ -21,7 +21,6 @@ import ( ...@@ -21,7 +21,6 @@ import (
// the superchain-registry is no longer deemed experimental. // the superchain-registry is no longer deemed experimental.
func TestGetRollupConfig(t *testing.T) { func TestGetRollupConfig(t *testing.T) {
configsByName := map[string]rollup.Config{ configsByName := map[string]rollup.Config{
"goerli": goerliCfg,
"mainnet": mainnetCfg, "mainnet": mainnetCfg,
"sepolia": sepoliaCfg, "sepolia": sepoliaCfg,
"oplabs-devnet-0-sepolia-dev-0": sepoliaDev0Cfg, "oplabs-devnet-0-sepolia-dev-0": sepoliaDev0Cfg,
...@@ -69,40 +68,6 @@ var mainnetCfg = rollup.Config{ ...@@ -69,40 +68,6 @@ var mainnetCfg = rollup.Config{
ProtocolVersionsAddress: common.HexToAddress("0x8062AbC286f5e7D9428a0Ccb9AbD71e50d93b935"), ProtocolVersionsAddress: common.HexToAddress("0x8062AbC286f5e7D9428a0Ccb9AbD71e50d93b935"),
} }
var goerliCfg = rollup.Config{
Genesis: rollup.Genesis{
L1: eth.BlockID{
Hash: common.HexToHash("0x6ffc1bf3754c01f6bb9fe057c1578b87a8571ce2e9be5ca14bace6eccfd336c7"),
Number: 8300214,
},
L2: eth.BlockID{
Hash: common.HexToHash("0x0f783549ea4313b784eadd9b8e8a69913b368b7366363ea814d7707ac505175f"),
Number: 4061224,
},
L2Time: 1673550516,
SystemConfig: eth.SystemConfig{
BatcherAddr: common.HexToAddress("0x7431310e026B69BFC676C0013E12A1A11411EEc9"),
Overhead: eth.Bytes32(common.HexToHash("0x0000000000000000000000000000000000000000000000000000000000000834")),
Scalar: eth.Bytes32(common.HexToHash("0x00000000000000000000000000000000000000000000000000000000000f4240")),
GasLimit: 25_000_000,
},
},
BlockTime: 2,
MaxSequencerDrift: 600,
SeqWindowSize: 3600,
ChannelTimeout: 300,
L1ChainID: big.NewInt(5),
L2ChainID: big.NewInt(420),
BatchInboxAddress: common.HexToAddress("0xff00000000000000000000000000000000000420"),
DepositContractAddress: common.HexToAddress("0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383"),
L1SystemConfigAddress: common.HexToAddress("0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60"),
RegolithTime: u64Ptr(1679079600),
CanyonTime: u64Ptr(1699981200),
DeltaTime: u64Ptr(1703116800),
EcotoneTime: u64Ptr(1707238800),
ProtocolVersionsAddress: common.HexToAddress("0x0C24F5098774aA366827D667494e9F889f7cFc08"),
}
var sepoliaCfg = rollup.Config{ var sepoliaCfg = rollup.Config{
Genesis: rollup.Genesis{ Genesis: rollup.Genesis{
L1: eth.BlockID{ L1: eth.BlockID{
......
...@@ -43,14 +43,14 @@ func (testSuite *PeerParamsTestSuite) TestNewPeerScoreThresholds() { ...@@ -43,14 +43,14 @@ func (testSuite *PeerParamsTestSuite) TestNewPeerScoreThresholds() {
// TestGetPeerScoreParams validates the peer score parameters. // TestGetPeerScoreParams validates the peer score parameters.
func (testSuite *PeerParamsTestSuite) TestGetPeerScoreParams_None() { func (testSuite *PeerParamsTestSuite) TestGetPeerScoreParams_None() {
params, err := GetScoringParams("none", chaincfg.Goerli) params, err := GetScoringParams("none", chaincfg.Sepolia)
testSuite.NoError(err) testSuite.NoError(err)
testSuite.Nil(params) testSuite.Nil(params)
} }
// TestLightPeerScoreParams validates the light peer score params. // TestLightPeerScoreParams validates the light peer score params.
func (testSuite *PeerParamsTestSuite) TestGetPeerScoreParams_Light() { func (testSuite *PeerParamsTestSuite) TestGetPeerScoreParams_Light() {
cfg := chaincfg.Goerli cfg := chaincfg.Sepolia
cfg.BlockTime = 1 cfg.BlockTime = 1
slot := time.Duration(cfg.BlockTime) * time.Second slot := time.Duration(cfg.BlockTime) * time.Second
epoch := 6 * slot epoch := 6 * slot
...@@ -98,7 +98,7 @@ func (testSuite *PeerParamsTestSuite) TestGetPeerScoreParams_Light() { ...@@ -98,7 +98,7 @@ func (testSuite *PeerParamsTestSuite) TestGetPeerScoreParams_Light() {
// TestParamsZeroBlockTime validates peer score params use default slot for 0 block time. // TestParamsZeroBlockTime validates peer score params use default slot for 0 block time.
func (testSuite *PeerParamsTestSuite) TestParamsZeroBlockTime() { func (testSuite *PeerParamsTestSuite) TestParamsZeroBlockTime() {
cfg := chaincfg.Goerli cfg := chaincfg.Sepolia
cfg.BlockTime = 0 cfg.BlockTime = 0
slot := 2 * time.Second slot := 2 * time.Second
params, err := GetScoringParams("light", cfg) params, err := GetScoringParams("light", cfg)
......
...@@ -15,18 +15,6 @@ import ( ...@@ -15,18 +15,6 @@ import (
var OPStackSupport = params.ProtocolVersionV0{Build: [8]byte{}, Major: 6, Minor: 0, Patch: 0, PreRelease: 0}.Encode() var OPStackSupport = params.ProtocolVersionV0{Build: [8]byte{}, Major: 6, Minor: 0, Patch: 0, PreRelease: 0}.Encode()
const ( const (
opMainnet = 10
opGoerli = 420
opSepolia = 11155420
labsGoerliDevnet = 997
labsGoerliChaosnet = 888
labsSepoliaDevnet0 = 11155421
baseGoerli = 84531
baseMainnet = 8453
pgnMainnet = 424
pgnSepolia = 58008 pgnSepolia = 58008
) )
...@@ -61,19 +49,6 @@ func LoadOPStackRollupConfig(chainID uint64) (*Config, error) { ...@@ -61,19 +49,6 @@ func LoadOPStackRollupConfig(chainID uint64) (*Config, error) {
} }
regolithTime := uint64(0) regolithTime := uint64(0)
// three goerli testnets test-ran Bedrock and later upgraded to Regolith.
// All other OP-Stack chains have Regolith enabled from the start.
switch chainID {
case baseGoerli:
regolithTime = 1683219600
case opGoerli:
regolithTime = 1679079600
case labsGoerliDevnet:
regolithTime = 1677984480
case labsGoerliChaosnet:
regolithTime = 1692156862
}
cfg := &Config{ cfg := &Config{
Genesis: Genesis{ Genesis: Genesis{
L1: eth.BlockID{ L1: eth.BlockID{
...@@ -106,13 +81,10 @@ func LoadOPStackRollupConfig(chainID uint64) (*Config, error) { ...@@ -106,13 +81,10 @@ func LoadOPStackRollupConfig(chainID uint64) (*Config, error) {
DepositContractAddress: common.Address(addrs.OptimismPortalProxy), DepositContractAddress: common.Address(addrs.OptimismPortalProxy),
L1SystemConfigAddress: common.Address(addrs.SystemConfigProxy), L1SystemConfigAddress: common.Address(addrs.SystemConfigProxy),
} }
if superChain.Config.ProtocolVersionsAddr != nil { // Set optional protocol versions address if superChain.Config.ProtocolVersionsAddr != nil { // Set optional protocol versions address
cfg.ProtocolVersionsAddress = common.Address(*superChain.Config.ProtocolVersionsAddr) cfg.ProtocolVersionsAddress = common.Address(*superChain.Config.ProtocolVersionsAddr)
} }
if chainID == labsGoerliDevnet || chainID == labsGoerliChaosnet {
cfg.ChannelTimeout = 120
cfg.MaxSequencerDrift = 1200
}
if chainID == pgnSepolia { if chainID == pgnSepolia {
cfg.MaxSequencerDrift = 1000 cfg.MaxSequencerDrift = 1000
cfg.SeqWindowSize = 7200 cfg.SeqWindowSize = 7200
......
...@@ -147,9 +147,9 @@ func TestRandomConfigDescription(t *testing.T) { ...@@ -147,9 +147,9 @@ func TestRandomConfigDescription(t *testing.T) {
}) })
t.Run("named L1", func(t *testing.T) { t.Run("named L1", func(t *testing.T) {
config := randConfig() config := randConfig()
config.L1ChainID = big.NewInt(5) config.L1ChainID = big.NewInt(11155111)
out := config.Description(map[string]string{config.L2ChainID.String(): "foobar chain"}) out := config.Description(map[string]string{config.L2ChainID.String(): "foobar chain"})
require.Contains(t, out, "goerli") require.Contains(t, out, "sepolia")
}) })
t.Run("unnamed", func(t *testing.T) { t.Run("unnamed", func(t *testing.T) {
config := randConfig() config := randConfig()
...@@ -506,7 +506,6 @@ func TestTimestampForBlock(t *testing.T) { ...@@ -506,7 +506,6 @@ func TestTimestampForBlock(t *testing.T) {
assert.Equal(t, timestamp, test.expectedBlockTime) assert.Equal(t, timestamp, test.expectedBlockTime)
}) })
} }
} }
func TestForkchoiceUpdatedVersion(t *testing.T) { func TestForkchoiceUpdatedVersion(t *testing.T) {
......
...@@ -7,7 +7,7 @@ import ( ...@@ -7,7 +7,7 @@ import (
"github.com/ethereum/go-ethereum/params" "github.com/ethereum/go-ethereum/params"
) )
var OPGoerliChainConfig, OPSepoliaChainConfig, OPMainnetChainConfig *params.ChainConfig var OPSepoliaChainConfig, OPMainnetChainConfig *params.ChainConfig
func init() { func init() {
mustLoadConfig := func(chainID uint64) *params.ChainConfig { mustLoadConfig := func(chainID uint64) *params.ChainConfig {
...@@ -17,13 +17,11 @@ func init() { ...@@ -17,13 +17,11 @@ func init() {
} }
return cfg return cfg
} }
OPGoerliChainConfig = mustLoadConfig(420)
OPSepoliaChainConfig = mustLoadConfig(11155420) OPSepoliaChainConfig = mustLoadConfig(11155420)
OPMainnetChainConfig = mustLoadConfig(10) OPMainnetChainConfig = mustLoadConfig(10)
} }
var L2ChainConfigsByChainID = map[uint64]*params.ChainConfig{ var L2ChainConfigsByChainID = map[uint64]*params.ChainConfig{
420: OPGoerliChainConfig,
11155420: OPSepoliaChainConfig, 11155420: OPSepoliaChainConfig,
10: OPMainnetChainConfig, 10: OPMainnetChainConfig,
} }
......
...@@ -19,9 +19,9 @@ func TestBootstrapClient(t *testing.T) { ...@@ -19,9 +19,9 @@ func TestBootstrapClient(t *testing.T) {
L2OutputRoot: common.HexToHash("0x2222"), L2OutputRoot: common.HexToHash("0x2222"),
L2Claim: common.HexToHash("0x3333"), L2Claim: common.HexToHash("0x3333"),
L2ClaimBlockNumber: 1, L2ClaimBlockNumber: 1,
L2ChainID: chaincfg.Goerli.L2ChainID.Uint64(), L2ChainID: chaincfg.Sepolia.L2ChainID.Uint64(),
L2ChainConfig: chainconfig.OPGoerliChainConfig, L2ChainConfig: chainconfig.OPSepoliaChainConfig,
RollupConfig: chaincfg.Goerli, RollupConfig: chaincfg.Sepolia,
} }
mockOracle := &mockBoostrapOracle{bootInfo, false} mockOracle := &mockBoostrapOracle{bootInfo, false}
readBootInfo := NewBootstrapClient(mockOracle).BootInfo() readBootInfo := NewBootstrapClient(mockOracle).BootInfo()
...@@ -35,8 +35,8 @@ func TestBootstrapClient_CustomChain(t *testing.T) { ...@@ -35,8 +35,8 @@ func TestBootstrapClient_CustomChain(t *testing.T) {
L2Claim: common.HexToHash("0x3333"), L2Claim: common.HexToHash("0x3333"),
L2ClaimBlockNumber: 1, L2ClaimBlockNumber: 1,
L2ChainID: CustomChainIDIndicator, L2ChainID: CustomChainIDIndicator,
L2ChainConfig: chainconfig.OPGoerliChainConfig, L2ChainConfig: chainconfig.OPSepoliaChainConfig,
RollupConfig: chaincfg.Goerli, RollupConfig: chaincfg.Sepolia,
} }
mockOracle := &mockBoostrapOracle{bootInfo, true} mockOracle := &mockBoostrapOracle{bootInfo, true}
readBootInfo := NewBootstrapClient(mockOracle).BootInfo() readBootInfo := NewBootstrapClient(mockOracle).BootInfo()
......
...@@ -161,13 +161,13 @@ func createOracleEngine(t *testing.T) (*OracleEngine, *stubEngineBackend) { ...@@ -161,13 +161,13 @@ func createOracleEngine(t *testing.T) (*OracleEngine, *stubEngineBackend) {
} }
engine := OracleEngine{ engine := OracleEngine{
backend: backend, backend: backend,
rollupCfg: chaincfg.Goerli, rollupCfg: chaincfg.Sepolia,
} }
return &engine, backend return &engine, backend
} }
func createL2Block(t *testing.T, number int) *types.Block { func createL2Block(t *testing.T, number int) *types.Block {
tx, err := derive.L1InfoDeposit(chaincfg.Goerli, eth.SystemConfig{}, uint64(1), eth.HeaderBlockInfo(&types.Header{ tx, err := derive.L1InfoDeposit(chaincfg.Sepolia, eth.SystemConfig{}, uint64(1), eth.HeaderBlockInfo(&types.Header{
Number: big.NewInt(32), Number: big.NewInt(32),
BaseFee: big.NewInt(7), BaseFee: big.NewInt(7),
}), 0) }), 0)
......
...@@ -25,8 +25,8 @@ var ( ...@@ -25,8 +25,8 @@ var (
l2ClaimValue = common.HexToHash("0x333333").Hex() l2ClaimValue = common.HexToHash("0x333333").Hex()
l2OutputRoot = common.HexToHash("0x444444").Hex() l2OutputRoot = common.HexToHash("0x444444").Hex()
l2ClaimBlockNumber = uint64(1203) l2ClaimBlockNumber = uint64(1203)
// Note: This is actually the L1 goerli genesis config. Just using it as an arbitrary, valid genesis config // Note: This is actually the L1 Sepolia genesis config. Just using it as an arbitrary, valid genesis config
l2Genesis = core.DefaultGoerliGenesisBlock() l2Genesis = core.DefaultSepoliaGenesisBlock()
l2GenesisConfig = l2Genesis.Config l2GenesisConfig = l2Genesis.Config
) )
...@@ -67,11 +67,11 @@ func TestLogFormat(t *testing.T) { ...@@ -67,11 +67,11 @@ func TestLogFormat(t *testing.T) {
func TestDefaultCLIOptionsMatchDefaultConfig(t *testing.T) { func TestDefaultCLIOptionsMatchDefaultConfig(t *testing.T) {
cfg := configForArgs(t, addRequiredArgs()) cfg := configForArgs(t, addRequiredArgs())
rollupCfg, err := chaincfg.GetRollupConfig("op-goerli") rollupCfg, err := chaincfg.GetRollupConfig("op-sepolia")
require.NoError(t, err) require.NoError(t, err)
defaultCfg := config.NewConfig( defaultCfg := config.NewConfig(
rollupCfg, rollupCfg,
chainconfig.OPGoerliChainConfig, chainconfig.OPSepoliaChainConfig,
common.HexToHash(l1HeadValue), common.HexToHash(l1HeadValue),
common.HexToHash(l2HeadValue), common.HexToHash(l2HeadValue),
common.HexToHash(l2OutputRoot), common.HexToHash(l2OutputRoot),
...@@ -98,7 +98,7 @@ func TestNetwork(t *testing.T) { ...@@ -98,7 +98,7 @@ func TestNetwork(t *testing.T) {
genesisFile := writeValidGenesis(t) genesisFile := writeValidGenesis(t)
cfg := configForArgs(t, addRequiredArgsExcept("--network", "--rollup.config", configFile, "--l2.genesis", genesisFile)) cfg := configForArgs(t, addRequiredArgsExcept("--network", "--rollup.config", configFile, "--l2.genesis", genesisFile))
require.Equal(t, *chaincfg.Goerli, *cfg.Rollup) require.Equal(t, *chaincfg.Sepolia, *cfg.Rollup)
}) })
for _, name := range chaincfg.AvailableNetworks() { for _, name := range chaincfg.AvailableNetworks() {
...@@ -139,8 +139,8 @@ func TestL2Genesis(t *testing.T) { ...@@ -139,8 +139,8 @@ func TestL2Genesis(t *testing.T) {
}) })
t.Run("NotRequiredForGoerli", func(t *testing.T) { t.Run("NotRequiredForGoerli", func(t *testing.T) {
cfg := configForArgs(t, replaceRequiredArg("--network", "goerli")) cfg := configForArgs(t, replaceRequiredArg("--network", "sepolia"))
require.Equal(t, chainconfig.OPGoerliChainConfig, cfg.L2ChainConfig) require.Equal(t, chainconfig.OPSepoliaChainConfig, cfg.L2ChainConfig)
}) })
} }
...@@ -352,7 +352,7 @@ func replaceRequiredArg(name string, value string) []string { ...@@ -352,7 +352,7 @@ func replaceRequiredArg(name string, value string) []string {
// to create a valid Config // to create a valid Config
func requiredArgs() map[string]string { func requiredArgs() map[string]string {
return map[string]string{ return map[string]string{
"--network": "goerli", "--network": "sepolia",
"--l1.head": l1HeadValue, "--l1.head": l1HeadValue,
"--l2.head": l2HeadValue, "--l2.head": l2HeadValue,
"--l2.outputroot": l2OutputRoot, "--l2.outputroot": l2OutputRoot,
...@@ -372,7 +372,7 @@ func writeValidGenesis(t *testing.T) string { ...@@ -372,7 +372,7 @@ func writeValidGenesis(t *testing.T) string {
func writeValidRollupConfig(t *testing.T) string { func writeValidRollupConfig(t *testing.T) string {
dir := t.TempDir() dir := t.TempDir()
j, err := json.Marshal(chaincfg.Goerli) j, err := json.Marshal(chaincfg.Sepolia)
require.NoError(t, err) require.NoError(t, err)
cfgFile := dir + "/rollup.json" cfgFile := dir + "/rollup.json"
require.NoError(t, os.WriteFile(cfgFile, j, 0666)) require.NoError(t, os.WriteFile(cfgFile, j, 0666))
......
...@@ -13,8 +13,8 @@ import ( ...@@ -13,8 +13,8 @@ import (
) )
var ( var (
validRollupConfig = chaincfg.Goerli validRollupConfig = chaincfg.Sepolia
validL2Genesis = chainconfig.OPGoerliChainConfig validL2Genesis = chainconfig.OPSepoliaChainConfig
validL1Head = common.Hash{0xaa} validL1Head = common.Hash{0xaa}
validL2Head = common.Hash{0xbb} validL2Head = common.Hash{0xbb}
validL2Claim = common.Hash{0xcc} validL2Claim = common.Hash{0xcc}
......
...@@ -25,7 +25,7 @@ func TestServerMode(t *testing.T) { ...@@ -25,7 +25,7 @@ func TestServerMode(t *testing.T) {
l1Head := common.Hash{0x11} l1Head := common.Hash{0x11}
l2OutputRoot := common.Hash{0x33} l2OutputRoot := common.Hash{0x33}
cfg := config.NewConfig(chaincfg.Goerli, chainconfig.OPGoerliChainConfig, l1Head, common.Hash{0x22}, l2OutputRoot, common.Hash{0x44}, 1000) cfg := config.NewConfig(chaincfg.Sepolia, chainconfig.OPSepoliaChainConfig, l1Head, common.Hash{0x22}, l2OutputRoot, common.Hash{0x44}, 1000)
cfg.DataDir = dir cfg.DataDir = dir
cfg.ServerMode = true cfg.ServerMode = true
......
...@@ -15,7 +15,7 @@ import ( ...@@ -15,7 +15,7 @@ import (
func TestLocalPreimageSource(t *testing.T) { func TestLocalPreimageSource(t *testing.T) {
cfg := &config.Config{ cfg := &config.Config{
Rollup: chaincfg.Goerli, Rollup: chaincfg.Sepolia,
L1Head: common.HexToHash("0x1111"), L1Head: common.HexToHash("0x1111"),
L2OutputRoot: common.HexToHash("0x2222"), L2OutputRoot: common.HexToHash("0x2222"),
L2Claim: common.HexToHash("0x3333"), L2Claim: common.HexToHash("0x3333"),
......
...@@ -39,7 +39,7 @@ require ( ...@@ -39,7 +39,7 @@ require (
github.com/crate-crypto/go-kzg-4844 v0.7.0 // indirect github.com/crate-crypto/go-kzg-4844 v0.7.0 // indirect
github.com/deckarep/golang-set/v2 v2.1.0 // indirect github.com/deckarep/golang-set/v2 v2.1.0 // indirect
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect
github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240306093353-c557df8e6f41 // indirect github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240318114348-52d3dbd1605d // indirect
github.com/ethereum/c-kzg-4844 v0.4.0 // indirect github.com/ethereum/c-kzg-4844 v0.4.0 // indirect
github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect
github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46 // indirect github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46 // indirect
......
...@@ -86,8 +86,8 @@ github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go. ...@@ -86,8 +86,8 @@ github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
github.com/ethereum-optimism/op-geth v1.101308.2-rc.2 h1:Tjm2n7/actyINbRIbqeDS+SyWAcIl+pRfOHODwW7lpQ= github.com/ethereum-optimism/op-geth v1.101308.2-rc.2 h1:Tjm2n7/actyINbRIbqeDS+SyWAcIl+pRfOHODwW7lpQ=
github.com/ethereum-optimism/op-geth v1.101308.2-rc.2/go.mod h1:RPqVhnX00rJNys/YRDK4Wl4PvS6dgFrLqhsopIZOhEw= github.com/ethereum-optimism/op-geth v1.101308.2-rc.2/go.mod h1:RPqVhnX00rJNys/YRDK4Wl4PvS6dgFrLqhsopIZOhEw=
github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240306093353-c557df8e6f41 h1:WKJvsRyW/YNgyT0P2x5U530ITOY8Dv9TrZnbliqSXd8= github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240318114348-52d3dbd1605d h1:K7HdD/ZAcSFhcqqnUAbvU+8vsg0DzL8pvetHw5vRLCc=
github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240306093353-c557df8e6f41/go.mod h1:7xh2awFQqsiZxFrHKTgEd+InVfDRrkKVUIuK8SAFHp0= github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240318114348-52d3dbd1605d/go.mod h1:7xh2awFQqsiZxFrHKTgEd+InVfDRrkKVUIuK8SAFHp0=
github.com/ethereum/c-kzg-4844 v0.4.0 h1:3MS1s4JtA868KpJxroZoepdV0ZKBp3u/O5HcZ7R3nlY= github.com/ethereum/c-kzg-4844 v0.4.0 h1:3MS1s4JtA868KpJxroZoepdV0ZKBp3u/O5HcZ7R3nlY=
github.com/ethereum/c-kzg-4844 v0.4.0/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0= github.com/ethereum/c-kzg-4844 v0.4.0/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0=
github.com/fjl/memsize v0.0.1 h1:+zhkb+dhUgx0/e+M8sF0QqiouvMQUiKR+QYvdxIOKcQ= github.com/fjl/memsize v0.0.1 h1:+zhkb+dhUgx0/e+M8sF0QqiouvMQUiKR+QYvdxIOKcQ=
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment