Skip to content
This repository was archived by the owner on Oct 20, 2024. It is now read-only.

Commit 7147ff8

Browse files
authored
Remove call to Arbitrum gas helper contract (#176)
1 parent 5425011 commit 7147ff8

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

internal/start/private.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ func PrivateMode() {
5959

6060
ov := gas.NewDefaultOverhead()
6161
if chain.Cmp(config.ArbitrumOneChainID) == 0 || chain.Cmp(config.ArbitrumGoerliChainID) == 0 {
62-
ov.SetCalcPreVerificationGasFunc(gas.CalcArbitrumPVGWithEthClient(rpc))
62+
ov.SetCalcPreVerificationGasFunc(gas.CalcArbitrumPVGWithEthClient(rpc, conf.SupportedEntryPoints[0]))
6363
}
6464

6565
mem, err := mempool.New(db)

pkg/arbitrum/nodeinterface/constants.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,5 @@ package nodeinterface
33
import "github.com/ethereum/go-ethereum/common"
44

55
var (
6-
ERC4337GasHelperAddress = common.HexToAddress("0x559e3c6A74678FDBE1Fcc54153A8D7Dd7049FBCA")
7-
PrecompileAddress = common.HexToAddress("0x00000000000000000000000000000000000000C8")
6+
PrecompileAddress = common.HexToAddress("0x00000000000000000000000000000000000000C8")
87
)

pkg/gas/pvg.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ func calcPVGFuncNoop() CalcPreVerificationGasFunc {
2929
// https://medium.com/offchainlabs/understanding-arbitrum-2-dimensional-fees-fd1d582596c9.
3030
func CalcArbitrumPVGWithEthClient(
3131
rpc *rpc.Client,
32+
entryPoint common.Address,
3233
) CalcPreVerificationGasFunc {
3334
pk, _ := crypto.GenerateKey()
3435
dummy, _ := signer.New(hexutil.Encode(crypto.FromECDSA(pk))[2:])
@@ -48,7 +49,7 @@ func CalcArbitrumPVGWithEthClient(
4849
create = true
4950
}
5051
ge, err := nodeinterface.GasEstimateL1ComponentMethod.Inputs.Pack(
51-
nodeinterface.ERC4337GasHelperAddress,
52+
entryPoint,
5253
create,
5354
append(methods.HandleOpsMethod.ID, ho...),
5455
)

0 commit comments

Comments
 (0)