test_dispatched_frame_state_gas_still_refills_on_revert()¶
Documentation for tests/amsterdam/eip2780_reduce_intrinsic_tx_gas/test_authorization_oog.py::test_dispatched_frame_state_gas_still_refills_on_revert@26332146.
Generate fixtures for these test cases for Amsterdam with:
fill -v tests/amsterdam/eip2780_reduce_intrinsic_tx_gas/test_authorization_oog.py::test_dispatched_frame_state_gas_still_refills_on_revert --fork Amsterdam
State gas charged inside the dispatched call is still refilled when that call reverts, in the same transaction whose authorization state gas must stay consumed.
The authorization sets a delegation on an existing EOA
(AUTH_BASE, persists across the revert). The recipient then
SSTOREs a fresh slot -- charging STORAGE_SET state gas --
and reverts, rolling the slot back, so that state gas is refilled.
This brackets the rollback boundary from both sides: the current
over-refill (returning the AUTH_BASE too) underpays by 35,190,
while an over-correction that stops refilling frame state gas
altogether would overcharge by the 97,920 STORAGE_SET.
Source code in tests/amsterdam/eip2780_reduce_intrinsic_tx_gas/test_authorization_oog.py
1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 | |
Parametrized Test Cases¶
This test generates 1 parametrized test case across 1 fork.