Frame Transactions (EIP-8141) - #3047
Conversation
362b750 to
1402c53
Compare
1402c53 to
2f8aa48
Compare
|
Note to reviewers: The first commit of this PR I have built the frame transaction implementation on top of the re-factor since the changes introduced in the refactor make it much nicer to implement frames. Once PR#3192 gets approved and merged, I will rebase this PR branch. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## eips/amsterdam/eip-8141 #3047 +/- ##
===========================================================
- Coverage 93.49% 93.13% -0.37%
===========================================================
Files 624 576 -48
Lines 37056 33246 -3810
Branches 3394 2975 -419
===========================================================
- Hits 34647 30962 -3685
+ Misses 1653 1586 -67
+ Partials 756 698 -58
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
2f8aa48 to
aef48b6
Compare
Implement the type-6 frame transaction flow on the amsterdam fork, separated from the regular flow from admission onwards: - static validation, signature verification, intrinsic gas, and the two gas anchors (standard_gas_limit, max_gas) in transactions/frame_transaction.py - consensus receipt types (FrameReceipt, FrameTransactionReceipt) and the 0x06 receipt codec arms in blocks.py - TransactionEnvironment split into top_level_context/frame_context in vm/__init__.py - admission through a dedicated check_frame_transaction in frame_processing.py; process_transaction dispatches frame transactions after the chain-id check - frames execute as independent top-level calls in vm/frame_interpreter.py: per-frame gas meters, atomic batches, cross-frame warm journal, default verify code, approval rollback - the six frame opcodes (TXPARAM, FRAMEDATALOAD, FRAMEDATACOPY, FRAMEPARAM, SIGPARAM, APPROVE) in vm/instructions/frame.py - settlement anchored on the standard gas limit with the calldata floor binding through max_gas; the payer refund is max_cost - charged_fee; the frame transaction receipt reports status, gas, and logs per frame Co-authored-by: lightclient <lightclient@protonmail.com>
Co-authored-by: lightclient <lightclient@protonmail.com>
Co-authored-by: lightclient <lightclient@protonmail.com>
aef48b6 to
fb05113
Compare
Co-authored-by: lightclient <lightclient@protonmail.com>
fb05113 to
7f4ee85
Compare
| VERSIONED_HASH_VERSION_KZG, | ||
| ) | ||
|
|
||
| if U256(tx.nonce) >= U256(U64.MAX_VALUE): |
EIP-8141 aligned the SIGPARAM (0xb4) copy operation's stack order with CALLDATACOPY (ethereum/EIPs 4a9ad32c): after signatureIndex and param the operands are memOffset, dataOffset, length. The implementation still popped them in the old order (length, dataOffset, memOffset) — the reverse of its own FRAMEDATACOPY. Swap to match the live spec.
Frame transaction processing initializes the shared, once-per-tx warm address set with the sender so its first EVM access is charged warm (100) rather than cold (2600). The sender is loaded unconditionally for the nonce check and, like a regular transaction's origin, must start warm per EIP-2929 and EIP-3651.
|
Hey I made a couple of fixes, opened PRs: |
fix: correct SIGPARAM copy operand order
cb6d6cf to
94b7234
Compare
fix: warm the sender for frame transactions
Thanks @Marchhill |
🗒️ Description
My work so far on frame transactions (EIP-8141)
Cute Animal Picture