Skip to content
This repository has been archived by the owner on Jun 9, 2024. It is now read-only.

Commit

Permalink
adding time first seen check on tx hash
Browse files Browse the repository at this point in the history
  • Loading branch information
cyka-bera committed Jan 31, 2024
1 parent 06f3e3e commit 3877af2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions cosmos/runtime/txpool/ante.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ func (m *Mempool) validateStateless(ctx sdk.Context, tx *ethtypes.Transaction) b
// 1. If the transaction has been in the mempool for longer than the configured timeout.
// 2. If the transaction's gas params are less than or equal to the configured limit.
expired := currentTime-m.crc.TimeFirstSeen(txHash) > m.lifetime
ctx.Logger().Info("validateStateless", "currentTime", currentTime, "timeFirstSeen", m.crc.TimeFirstSeen(txHash), "expired", expired)
priceLeLimit := tx.GasPrice().Cmp(m.priceLimit) <= 0

if expired {
Expand Down

0 comments on commit 3877af2

Please sign in to comment.