From d71bfff5520d53ec916495f8c8b2b357a63e0313 Mon Sep 17 00:00:00 2001 From: Marius van der Wijden Date: Mon, 18 Dec 2023 11:31:02 +0100 Subject: [PATCH] eth/catalyst: add comment --- eth/catalyst/simulated_beacon.go | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/eth/catalyst/simulated_beacon.go b/eth/catalyst/simulated_beacon.go index 5c7971f42a..8c99c4e4ea 100644 --- a/eth/catalyst/simulated_beacon.go +++ b/eth/catalyst/simulated_beacon.go @@ -20,7 +20,6 @@ import ( "crypto/rand" "errors" "math" - "math/big" "sync" "time" @@ -31,7 +30,6 @@ import ( "github.com/ethereum/go-ethereum/eth" "github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/node" - "github.com/ethereum/go-ethereum/params" "github.com/ethereum/go-ethereum/rpc" ) @@ -284,11 +282,10 @@ func (c *SimulatedBeacon) Commit() common.Hash { // Rollback un-sends previously added transactions. func (c *SimulatedBeacon) Rollback() { - // Flush all transactions from the transaction pools - c.eth.TxPool().SetGasTip(big.NewInt(-1)) - // Set the gas tip back to accept new transactions - // TODO (Marius van der Wijden): set gas tip to parameter passed by config - c.eth.TxPool().SetGasTip(big.NewInt(params.GWei)) + // TODO (MariusVanDerWijden): implement a way in the transaction pool + // to flush _all_ transactions, even local transactions. + // Since the transactions send via the simulated backend are all + // send via the RPC, they end up all being local to the node } // Fork sets the head to the provided hash.