diff --git a/eth/backend.go b/eth/backend.go index 99a358af2a..908bfd15b1 100644 --- a/eth/backend.go +++ b/eth/backend.go @@ -329,12 +329,14 @@ func New(stack *node.Node, config *ethconfig.Config) (*Ethereum, error) { config.BlobPool.Datadir = stack.ResolvePath(config.BlobPool.Datadir) } eth.blobTxPool = blobpool.New(config.BlobPool, eth.blockchain, legacyPool.HasPendingAuth) - eth.blobCache = blobpool.NewCache(eth.blobTxPool) eth.txPool, err = txpool.New(config.TxPool.PriceLimit, eth.blockchain, []txpool.SubPool{legacyPool, eth.blobTxPool}) if err != nil { return nil, err } + // Only after txpool.New has run the pool's Init: the cache reads the pool's + // lookup and store, which Init builds without holding the pool lock. + eth.blobCache = blobpool.NewCache(eth.blobTxPool) if !config.TxPool.NoLocals { rejournal := config.TxPool.Rejournal