-
Notifications
You must be signed in to change notification settings - Fork 5.3k
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
Add EIP: EVM Transaction Bundles #8684
Conversation
✅ All reviewers have approved. |
The commit 515eeb1 (as a parent of d7360d0) contains errors. |
EIPS/eip-7727.md
Outdated
The `BUNDLE_TX_TYPE` has a new gas cost formula. For the `BUNDLE_TX_TYPE` to be valid, it must have enough gas to cover: | ||
|
||
1. The `BUNDLE_TX_TYPE` transaction base cost of `BUNDLE_BASE_GAS_COST`. | ||
2. All bytes of the `transactionList` elements as if their bytes were part of a typical transaction’s `CALL_DATA`. | ||
|
||
The final gas cost of the `BUNDLE_TX_TYPE` depends on if the `transactionList`'s elements are valid transactions or not. The following logic is used on the `transactionList` elements: | ||
|
||
1. If an element is valid and can begin execution, the `BUNDLE_TX_TYPE` signer is not charged for that element’s bytes. | ||
2. If the element is not valid and cannot being execution, the `BUNDLE_TX_TYPE` is charged as if that element’s bytes were just `CALL_DATA`. | ||
|
||
At the start of processing, the `BUNDLE_TX_TYPE`'s signer must be charged as if all inner transactions were invalid and refunded the gas for the valid transactions as each valid transaction finishes execution. |
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.
Only include the actual gas formula in the specification section. The reasoning behind it should live in the rationale section. Helps to keep the specification as small and readable as possible.
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.
Do you mean I should have a code block instead of a verbal description? The words here are describing different parts of the gas costing logic and aren't justifications for it.
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 code block would definitely be fine, but it isn't necessary. I think I just misinterpreted the way you wrote this, honestly.
Instead of writing it as "it must have enough gas to cover...", I'd recommend wording it like:
The gas cost of BUNDLE_TX_TYPE is calculated as follows
BUNDLE_BASE_GAS_COST
plusFOO
timesBAR
, whereFOO
is zero if [...] and is seven otherwise.
Introducing the formula with "must have enough gas to cover" just doesn't sound precise enough.
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.
I updated it! Let me know if you think it still needs work, happy to refactor again.
Addressed all comments and left two questions. |
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.
All Reviewers Have Approved; Performing Automatic Merge...
EIP for magicians post: https://ethereum-magicians.org/t/eip-for-evm-native-bundles/20322