Skip to content

Commit b37a1ae

Browse files
feat: interop portal fast follow 1 (#14785)
* feat: interop portal fast follow 1 First set of fast-follow changes to the interop portal. * fix: PR review feedback
1 parent ff32710 commit b37a1ae

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+558
-434
lines changed

op-chain-ops/interopgen/configs.go

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -74,16 +74,15 @@ type L2Config struct {
7474
Challenger common.Address
7575
SystemConfigOwner common.Address
7676
genesis.L2InitializationConfig
77-
Prefund map[common.Address]*big.Int
78-
SaltMixer string
79-
GasLimit uint64
80-
DisputeGameUsesSuperRoots bool
81-
DisputeGameType uint32
82-
DisputeAbsolutePrestate common.Hash
83-
DisputeMaxGameDepth uint64
84-
DisputeSplitDepth uint64
85-
DisputeClockExtension uint64
86-
DisputeMaxClockDuration uint64
77+
Prefund map[common.Address]*big.Int
78+
SaltMixer string
79+
GasLimit uint64
80+
DisputeGameType uint32
81+
DisputeAbsolutePrestate common.Hash
82+
DisputeMaxGameDepth uint64
83+
DisputeSplitDepth uint64
84+
DisputeClockExtension uint64
85+
DisputeMaxClockDuration uint64
8786
}
8887

8988
func (c *L2Config) Check(log log.Logger) error {

op-chain-ops/interopgen/deploy.go

Lines changed: 18 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -198,25 +198,24 @@ func DeployL2ToL1(l1Host *script.Host, superCfg *SuperchainConfig, superDeployme
198198
l1Host.SetTxOrigin(cfg.Deployer)
199199

200200
output, err := opcm.DeployOPChain(l1Host, opcm.DeployOPChainInput{
201-
OpChainProxyAdminOwner: cfg.ProxyAdminOwner,
202-
SystemConfigOwner: cfg.SystemConfigOwner,
203-
Batcher: cfg.BatchSenderAddress,
204-
UnsafeBlockSigner: cfg.P2PSequencerAddress,
205-
Proposer: cfg.Proposer,
206-
Challenger: cfg.Challenger,
207-
BasefeeScalar: cfg.GasPriceOracleBaseFeeScalar,
208-
BlobBaseFeeScalar: cfg.GasPriceOracleBlobBaseFeeScalar,
209-
L2ChainId: new(big.Int).SetUint64(cfg.L2ChainID),
210-
Opcm: superDeployment.Opcm,
211-
SaltMixer: cfg.SaltMixer,
212-
GasLimit: cfg.GasLimit,
213-
DisputeGameUsesSuperRoots: cfg.DisputeGameUsesSuperRoots,
214-
DisputeGameType: cfg.DisputeGameType,
215-
DisputeAbsolutePrestate: cfg.DisputeAbsolutePrestate,
216-
DisputeMaxGameDepth: cfg.DisputeMaxGameDepth,
217-
DisputeSplitDepth: cfg.DisputeSplitDepth,
218-
DisputeClockExtension: cfg.DisputeClockExtension,
219-
DisputeMaxClockDuration: cfg.DisputeMaxClockDuration,
201+
OpChainProxyAdminOwner: cfg.ProxyAdminOwner,
202+
SystemConfigOwner: cfg.SystemConfigOwner,
203+
Batcher: cfg.BatchSenderAddress,
204+
UnsafeBlockSigner: cfg.P2PSequencerAddress,
205+
Proposer: cfg.Proposer,
206+
Challenger: cfg.Challenger,
207+
BasefeeScalar: cfg.GasPriceOracleBaseFeeScalar,
208+
BlobBaseFeeScalar: cfg.GasPriceOracleBlobBaseFeeScalar,
209+
L2ChainId: new(big.Int).SetUint64(cfg.L2ChainID),
210+
Opcm: superDeployment.Opcm,
211+
SaltMixer: cfg.SaltMixer,
212+
GasLimit: cfg.GasLimit,
213+
DisputeGameType: cfg.DisputeGameType,
214+
DisputeAbsolutePrestate: cfg.DisputeAbsolutePrestate,
215+
DisputeMaxGameDepth: cfg.DisputeMaxGameDepth,
216+
DisputeSplitDepth: cfg.DisputeSplitDepth,
217+
DisputeClockExtension: cfg.DisputeClockExtension,
218+
DisputeMaxClockDuration: cfg.DisputeMaxClockDuration,
220219
})
221220
if err != nil {
222221
return nil, fmt.Errorf("failed to deploy L2 OP chain: %w", err)

op-chain-ops/interopgen/recipe.go

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -275,16 +275,15 @@ func (r *InteropDevL2Recipe) build(l1ChainID uint64, addrs devkeys.Addresses) (*
275275
UseAltDA: false,
276276
},
277277
},
278-
Prefund: make(map[common.Address]*big.Int),
279-
SaltMixer: "",
280-
GasLimit: 60_000_000,
281-
DisputeGameUsesSuperRoots: true,
282-
DisputeGameType: 1, // PERMISSIONED_CANNON Game Type
283-
DisputeAbsolutePrestate: common.HexToHash("0x038512e02c4c3f7bdaec27d00edf55b7155e0905301e1a88083e4e0a6764d54c"),
284-
DisputeMaxGameDepth: 73,
285-
DisputeSplitDepth: 30,
286-
DisputeClockExtension: 10800, // 3 hours (input in seconds)
287-
DisputeMaxClockDuration: 302400, // 3.5 days (input in seconds)
278+
Prefund: make(map[common.Address]*big.Int),
279+
SaltMixer: "",
280+
GasLimit: 60_000_000,
281+
DisputeGameType: 1, // PERMISSIONED_CANNON Game Type
282+
DisputeAbsolutePrestate: common.HexToHash("0x038512e02c4c3f7bdaec27d00edf55b7155e0905301e1a88083e4e0a6764d54c"),
283+
DisputeMaxGameDepth: 73,
284+
DisputeSplitDepth: 30,
285+
DisputeClockExtension: 10800, // 3 hours (input in seconds)
286+
DisputeMaxClockDuration: 302400, // 3.5 days (input in seconds)
288287
}
289288

290289
l2Users := devkeys.ChainUserKeys(new(big.Int).SetUint64(r.ChainID))

op-deployer/pkg/deployer/integration_test/apply_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -529,7 +529,6 @@ func TestAdditionalDisputeGames(t *testing.T) {
529529
intent.Chains[0].AdditionalDisputeGames = []state.AdditionalDisputeGame{
530530
{
531531
ChainProofParams: state.ChainProofParams{
532-
DisputeGameUsesSuperRoots: false,
533532
DisputeGameType: 255,
534533
DisputeAbsolutePrestate: standard.DisputeAbsolutePrestate,
535534
DisputeMaxGameDepth: 50,

op-deployer/pkg/deployer/opcm/opchain.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ type DeployOPChainInput struct {
3333
SaltMixer string
3434
GasLimit uint64
3535

36-
DisputeGameUsesSuperRoots bool
3736
DisputeGameType uint32
3837
DisputeAbsolutePrestate common.Hash
3938
DisputeMaxGameDepth uint64

op-deployer/pkg/deployer/pipeline/opchain.go

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -74,13 +74,12 @@ func DeployOPChain(env *Env, intent *state.Intent, st *state.State, chainID comm
7474
func makeDCI(intent *state.Intent, thisIntent *state.ChainIntent, chainID common.Hash, st *state.State) (opcm.DeployOPChainInput, error) {
7575
proofParams, err := jsonutil.MergeJSON(
7676
state.ChainProofParams{
77-
DisputeGameUsesSuperRoots: standard.DisputeGameUsesSuperRoots,
78-
DisputeGameType: standard.DisputeGameType,
79-
DisputeAbsolutePrestate: standard.DisputeAbsolutePrestate,
80-
DisputeMaxGameDepth: standard.DisputeMaxGameDepth,
81-
DisputeSplitDepth: standard.DisputeSplitDepth,
82-
DisputeClockExtension: standard.DisputeClockExtension,
83-
DisputeMaxClockDuration: standard.DisputeMaxClockDuration,
77+
DisputeGameType: standard.DisputeGameType,
78+
DisputeAbsolutePrestate: standard.DisputeAbsolutePrestate,
79+
DisputeMaxGameDepth: standard.DisputeMaxGameDepth,
80+
DisputeSplitDepth: standard.DisputeSplitDepth,
81+
DisputeClockExtension: standard.DisputeClockExtension,
82+
DisputeMaxClockDuration: standard.DisputeMaxClockDuration,
8483
},
8584
intent.GlobalDeployOverrides,
8685
thisIntent.DeployOverrides,
@@ -102,7 +101,6 @@ func makeDCI(intent *state.Intent, thisIntent *state.ChainIntent, chainID common
102101
Opcm: st.ImplementationsDeployment.OpcmAddress,
103102
SaltMixer: st.Create2Salt.String(), // passing through salt generated at state initialization
104103
GasLimit: standard.GasLimit,
105-
DisputeGameUsesSuperRoots: proofParams.DisputeGameUsesSuperRoots,
106104
DisputeGameType: proofParams.DisputeGameType,
107105
DisputeAbsolutePrestate: proofParams.DisputeAbsolutePrestate,
108106
DisputeMaxGameDepth: proofParams.DisputeMaxGameDepth,

op-deployer/pkg/deployer/standard/standard.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ const (
2626
ProofMaturityDelaySeconds uint64 = 604800
2727
DisputeGameFinalityDelaySeconds uint64 = 302400
2828
MIPSVersion uint64 = 1
29-
DisputeGameUsesSuperRoots bool = false
3029
DisputeGameType uint32 = 1 // PERMISSIONED game type
3130
DisputeMaxGameDepth uint64 = 73
3231
DisputeSplitDepth uint64 = 30

op-deployer/pkg/deployer/state/chain_intent.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ const (
1717
)
1818

1919
type ChainProofParams struct {
20-
DisputeGameUsesSuperRoots bool `json:"disputeGameUsesSuperRoots" toml:"disputeGameUsesSuperRoots"`
2120
DisputeGameType uint32 `json:"respectedGameType" toml:"respectedGameType"`
2221
DisputeAbsolutePrestate common.Hash `json:"faultGameAbsolutePrestate" toml:"faultGameAbsolutePrestate"`
2322
DisputeMaxGameDepth uint64 `json:"faultGameMaxDepth" toml:"faultGameMaxDepth"`

op-deployer/pkg/deployer/upgrade/v2_0_0/upgrade_test.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ import (
2121
)
2222

2323
func TestUpgradeOPChainInput_OpChainConfigs(t *testing.T) {
24-
t.Skip("skipping for upgrade 15")
2524
input := &UpgradeOPChainInput{
2625
Prank: common.Address{0xaa},
2726
Opcm: common.Address{0xbb},
@@ -55,7 +54,6 @@ func TestUpgradeOPChainInput_OpChainConfigs(t *testing.T) {
5554
}
5655

5756
func TestUpgrader_Upgrade(t *testing.T) {
58-
t.Skip("skipping for upgrade 15")
5957
lgr := testlog.Logger(t, slog.LevelDebug)
6058

6159
forkedL1, stopL1, err := devnet.NewForkedSepolia(lgr)

op-e2e/config/init.go

Lines changed: 18 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -436,13 +436,12 @@ func defaultIntent(root string, loc *artifacts.Locator, deployer common.Address,
436436
{
437437
ChainProofParams: state.ChainProofParams{
438438
// Fast game
439-
DisputeGameUsesSuperRoots: false,
440-
DisputeGameType: 254,
441-
DisputeAbsolutePrestate: defaultPrestate,
442-
DisputeMaxGameDepth: 14 + 3 + 1,
443-
DisputeSplitDepth: 14,
444-
DisputeClockExtension: 0,
445-
DisputeMaxClockDuration: 0,
439+
DisputeGameType: 254,
440+
DisputeAbsolutePrestate: defaultPrestate,
441+
DisputeMaxGameDepth: 14 + 3 + 1,
442+
DisputeSplitDepth: 14,
443+
DisputeClockExtension: 0,
444+
DisputeMaxClockDuration: 0,
446445
},
447446
VMType: state.VMTypeAlphabet,
448447
UseCustomOracle: true,
@@ -453,25 +452,23 @@ func defaultIntent(root string, loc *artifacts.Locator, deployer common.Address,
453452
{
454453
ChainProofParams: state.ChainProofParams{
455454
// Alphabet game
456-
DisputeGameUsesSuperRoots: false,
457-
DisputeGameType: 255,
458-
DisputeAbsolutePrestate: defaultPrestate,
459-
DisputeMaxGameDepth: 14 + 3 + 1,
460-
DisputeSplitDepth: 14,
461-
DisputeClockExtension: 0,
462-
DisputeMaxClockDuration: 1200,
455+
DisputeGameType: 255,
456+
DisputeAbsolutePrestate: defaultPrestate,
457+
DisputeMaxGameDepth: 14 + 3 + 1,
458+
DisputeSplitDepth: 14,
459+
DisputeClockExtension: 0,
460+
DisputeMaxClockDuration: 1200,
463461
},
464462
VMType: state.VMTypeAlphabet,
465463
},
466464
{
467465
ChainProofParams: state.ChainProofParams{
468-
DisputeGameUsesSuperRoots: false,
469-
DisputeGameType: 0,
470-
DisputeAbsolutePrestate: cannonPrestate(root, allocType),
471-
DisputeMaxGameDepth: 50,
472-
DisputeSplitDepth: 14,
473-
DisputeClockExtension: 0,
474-
DisputeMaxClockDuration: 1200,
466+
DisputeGameType: 0,
467+
DisputeAbsolutePrestate: cannonPrestate(root, allocType),
468+
DisputeMaxGameDepth: 50,
469+
DisputeSplitDepth: 14,
470+
DisputeClockExtension: 0,
471+
DisputeMaxClockDuration: 1200,
475472
},
476473
VMType: cannonVMType(allocType),
477474
},

0 commit comments

Comments
 (0)