Skip to content

op-reth: settle SDM refunds in block-level RPC replays - #23616

Closed
geoknee wants to merge 3 commits into
geoknee/sdm-rpc-replay-per-txfrom
geoknee/sdm-rpc-replay-block-level
Closed

geoknee wants to merge 3 commits into
geoknee/sdm-rpc-replay-per-txfrom
geoknee/sdm-rpc-replay-block-level

Conversation

@geoknee

@geoknee geoknee commented Oct 23, 2026

Copy link
Copy Markdown
Contributor

Step 3 of the plan in ethereum-optimism/protocol-team#485, stacked on #23615: settle SDM refunds in the block-level RPC replays.

Pins reth to ethereum-optimism/reth#25, which moves reth's block replay loops behind defaulted Trace methods without changing their behavior. OpEthApi overrides them to replay through the block executor: trace_block_transactions (trace_block, trace_replayBlockTransactions, trace_filter, ots_* block traces), debug_trace_block_transactions (debug_traceBlockByHash / ByNumber, raw debug_traceBlock, debug_traceBadBlock), debug_trace_chain_block_transactions (traceChain) and block_intermediate_roots (debug_intermediateRoots).

debug_traceBadBlock goes through the executor too, so a bad block that the executor rejects (block gas, DA footprint, SDM refund-list validation) now fails to trace instead of tracing pre-refund. A bare-EVM fallback for that case is possible if we want it.

The regression test now also covers raw debug_traceBlock (canonical gas again, as in @pcw109550's repro on #485), debug_traceBlockByNumber, debug_intermediateRoots and trace_replayBlockTransactions. Those assertions fail without the overrides and pass with them; the op-reth it suite passes, clippy is clean and just check-upstream-mirrors passes.

Do not merge yet: the reth pin is the head of the unmerged ethereum-optimism/reth#25. Repin to the merged fork commit or tag, and move optimism-premium's reth pin in step.

🤖 Generated with Claude Code

geoknee and others added 3 commits October 23, 2026 16:27
Extends the regression test to debug_traceBlock (raw), debug_traceBlockByNumber, debug_intermediateRoots and trace_replayBlockTransactions. Fails without executor-backed block replays.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Picks up the replay extension points on Trace. Also adds the trace types and revm-inspectors to reth-optimism-rpc for the block-level overrides.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
OpEthApi overrides the Trace extension points (trace_block_transactions, debug_trace_block_transactions, debug_trace_chain_block_transactions, block_intermediate_roots) to replay through the block executor. Fixes debug_traceBlock* including raw blocks, debug_intermediateRoots, traceChain, and trace_block / trace_replayBlockTransactions / trace_filter / ots block traces. debug_traceBadBlock now fails on blocks the executor rejects.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@einar-oplabs

Copy link
Copy Markdown
Contributor

Superseded by #23670, which combines the per-transaction and block-level overrides on ethereum-optimism/reth#26. Tracked in ethereum-optimism/protocol-team#485. Closing as superseded; branch kept.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants