op-run-block

command
v1.13.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 15, 2025 License: MIT Imports: 30 Imported by: 0

README

op-run-block

This tool enables local op-geth EVM debugging, to re-run bad blocks in a controlled local environment, where arbitrary tracers can be attached, and experimental changes can be tested quickly.

This helps debug why these blocks may fail or diverge in unexpected ways. E.g. a block produced by op-reth that does not get accepted by op-geth can be replayed in a debugger to find what is happening.

Usage

go run . --rpc=http://my-debug-geth-endpoint:8545 --block=badblock.json --out=trace.txt

Where badblock.json looks like:

[
  {
    "block": {
      "timestamp": ...
      "number": ...
      "transactions": [ ... ],
      ...
    }
  }
]

This type of block can be collected with:

cast rpc --rpc-url=http://localhost:8545 debug_getBadBlocks

See Go-ethereum debug RPC namespace docs: https://geth.ethereum.org/docs/interacting-with-geth/rpc/ns-debug

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL