flashbots / mev-geth

Go implementation of MEV-Auction for Ethereum
GNU Lesser General Public License v3.0
788 stars 198 forks source link

Call eth_callBundle allow to defined state on the selected transaction #116

Closed hugo082 closed 2 years ago

hugo082 commented 2 years ago

In order to allow an easier transaction simulation via the eth_callBundle method, we introduce a new parameter stateTransactionHash that should be in the stateBlockNumber child. If this parameter is provided, we will execute all transactions from index 0 to the state transaction index (included).

Example

A call to eth_callBundle with:

hugo082 commented 2 years ago

I will work on it to fix tests, can you just give me some feedback to confirm the chosen solution? Maybe there is a more efficient way to implement this feature? 🚀

Ruteri commented 2 years ago

This will be too much of a dos vector to have enabled by default. If it's something you need it should be behind a feature flag