Skip to content
This repository was archived by the owner on Oct 25, 2024. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion miner/worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -1547,11 +1547,22 @@ func (w *worker) generateWork(params *generateParams) (*types.Block, *big.Int, e
orderCloseTime := time.Now()

blockBundles, allBundles, usedSbundles, mempoolTxHashes, err := w.fillTransactionsSelectAlgo(nil, work)

if err != nil {
return nil, nil, err
}

// We mark transactions created by the builder as mempool transactions so code validating bundles will not fail
// for transactions created by the builder such as mev share refunds.
for _, tx := range work.txs {
from, err := types.Sender(work.signer, tx)
if err != nil {
return nil, nil, err
}
if from == work.coinbase {
mempoolTxHashes[tx.Hash()] = struct{}{}
}
}

err = VerifyBundlesAtomicity(work, blockBundles, allBundles, usedSbundles, mempoolTxHashes)
if err != nil {
log.Error("Bundle invariant is violated for built block", "block", work.header.Number, "err", err)
Expand Down