Skip to content

[pallet-revive] eth-rpc: fix latest block initialization and reduce per-block RPC calls. - #12742

Open
marian-radu wants to merge 9 commits into
masterfrom
mr/eth-rpc-seed-latest-best-block
Open

[pallet-revive] eth-rpc: fix latest block initialization and reduce per-block RPC calls.#12742
marian-radu wants to merge 9 commits into
masterfrom
mr/eth-rpc-seed-latest-best-block

Conversation

@marian-radu

@marian-radu marian-radu commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

Both the finalized and best blocks were initialized using at_current_block(), which in subxt 0.50 returns the finalized block; the best block therefore started behind the chain tip and served stale blocks until the subscription caught up. Also reduce the number of RPC calls by reusing the already resolved block in fetch_receipt_data, and by only requesting receipt data when a block contains EVM extrinsics.

Changes

  • Initialize latest_block from the actual best block.
  • Make update_latest monotonic, so the startup backlog replayed by subxt 0.50's chainHead subscription can no longer walk a head backwards.
  • Pass the already resolved block to fetch_receipt_data instead of a hash.
  • Only request receipt data when the block contains pallet-revive extrinsics.
  • Raise the differential-tests job timeout from 60 to 120 minutes; the full corpus no longer finishes within 60 minutes since the subxt 0.50 bump. Further investigation of the slowdown will be tackled separately.

@marian-radu
marian-radu requested review from a team as code owners July 27, 2026 12:53
@paritytech-workflow-stopper

Copy link
Copy Markdown

All GitHub workflows were cancelled due to failure one of the required jobs.
Failed workflow url: https://github.com/paritytech/polkadot-sdk/actions/runs/30274690581
Failed job name: fmt

@marian-radu marian-radu added the T7-smart_contracts This PR/Issue is related to smart contracts. label Jul 27, 2026
@marian-radu marian-radu changed the title [pallet-revive] Fix eth-rpc latest being initialized from the finalized block [pallet-revive] eth-rpc: fix latest block initialization and reduce per-block RPC calls. Jul 28, 2026
@marian-radu

Copy link
Copy Markdown
Contributor Author

/cmd prdoc --audience runtime_dev --bump patch

@marian-radu
marian-radu requested review from 0xOmarA and mokita-j July 28, 2026 11:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

T7-smart_contracts This PR/Issue is related to smart contracts.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant