You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(l1): have block execution stop when block's gas limit is surpassed by executing a transaction (#5185)
**Motivation**
The ef test for Osaka that's run in the Hive integration testing site
named
`osaka/eip7825_transaction_gas_limit_cap/test_tx_gas_limit.py::test_tx_gas_larger_than_block_gas_limit[fork_Osaka-blockchain_test_engine-exceed_block_gas_limit_False]`
is failing due to an error message mismatch. See
[here](https://hive.ethpandaops.io/#/test/fusaka/1762265312-8631b0f0f5ea8f900a071365137dd155?testnumber=364).
Besides we don't have any logic implemented when processing a block to
stop computing transactions once the block's gas limit was surpassed.
**Description**
This pr adds a conditional to check if the block's gas limit can be
potentially surpassed, and in that case stop computing any other
transactions. So if tx.gas_limit > gas_available the block's execution
must stop with an exception, as the spec says
[here](https://github.com/ethereum/execution-specs/blob/69364e2133e1d20f679455fc92680366cb72db37/src/ethereum/forks/osaka/fork.py#L460).
To test it I run:
```
make build-image
cd hive
./hive --sim ethereum/eels/consume-engine --client ethrex --results-root results --client-file=../fixtures/hive/clients.yaml --sim.buildarg fixtures=https://github.com/ethereum/execution-spec-tests/releases/download/v5.3.0/fixtures_develop.tar.gz --sim.buildarg branch=forks/osaka --sim.loglevel=3 --sim.limit=".*test_tx_gas_larger_than_block_gas_limit.*"
```
0 commit comments