Skip to content

Remove support for sei_getTransactionReceipt API - #3945

Merged
masih merged 1 commit into
mainfrom
masih/sei-api-cleanup-get-recep
Aug 18, 2026
Merged

Remove support for sei_getTransactionReceipt API#3945
masih merged 1 commit into
mainfrom
masih/sei-api-cleanup-get-recep

Conversation

@masih

@masih masih commented Aug 18, 2026

Copy link
Copy Markdown
Collaborator

This API is deprecated and no longer supported by Sei. Users should use EVM flavour APIs instead.

This API is deprecated and no longer supported by Sei. Users should use EVM flavour APIs instead.
@github-actions

Copy link
Copy Markdown

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

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedAug 18, 2026, 11:28 AM

@codecov

codecov Bot commented Aug 18, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 58.56%. Comparing base (fab5625) to head (b3b9211).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #3945      +/-   ##
==========================================
- Coverage   59.60%   58.56%   -1.04%     
==========================================
  Files        2331     2232      -99     
  Lines      200124   188773   -11351     
==========================================
- Hits       119277   110563    -8714     
+ Misses      69413    67685    -1728     
+ Partials    11434    10525     -909     
Flag Coverage Δ
sei-chain-pr 73.08% <100.00%> (?)
sei-db 70.41% <ø> (-0.22%) ⬇️
sei-db-state-db ?

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

Files with missing lines Coverage Δ
evmrpc/config/config.go 97.27% <ø> (ø)
evmrpc/sei_legacy.go 89.47% <ø> (+13.35%) ⬆️
evmrpc/server.go 87.43% <ø> (-0.24%) ⬇️
evmrpc/tx.go 81.78% <100.00%> (-0.35%) ⬇️

... and 100 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.

@masih
masih marked this pull request as ready for review August 18, 2026 11:41
@cursor

cursor Bot commented Aug 18, 2026

Copy link
Copy Markdown

PR Summary

High Risk
Breaking change for integrations that relied on synthetic receipts for Cosmos-originated transactions; EVM receipt behavior is narrowed to non-synthetic paths only.

Overview
Removes the deprecated sei_getTransactionReceipt JSON-RPC method and the synthetic-receipt path that backed it. Callers must use standard eth_getTransactionReceipt / eth_getLogs instead; there is no remaining RPC for Cosmos-only txs that never produced an EVM receipt.

The sei transaction API (SeiTransactionAPI) is dropped from the HTTP server, and TransactionAPI no longer toggles includeSynthetic—receipt and block-tx lookups always use the EVM-only behavior (includeSynthetic false). Legacy gating now covers only sei_getSeiAddress, sei_getEVMAddress, and sei_getCosmosTx; listing sei_getTransactionReceipt in enabled_legacy_sei_apis is ignored. Docker configs, init templates, and docs are updated accordingly.

Contract and integration tests switch from sei_getTransactionReceipt to eth_getTransactionReceipt where appropriate; the CW20 pointer test derives the block from the wasm tx height instead of a Sei receipt.

Reviewed by Cursor Bugbot for commit b3b9211. Bugbot is set up for automated code reviews on this repo. Configure here.

@seidroid seidroid Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clean, well-scoped removal of sei_getTransactionReceipt: no dangling references to the removed symbols, config defaults/docker allowlists/golden and .iox fixtures stay consistent, and the JS switches to eth_getTransactionReceipt are behavior-equivalent for EVM-originated txs. Non-blocking: the unreleased CHANGELOG still tells clients to enable this method, the includeSynthetic plumbing is now hardcoded false at every call site, and a couple of tests lost the coverage they were named for.

Findings: 0 blocking | 5 non-blocking | 2 posted inline

Blockers

  • None at the file/PR level.

Non-blocking

  • CHANGELOG.md:38 (Unreleased → Upgrade guide, entry for #3927) still ends with "clients that know the synthetic transaction hash can enable sei_getTransactionReceipt" — this PR removes that capability in the same unreleased cycle, so that migration guidance is now wrong. Amend that entry (and/or add an entry for this PR) so the changelog matches evmrpc/README.md, which now correctly says there is no remaining JSON-RPC method for discovering Cosmos-originated synthetic logs.
  • In evmrpc/sei_legacy_test.go, the allowed-path tests were switched to sei_getCosmosTx but the blocked-path ones still use sei_getTransactionReceipt (lines 52, 129, 383, 410, 441, 622, 673, 698, 722, 744, 767, 796, 832). Since that name is no longer in seiLegacyGatedMethods, those tests now exercise the unknown-sei_*-name fail-closed branch (duplicating TestWrapSeiLegacyHTTP_UnknownSeiMethodBlocked) rather than the "registered gated method not in the allowlist" branch their names describe. Swapping them to a real gated name (e.g. sei_getCosmosTx) restores the intended coverage; today only the notification-batch test at line 723 still covers that branch.
  • 2 suggestion(s)/nit(s) flagged inline on specific lines.
  • 1 non-blocking pre-existing issue(s) listed below under pre-existing issues.

Pre-existing issues

  • [suggestion] BuildSeiLegacyEnabledSet (evmrpc/sei_legacy.go:60) silently drops list entries that aren't registered gated methods, and seiLegacyMethodDisabledMessage then tells callers of such a method "To allow this legacy method, add it to enabled_legacy_sei_apis under [evm] in app.toml" — advice that cannot work for a removed method. Operators who had uncommented the template's sei_getTransactionReceipt line get no startup warning that the value is now inert. A startup log for unrecognized enabled_legacy_sei_apis entries, or a distinct message for removed-vs-disabled methods, would avoid the misdirection (applies equally to the 20 names removed in #3927).

Comment thread evmrpc/tx.go
}
}
return encodeReceipt(t.ctxProvider, t.txConfigProvider, receipt, t.keeper, block, includeSynthetic, t.globalBlockCache, t.cacheCreationMutex)
return encodeReceipt(t.ctxProvider, t.txConfigProvider, receipt, t.keeper, block, false, t.globalBlockCache, t.cacheCreationMutex)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[suggestion] With the sei namespace gone, includeSynthetic is now false at every production call site: here, block.go:299 (encodeReceipt), block.go:178/222 (EncodeTmBlock), and tx.go:333/398 (filterTransactions). shouldIncludeSynthetic (utils.go:308) can likewise only be reached with "eth", since NewFilterAPI is only constructed with that namespace, so filter.go's includeSyntheticReceipts is permanently false and the *wasmtypes.MsgExecuteContract branch in filterTransactions (utils.go:251) is unreachable outside tests.

Threading a constant false through five signatures is the halfway state AGENTS.md "Structural corrections" warns about — the removal reads as complete at the API layer but leaves the parameter as a convention a future caller can misread. Consider dropping the parameter (and the now-dead synthetic branches plus shouldIncludeSynthetic) here or in an immediate follow-up, rather than leaving the literals in place.

expect(receipt).not.to.be.null;
console.log("receipt[\"blockNumber\"]", receipt["blockNumber"]);
const bn = receipt["blockNumber"];
const bn = `0x${Number(res.height).toString(16)}`;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[suggestion] res.height is only set to the real inclusion height when waitForAdminTxCommit's block-walk finds the tx (contracts/test/lib.js:1007); on the logged anomalous path it stays at the -b sync CheckTx default of "0". bn then becomes 0x0, and since this test's only remaining purpose is the negative assertion expect(ethlogs.length).to.equal(0) over exactly that one block, it would pass vacuously against block 0 instead of failing. A guard such as expect(Number(res.height)).to.be.greaterThan(0) before building the filter keeps the assertion meaningful.

@masih
masih added this pull request to the merge queue Aug 18, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Aug 18, 2026
@masih
masih added this pull request to the merge queue Aug 18, 2026
Merged via the queue into main with commit bc7bc2a Aug 18, 2026
92 of 96 checks passed
@masih
masih deleted the masih/sei-api-cleanup-get-recep branch August 18, 2026 15:19
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