Skip to content

Commit d8a1c9e

Browse files
authored
fix: race condition in antecache (#775)
1 parent bd820ee commit d8a1c9e

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
4343
* (evm) [#728](https://github.com/crypto-org-chain/ethermint/pull/728) feat: support preinstalls
4444
* (evm) [#722](https://github.com/crypto-org-chain/ethermint/pull/722) feat: support EIP-2935
4545
* (rpc) [#764](https://github.com/crypto-org-chain/ethermint/pull/764) rpc: apply state overrides to eth_estimateGas
46+
* (ante) [#775](https://github.com/crypto-org-chain/ethermint/pull/775) fix: race condition in antecache
4647

4748
## [v0.22.0] - 2025-08-12
4849

ante/eth.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -311,6 +311,10 @@ func CheckAndSetEthSenderNonce(
311311

312312
// nonce verification, the sequence needs to be in order
313313
if txNonce != expectedNonce {
314+
// delete in case of recheck tx
315+
if ex {
316+
cache.Delete(fromStr, txNonce)
317+
}
314318
return errorsmod.Wrapf(
315319
errortypes.ErrInvalidSequence,
316320
"invalid nonce; got %d, expected %d", txNonce, expectedNonce,

0 commit comments

Comments
 (0)