This repository has been archived by the owner on Oct 25, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 137
Toggleable discard for failed revertible transaction hashes #81
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…. Add support for dropping revertible transaction hashes in sbundle. Update logic to prevent naked transactions from being discarded since only bundles and sbundles currently support specifying revertible transaction hashes
Ruteri
reviewed
Jul 3, 2023
dvush
reviewed
Jul 3, 2023
…ons on error, remove unnecessary from commit tx function, add additional unit test that includes bundle when it contains revertible tx that we wish to discard
Wazzymandias
changed the title
Toggleable transaction discard for reverted transaction hashes
Toggleable discard for failed revertible transaction hashes
Jul 4, 2023
Ruteri
reviewed
Jul 5, 2023
Ruteri
approved these changes
Jul 5, 2023
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.
Deferring decision on the conventions to @dvush and @avalonche since they frequent this codebase more than I do
avalonche
reviewed
Jul 5, 2023
@@ -1944,7 +1949,10 @@ func containsHash(arr []common.Hash, match common.Hash) bool { | |||
|
|||
// Compute the adjusted gas price for a whole bundle | |||
// Done by calculating all gas spent, adding transfers to the coinbase, and then dividing by gas used | |||
func (w *worker) computeBundleGas(env *environment, bundle types.MevBundle, state *state.StateDB, gasPool *core.GasPool, pendingTxs map[common.Address]types.Transactions, currentTxCount int) (simulatedBundle, error) { | |||
func (w *worker) computeBundleGas( |
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.
can consider restructuring these args into a struct
avalonche
reviewed
Jul 5, 2023
avalonche
reviewed
Jul 5, 2023
avalonche
reviewed
Jul 5, 2023
avalonche
reviewed
Jul 5, 2023
avalonche
approved these changes
Jul 5, 2023
dvush
approved these changes
Jul 5, 2023
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 correct to me
re: styling - I think breaking lines looks better but no strong opinion this or that way
Wazzymandias
force-pushed
the
bundle-tx-discard
branch
from
August 2, 2023 19:26
e8a3fe1
to
4bd0c15
Compare
Wazzymandias
force-pushed
the
bundle-tx-discard
branch
from
August 2, 2023 19:29
4bd0c15
to
a1b5e6a
Compare
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
📝 Summary
Current behavior of bundles is that:
This PR makes it so when users specify reverting transaction hashes in their request, the builder discards the transaction(s) on error
Changes
📚 References
CONTRIBUTING.md