eth/fetcher: track legacypool duplicate transaction

This commit is contained in:
moomin 2023-10-23 14:17:05 +09:00 committed by GitHub
parent ffc6a0f36e
commit 77892376f2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -341,7 +341,7 @@ func (f *TxFetcher) Enqueue(peer string, txs []*types.Transaction, direct bool)
switch {
case err == nil: // Noop, but need to handle to not count these
case errors.Is(err, txpool.ErrAlreadyKnown):
case errors.Is(err, txpool.ErrAlreadyKnown) || errors.Is(err, legacypool.ErrAlreadyKnown):
duplicate++
case errors.Is(err, txpool.ErrUnderpriced) || errors.Is(err, txpool.ErrReplaceUnderpriced):