Skip to content

do not create receipts for invisible txs#2997

Merged
codchen merged 3 commits intomainfrom
tony/no-receipt-for-no-nonce-bump
Mar 6, 2026
Merged

do not create receipts for invisible txs#2997
codchen merged 3 commits intomainfrom
tony/no-receipt-for-no-nonce-bump

Conversation

@codchen
Copy link
Collaborator

@codchen codchen commented Mar 2, 2026

Describe your changes and provide context

Historically we've been creating artificial receipts for transactions that fail ante handler (i.e. before the tx even enters the EVM). This creates inconsistency in the case where a transaction fails in a way that doesn't bump nonce (which would make the transaction invisible from RPC responses). This PR addresses that inconsistency by not creating receipts for transactions that don't bump nonce.

Testing performed to validate your change

unit tests

@github-actions
Copy link

github-actions bot commented Mar 2, 2026

The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedMar 6, 2026, 9:11 AM

@github-actions
Copy link

github-actions bot commented Mar 2, 2026

The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedMar 2, 2026, 6:12 AM

@codecov
Copy link

codecov bot commented Mar 2, 2026

Codecov Report

❌ Patch coverage is 81.25000% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 58.41%. Comparing base (105d090) to head (75345e4).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
evmrpc/block.go 33.33% 1 Missing and 1 partial ⚠️
x/evm/ante/basic.go 0.00% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2997      +/-   ##
==========================================
+ Coverage   58.25%   58.41%   +0.15%     
==========================================
  Files        2077     2110      +33     
  Lines      171294   175022    +3728     
==========================================
+ Hits        99786   102231    +2445     
- Misses      62614    63765    +1151     
- Partials     8894     9026     +132     
Flag Coverage Δ
sei-chain-pr 64.10% <81.25%> (?)
sei-db 70.41% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
app/ante/evm_delivertx.go 72.54% <100.00%> (+0.54%) ⬆️
evmrpc/info.go 76.95% <100.00%> (+3.29%) ⬆️
x/evm/keeper/abci.go 56.31% <100.00%> (+0.86%) ⬆️
x/evm/keeper/deferred.go 80.70% <100.00%> (+3.15%) ⬆️
x/evm/types/keys.go 98.30% <ø> (ø)
x/evm/ante/basic.go 71.42% <0.00%> (-2.65%) ⬇️
evmrpc/block.go 76.05% <33.33%> (-0.54%) ⬇️

... and 72 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

for _, deferredInfo := range evmTxDeferredInfoList {
txHash := common.BytesToHash(deferredInfo.TxHash)
if deferredInfo.Error != "" && txHash.Cmp(ethtypes.EmptyTxsHash) != 0 {
if !k.GetNonceBumped(ctx, deferredInfo.TxIndex) {

Check warning

Code scanning / CodeQL

Panic in BeginBock or EndBlock consensus methods Warning

path flow from Begin/EndBlock to a panic call
path flow from Begin/EndBlock to a panic call
path flow from Begin/EndBlock to a panic call
path flow from Begin/EndBlock to a panic call
path flow from Begin/EndBlock to a panic call
@codchen codchen force-pushed the tony/no-receipt-for-no-nonce-bump branch from e8ea49f to f3047ff Compare March 5, 2026 06:31
@codchen codchen enabled auto-merge (squash) March 6, 2026 09:11
@codchen codchen merged commit 13e5513 into main Mar 6, 2026
39 checks passed
@codchen codchen deleted the tony/no-receipt-for-no-nonce-bump branch March 6, 2026 09:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants