From 0bedefe79e6e08c226fc115266584fff3922872e Mon Sep 17 00:00:00 2001 From: Maciej Kulawik Date: Thu, 25 Sep 2025 23:13:05 +0100 Subject: [PATCH 1/4] add DebugBlock to ArbitrumChainPrams --- params/config_arbitrum.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/params/config_arbitrum.go b/params/config_arbitrum.go index f9362784eb..d543768c39 100644 --- a/params/config_arbitrum.go +++ b/params/config_arbitrum.go @@ -57,6 +57,7 @@ type ArbitrumChainParams struct { GenesisBlockNum uint64 MaxCodeSize uint64 `json:"MaxCodeSize,omitempty"` // Maximum bytecode to permit for a contract. 0 value implies params.DefaultMaxCodeSize MaxInitCodeSize uint64 `json:"MaxInitCodeSize,omitempty"` // Maximum initcode to permit in a creation transaction and create instructions. 0 value implies params.DefaultMaxInitCodeSize + DebugBlock uint64 `json:"DebugBlock,omitempty"` } func (c *ChainConfig) IsArbitrum() bool { @@ -85,6 +86,13 @@ func (c *ChainConfig) DebugMode() bool { return c.ArbitrumChainParams.AllowDebugPrecompiles } +func (c *ChainConfig) DebugBlock() uint64 { + if !c.DebugMode() { + return 0 + } + return c.ArbitrumChainParams.DebugBlock +} + func (c *ChainConfig) checkArbitrumCompatible(newcfg *ChainConfig, head *big.Int) *ConfigCompatError { if c.IsArbitrum() != newcfg.IsArbitrum() { // This difference applies to the entire chain, so report that the genesis block is where the difference appears. From 400642d1c3e37c0ef9515d46a3db453e3c322002 Mon Sep 17 00:00:00 2001 From: Maciej Kulawik Date: Fri, 26 Sep 2025 23:32:44 +0100 Subject: [PATCH 2/4] add DebugAddress to ArbitrumChainParams --- params/config_arbitrum.go | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/params/config_arbitrum.go b/params/config_arbitrum.go index d543768c39..485a8967a0 100644 --- a/params/config_arbitrum.go +++ b/params/config_arbitrum.go @@ -55,9 +55,10 @@ type ArbitrumChainParams struct { InitialArbOSVersion uint64 InitialChainOwner common.Address GenesisBlockNum uint64 - MaxCodeSize uint64 `json:"MaxCodeSize,omitempty"` // Maximum bytecode to permit for a contract. 0 value implies params.DefaultMaxCodeSize - MaxInitCodeSize uint64 `json:"MaxInitCodeSize,omitempty"` // Maximum initcode to permit in a creation transaction and create instructions. 0 value implies params.DefaultMaxInitCodeSize - DebugBlock uint64 `json:"DebugBlock,omitempty"` + MaxCodeSize uint64 `json:"MaxCodeSize,omitempty"` // Maximum bytecode to permit for a contract. 0 value implies params.DefaultMaxCodeSize + MaxInitCodeSize uint64 `json:"MaxInitCodeSize,omitempty"` // Maximum initcode to permit in a creation transaction and create instructions. 0 value implies params.DefaultMaxInitCodeSize + DebugBlock uint64 `json:"DebugBlock,omitempty"` + DebugAddress common.Address `json: "DebugAddress,omitempty"` } func (c *ChainConfig) IsArbitrum() bool { @@ -86,13 +87,6 @@ func (c *ChainConfig) DebugMode() bool { return c.ArbitrumChainParams.AllowDebugPrecompiles } -func (c *ChainConfig) DebugBlock() uint64 { - if !c.DebugMode() { - return 0 - } - return c.ArbitrumChainParams.DebugBlock -} - func (c *ChainConfig) checkArbitrumCompatible(newcfg *ChainConfig, head *big.Int) *ConfigCompatError { if c.IsArbitrum() != newcfg.IsArbitrum() { // This difference applies to the entire chain, so report that the genesis block is where the difference appears. From 99038d41dc99cdc04ec82e670a034c007916841d Mon Sep 17 00:00:00 2001 From: Maciej Kulawik Date: Fri, 3 Oct 2025 00:27:48 +0100 Subject: [PATCH 3/4] fix DebugBlock config json tag --- params/config_arbitrum.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/params/config_arbitrum.go b/params/config_arbitrum.go index 485a8967a0..b2b9534384 100644 --- a/params/config_arbitrum.go +++ b/params/config_arbitrum.go @@ -58,7 +58,7 @@ type ArbitrumChainParams struct { MaxCodeSize uint64 `json:"MaxCodeSize,omitempty"` // Maximum bytecode to permit for a contract. 0 value implies params.DefaultMaxCodeSize MaxInitCodeSize uint64 `json:"MaxInitCodeSize,omitempty"` // Maximum initcode to permit in a creation transaction and create instructions. 0 value implies params.DefaultMaxInitCodeSize DebugBlock uint64 `json:"DebugBlock,omitempty"` - DebugAddress common.Address `json: "DebugAddress,omitempty"` + DebugAddress common.Address `json:"DebugAddress,omitempty"` } func (c *ChainConfig) IsArbitrum() bool { From 3b8509053a76db5338b45b477a535447dcfc0da9 Mon Sep 17 00:00:00 2001 From: Maciej Kulawik Date: Thu, 9 Oct 2025 01:03:12 +0100 Subject: [PATCH 4/4] fix omitempty for DebugAddress, make it a pointer --- params/config_arbitrum.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/params/config_arbitrum.go b/params/config_arbitrum.go index b2b9534384..8b0e7410c5 100644 --- a/params/config_arbitrum.go +++ b/params/config_arbitrum.go @@ -55,10 +55,10 @@ type ArbitrumChainParams struct { InitialArbOSVersion uint64 InitialChainOwner common.Address GenesisBlockNum uint64 - MaxCodeSize uint64 `json:"MaxCodeSize,omitempty"` // Maximum bytecode to permit for a contract. 0 value implies params.DefaultMaxCodeSize - MaxInitCodeSize uint64 `json:"MaxInitCodeSize,omitempty"` // Maximum initcode to permit in a creation transaction and create instructions. 0 value implies params.DefaultMaxInitCodeSize - DebugBlock uint64 `json:"DebugBlock,omitempty"` - DebugAddress common.Address `json:"DebugAddress,omitempty"` + MaxCodeSize uint64 `json:"MaxCodeSize,omitempty"` // Maximum bytecode to permit for a contract. 0 value implies params.DefaultMaxCodeSize + MaxInitCodeSize uint64 `json:"MaxInitCodeSize,omitempty"` // Maximum initcode to permit in a creation transaction and create instructions. 0 value implies params.DefaultMaxInitCodeSize + DebugBlock uint64 `json:"DebugBlock,omitempty"` + DebugAddress *common.Address `json:"DebugAddress,omitempty"` } func (c *ChainConfig) IsArbitrum() bool {