Skip to content

Conversation

@marioevz
Copy link
Member

@marioevz marioevz commented Jul 19, 2025

🗒️ Description

Fixes all pre-Osaka python tests (outside of tests/cancun/eip4844_blobs which require further fixes) to use less gas than the new gas-limit-cap introduced by EIP-7825.

- tests/cancun/eip6780_selfdestruct/test_selfdestruct_revert.py

Reduced gas limit from 20 million to 500k (test was overusing gas).

- tests/istanbul/eip152_blake2/test_blake2.py

Test was using Environment().gas_limit to exhaust the block gas limit.
A new benchmark test must be developed to exhaust the gas limit with multiple txs (see ethereum/execution-specs#1571).

- tests/istanbul/eip1344_chainid/test_chainid.py

Reduced gas limit from 1 gigagas to 100k (test was overusing gas).

- tests/prague/eip6110_deposits/test_deposits.py

Deposit at deepest call depth possible, reduced the number of recursive calls to fit in a single tx.

- tests/prague/eip7002_el_triggerable_withdrawals/test_withdrawal_requests.py

Withdrawal at deepest call depth possible, reduced the number of recursive calls to fit in a single tx.

- tests/prague/eip7702_set_code_tx/test_gas.py

Single tx using as many authorizations as possible. Added track issue to add a new benchmark test (see ethereum/execution-specs#1571).

- tests/prague/eip7702_set_code_tx/test_set_code_txs.py

Recursive call into an authorized delegated account, the depth is now reduced due to the tx max gas limit.

- tests/prague/eip2537_bls_12_381_precompiles/test_bls12_pairing.py

Simple reduction of max gas that can be consumed for a test that pushes many times infinity to the pairing pre-compile.

- tests/prague/eip2537_bls_12_381_precompiles/test_bls12_variable_length_input_contracts.py

This is major rework on how the tests that cover the full precompile discount tables (G1 MSM, G2 MSM, and pairing).

We now use parametrize_by_fork to read the transaction gas limit cap and decide whether to split the discount table into multiple tests or a single one, and how many elements of the table per iteration it should test.

🔗 Related Issues or PRs

N/A.

✅ Checklist

  • All: Ran fast tox checks to avoid unnecessary CI fails, see also Code Standards and Enabling Pre-commit Checks:
    uvx --with=tox-uv tox -e lint,typecheck,spellcheck,markdownlint
  • All: PR title adheres to the repo standard - it will be used as the squash commit message and should start type(scope):.
  • All: Considered adding an entry to CHANGELOG.md.
  • All: Considered updating the online docs in the ./docs/ directory.
  • All: Set appropriate labels for the changes (only maintainers can apply labels).

@marioevz marioevz requested a review from spencer-tb July 19, 2025 00:40
@marioevz marioevz added scope:tests Scope: Changes EL client test cases in `./tests` fork:osaka Osaka hardfork labels Jul 19, 2025
@marioevz marioevz force-pushed the fix-pre-osaka-max-transaction-gas-limit-cap branch from 3bf6d86 to f670f90 Compare July 22, 2025 18:23
@spencer-tb spencer-tb force-pushed the fix-pre-osaka-max-transaction-gas-limit-cap branch from 2042772 to 2cca412 Compare July 25, 2025 17:19
@spencer-tb
Copy link
Collaborator

Updated the following tests:

  • tests/istanbul/eip152_blake2/test_blake2.py::test_blake2b_gas_limit
  • tests/istanbul/eip152_blake2/test_blake2.py::test_blake2b_large_gas_limit
  • tests/prague/eip6110_deposits/test_deposits.py
  • tests/cancun/eip1153_tstore/test_tstorage.py::test_run_until_out_of_gas

Copy link
Collaborator

@spencer-tb spencer-tb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks for working on this :)

@spencer-tb spencer-tb merged commit ae95b1b into main Jul 25, 2025
16 checks passed
@spencer-tb spencer-tb deleted the fix-pre-osaka-max-transaction-gas-limit-cap branch July 25, 2025 17:43
kclowes pushed a commit to kclowes/execution-spec-tests that referenced this pull request Oct 20, 2025
…ereum#1928)

* fix(tests): EIP-7825: Pre-Osaka tests consuming more than the tx gas limit cap

* fix(tests): EIP-7825: Pre-Osaka BLS tests consuming more than the tx gas limit cap

* fix: tox

* docs: changelog

* chore(tests): make blake2 use dynamic tx limit.

* chore(tests): update slow deposit tests.

* chore(tests): tstore run until out of gas test.

---------

Co-authored-by: spencer-tb <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fork:osaka Osaka hardfork scope:tests Scope: Changes EL client test cases in `./tests`

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants