Skip to content
This repository was archived by the owner on Jul 2, 2026. It is now read-only.

bal@v5.6.1

Pre-release
Pre-release

Choose a tag to compare

@spencer-tb spencer-tb released this 02 Apr 23:38
88e9fb8

bal-devnet-3 v7

⚠️ Hotfix for https://github.com/ethereum/execution-spec-tests/releases/bal@v5.6.0.
The past release did not include ethereum/execution-specs#2608.

Per-tx state gas pre-check removal

Spec fix (ethereum/execution-specs#2578): check_transaction was reserving the full tx gas limit against the state gas budget per-transaction, but EIP-8037 only defines block-level validation. This rejected valid blocks where individual txs exceeded the state gas budget but the block total was valid.

Test (ethereum/execution-specs#2583): Multi-tx block where individual txs exceed the state gas budget but the block total max(regular, state) <= gas_limit is valid.

CREATE state gas ordering (now active)

Spec fix (ethereum/execution-specs#2608): charge_state_gas(STATE_BYTES_PER_NEW_ACCOUNT) was called before the MAX_INIT_CODE_SIZE validation in create()/create2(). A CREATE with oversized initcode would persist state_gas_used for an account that was never created. Also moved is_static check before gas charging, consistent with SSTORE, CALL, and SELFDESTRUCT.

Test: Existing test_max_initcode_size_via_create[over_max] cases cover this scenario after re-fill.

Code deposit halt state gas

Test (ethereum/execution-specs#2595, by @qu0b): Initcode that performs state-creating operations (CALL to new account, inner CREATE) then triggers code deposit failure (oversized code or OOG). Verifies reverted GAS_NEW_ACCOUNT does not count in block_state_gas_used.

Note: These tests use the current EELS spec as source of truth, where state gas persists at the top level on failure. If the top-level reservoir refund (ethereum/EIPs#11476) is adopted for devnet-4, these tests will need replaced.

Block header gas_used verification

Test (ethereum/execution-specs#2611): 6 blockchain tests verifying block header gas_used via header_verify for CREATE, CREATE2, CALL, SSTORE, and SELFDESTRUCT. Catches client bugs where gas_used is reported incorrectly in the block header.

Block-level 2D gas accounting

Test (ethereum/execution-specs#2610, by @qu0b): 8 blockchain tests for block-level max(block_regular_gas, block_state_gas) accounting: state-dominant blocks, regular-dominant blocks, mixed tx interleaving, EIP-7778 refund non-reduction, exact-fit boundary, multi-block dimension flips, CALL/CREATE in 2D context.

Items Requiring Future Discussion

The following EIP-8037 spec changes are under discussion for devnet-4:

  • Top-level reservoir refund (ethereum/EIPs#11476): Currently, subcall revert/halt returns state gas to the parent's reservoir, but at depth 0 the sender still pays for state gas even when state changes are rolled back. The proposed change resets execution_state_gas_used to zero on top-level failure too, making behavior consistent at all call depths. Consensus is forming on the latter, but needs more discussion to isolate edge cases.

  • 0 -> x -> 0 storage reservoir refill: When storage goes 0 -> x -> 0 in the same transaction, the net state growth is zero but state gas is not returned to the reservoir. @rakita proposes refilling the reservoir when storage returns to its original zero value, analogous to how EIP-3529 refunds regular gas for storage clearing. Same applies to SELFDESTRUCT of a locally created account (CREATE charges state gas, SELFDESTRUCT removes it, net zero). No EIP PR yet and needs more discussion.

EIPs Reference

EIP Blob
EIP-7708 EIPS/eip-7708.md
EIP-7778 EIPS/eip-7778.md
EIP-7843 EIPS/eip-7843.md
EIP-7928 EIPS/eip-7928.md
EIP-7954 EIPS/eip-7954.md
EIP-8024 EIPS/eip-8024.md
EIP-8037 EIPS/eip-8037.md

Note: We are using a static cost_per_state_byte of 1174 (for all block gas limits) in devnet-3 only!

Full Changelog: https://github.com/ethereum/execution-specs/compare/tests-bal@v5.6.0...tests-bal@v5.6.1