Skip to content

Commit

Permalink
op-deployer: Update proof params JSON to match deploy config (#13616)
Browse files Browse the repository at this point in the history
  • Loading branch information
mslipper authored Jan 7, 2025
1 parent 83fb599 commit 9d41b8c
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 18 deletions.
23 changes: 11 additions & 12 deletions op-deployer/pkg/deployer/integration_test/apply_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ func (d *deployerKey) String() string {

func TestEndToEndApply(t *testing.T) {
op_e2e.InitParallel(t)
kurtosisutil.Test(t)

lgr := testlog.Logger(t, slog.LevelDebug)

Expand Down Expand Up @@ -651,12 +650,12 @@ func TestProofParamOverrides(t *testing.T) {
"proofMaturityDelaySeconds": standard.ProofMaturityDelaySeconds + 1,
"disputeGameFinalityDelaySeconds": standard.DisputeGameFinalityDelaySeconds + 1,
"mipsVersion": standard.MIPSVersion + 1,
"disputeGameType": standard.DisputeGameType, // This must be set to the permissioned game
"disputeAbsolutePrestate": common.Hash{'A', 'B', 'S', 'O', 'L', 'U', 'T', 'E'},
"disputeMaxGameDepth": standard.DisputeMaxGameDepth + 1,
"disputeSplitDepth": standard.DisputeSplitDepth + 1,
"disputeClockExtension": standard.DisputeClockExtension + 1,
"disputeMaxClockDuration": standard.DisputeMaxClockDuration + 1,
"respectedGameType": standard.DisputeGameType, // This must be set to the permissioned game
"faultGameAbsolutePrestate": common.Hash{'A', 'B', 'S', 'O', 'L', 'U', 'T', 'E'},
"faultGameMaxDepth": standard.DisputeMaxGameDepth + 1,
"faultGameSplitDepth": standard.DisputeSplitDepth + 1,
"faultGameClockExtension": standard.DisputeClockExtension + 1,
"faultGameMaxClockDuration": standard.DisputeMaxClockDuration + 1,
"dangerouslyAllowCustomDisputeParameters": true,
}

Expand Down Expand Up @@ -700,29 +699,29 @@ func TestProofParamOverrides(t *testing.T) {
st.ImplementationsDeployment.OptimismPortalImplAddress,
},
{
"disputeAbsolutePrestate",
"faultGameAbsolutePrestate",
func(t *testing.T, val any) common.Hash {
return val.(common.Hash)
},
chainState.PermissionedDisputeGameAddress,
},
{
"disputeMaxGameDepth",
"faultGameMaxDepth",
uint64Caster,
chainState.PermissionedDisputeGameAddress,
},
{
"disputeSplitDepth",
"faultGameSplitDepth",
uint64Caster,
chainState.PermissionedDisputeGameAddress,
},
{
"disputeClockExtension",
"faultGameClockExtension",
uint64Caster,
chainState.PermissionedDisputeGameAddress,
},
{
"disputeMaxClockDuration",
"faultGameMaxClockDuration",
uint64Caster,
chainState.PermissionedDisputeGameAddress,
},
Expand Down
12 changes: 6 additions & 6 deletions op-deployer/pkg/deployer/state/chain_intent.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ const (
)

type ChainProofParams struct {
DisputeGameType uint32 `json:"disputeGameType" toml:"disputeGameType"`
DisputeAbsolutePrestate common.Hash `json:"disputeAbsolutePrestate" toml:"disputeAbsolutePrestate"`
DisputeMaxGameDepth uint64 `json:"disputeMaxGameDepth" toml:"disputeMaxGameDepth"`
DisputeSplitDepth uint64 `json:"disputeSplitDepth" toml:"disputeSplitDepth"`
DisputeClockExtension uint64 `json:"disputeClockExtension" toml:"disputeClockExtension"`
DisputeMaxClockDuration uint64 `json:"disputeMaxClockDuration" toml:"disputeMaxClockDuration"`
DisputeGameType uint32 `json:"respectedGameType" toml:"respectedGameType"`
DisputeAbsolutePrestate common.Hash `json:"faultGameAbsolutePrestate" toml:"faultGameAbsolutePrestate"`
DisputeMaxGameDepth uint64 `json:"faultGameMaxDepth" toml:"faultGameMaxDepth"`
DisputeSplitDepth uint64 `json:"faultGameSplitDepth" toml:"faultGameSplitDepth"`
DisputeClockExtension uint64 `json:"faultGameClockExtension" toml:"faultGameClockExtension"`
DisputeMaxClockDuration uint64 `json:"faultGameMaxClockDuration" toml:"faultGameMaxClockDuration"`
DangerouslyAllowCustomDisputeParameters bool `json:"dangerouslyAllowCustomDisputeParameters" toml:"dangerouslyAllowCustomDisputeParameters"`
}

Expand Down
1 change: 1 addition & 0 deletions op-e2e/config/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -401,6 +401,7 @@ func defaultIntent(root string, loc *artifacts.Locator, deployer common.Address,
"faultGameGenesisBlock": 0,
"faultGameGenesisOutputRoot": genesisOutputRoot.Hex(),
"faultGameSplitDepth": 14,
"dangerouslyAllowCustomDisputeParameters": true,
"faultGameWithdrawalDelay": 604800,
"preimageOracleMinProposalSize": 10000,
"preimageOracleChallengePeriod": 120,
Expand Down

0 comments on commit 9d41b8c

Please sign in to comment.