-
Notifications
You must be signed in to change notification settings - Fork 105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(forks,tests): Add EIP-7623 #1004
Conversation
tests/prague/eip7623_increase_calldata_cost/test_transaction_validity.py
Outdated
Show resolved
Hide resolved
tests/prague/eip7623_increase_calldata_cost/test_transaction_validity.py
Outdated
Show resolved
Hide resolved
tests/prague/eip7623_increase_calldata_cost/test_transaction_validity.py
Show resolved
Hide resolved
tests/prague/eip7623_increase_calldata_cost/test_transaction_validity.py
Show resolved
Hide resolved
tests/prague/eip7623_increase_calldata_cost/test_transaction_validity.py
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added some comments, quick review
this is a good eip for transaction tests. in tx tests we assume that intrinsic gas rules are still checked. so if tx deserialization is ok, but didn't pass intrinsic gas check such tx test is invalid tx.
by playing with transaction format in any way we want we can parametrize transaction fields in transaction test
not building env,pre,blocks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A small suggestion for docs style but otherwise looks great!
Co-authored-by: Stuart Reed <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks really good. Just one minor nit on the helper function name :)
Co-authored-by: danceratopz <[email protected]>
* feat(forks): Add EIP-7623 logic to gas calculation * fix(tests): Broken tests due to gas cost change * feat(forks): Add `transaction_data_floor_cost_calculator` * new(tests): EIP-7623: Add transaction validity tests * review comments * new(tests): EIP-7623: Add gas consumption tests * refactor(tests): EIP-7623: minor refactor * Update src/ethereum_test_forks/base_fork.py Co-authored-by: Stuart Reed <[email protected]> * Update src/ethereum_test_forks/base_fork.py * Apply suggestions from code review Co-authored-by: danceratopz <[email protected]> * fix(forks): tox * docs: changelog --------- Co-authored-by: Stuart Reed <[email protected]> Co-authored-by: danceratopz <[email protected]>
🗒️ Description
Adds tests for EIP-7623: Increase calldata cost.
Framework changes
Modifies
transaction_intrinsic_cost_calculator
that is returned by the fork objects to account for the extra intrinsic cost that the EIP adds.Also a new parameter is added to the function in order to return different values depending on how the function is used:
Fix Existing Tests
Some tests were broken because they needed a transaction to start with a deterministic amount of gas and also with a given calldata length.
Solution to most of these issues was to add an access list so the intrinsic gas cost exceeded the new floor data cost.
🔗 Related Issues
None
✅ Checklist
mkdocs serve
locally and verified the auto-generated docs for new tests in the Test Case Reference are correctly formatted.