go-ethereum/internal
Minhyuk Kim 59405c40d3
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
eth/gasestimator: check ErrGasLimitTooHigh conditions (#32348)
This PR makes 2 changes to how
[EIP-7825](https://github.com/ethereum/go-ethereum/pull/31824) behaves.

When `eth_estimateGas` or `eth_createAccessList` is called without any
gas limit in the payload, geth will choose the block's gas limit or the
`RPCGasCap`, which can be larger than the `maxTxGas`.

When this happens for `estimateGas`, the gas estimation just errors out
and ends, when it should continue doing binary search to find the lowest
possible gas limit.

This PR will: 
- Add a check to see if `hi` is larger than `maxTxGas` and cap it to
`maxTxGas` if it's larger. And add a special case handling for gas
estimation execute when it errs with `ErrGasLimitTooHigh`

---------

Co-authored-by: Gary Rong <garyrong0905@gmail.com>
2025-08-05 19:51:16 +08:00
..
blocktest internal/blocktest: add package for shared test code (#27270) 2023-07-11 14:57:02 +02:00
build internal/build: add support for Github Actions CI environment (#31891) 2025-05-23 17:48:15 +02:00
cmdtest cmd/geth, internal: fix flaky console tests (#31784) 2025-05-08 15:15:36 +02:00
debug cmd/utils, internal/debug: hide the deprecated flags (#32128) 2025-07-03 13:23:00 +08:00
download cmd/geth, internal/era/eradl: add era1 downloader tool (#31823) 2025-05-15 22:53:26 +02:00
era core/rawdb: integrate eradb backend for RPC (#31604) 2025-06-03 10:47:38 +02:00
ethapi eth/gasestimator: check ErrGasLimitTooHigh conditions (#32348) 2025-08-05 19:51:16 +08:00
flags .github, internal/flags: improve actions test runs (#32150) 2025-07-07 13:26:11 +02:00
guide all: fix typos in docs and comments (#31548) 2025-04-02 13:52:40 -06:00
jsre internal: remove unused shh and swarm modules from console (#32073) 2025-07-01 19:51:16 +08:00
reexec internal/reexec: fix broken link to Docker/Moby in comment (#31859) 2025-05-20 15:58:00 +08:00
shutdowncheck eth, les: update unclean shutdown markers regularly (#24077) 2021-12-17 15:18:51 +01:00
syncx core: improve shutdown synchronization in BlockChain (#22853) 2021-10-07 15:47:50 +02:00
testlog internal/testlog: fix log output from sub-loggers (#31539) 2025-04-10 18:21:32 +02:00
testrand triedb/pathdb: improve tests (#29278) 2024-03-19 10:50:08 +08:00
utesting internal: run tests in parallel (#30381) 2024-09-16 08:44:47 +02:00
version build, internal, version: break ci.go/version->common dependency (#30638) 2024-10-20 19:28:39 +03:00
web3ext cmd, eth, internal: introduce debug_sync (#32177) 2025-07-28 14:57:45 +08:00