From 60071aa750f9bfc4ff60b381e2ad4800c21e1838 Mon Sep 17 00:00:00 2001 From: hiepnv90 <87631229+hiepnv90@users.noreply.github.com> Date: Thu, 28 Nov 2024 17:24:00 +0700 Subject: [PATCH] Remove estimate gas with block overrides (#100) --- pkg/eth/simulator.go | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/pkg/eth/simulator.go b/pkg/eth/simulator.go index bc077ac..11b8c8f 100644 --- a/pkg/eth/simulator.go +++ b/pkg/eth/simulator.go @@ -45,20 +45,6 @@ func (s *Simulator) CallContract( return s.gethClient.CallContract(ctx, msg, blockNumber, overrides) } -func (s *Simulator) EstimateGasWithBlockOverrides( - ctx context.Context, msg ethereum.CallMsg, blockNumber *big.Int, - overrides *map[common.Address]gethclient.OverrideAccount, - blockOverrides gethclient.BlockOverrides, -) (uint64, error) { - var gas hexutil.Uint64 - err := s.c.CallContext( - ctx, &gas, "eth_estimateGas", mev.ToCallArg(msg), - toBlockNumArg(blockNumber), overrides, blockOverrides, - ) - - return uint64(gas), err -} - func toBlockNumArg(number *big.Int) string { if number == nil { return "latest"