foundry icon indicating copy to clipboard operation
foundry copied to clipboard

bug(`anvil`): `debug_traceTransaction` does not work for local txs (after fork)

Open monokh opened this issue 1 year ago • 0 comments

Component

Anvil

Have you ensured that all of these are up to date?

  • [X] Foundry
  • [X] Foundryup

What version of Foundry are you on?

forge 0.2.0 (588a1d7 2024-06-19T00:23:02.274658000Z)

What command(s) is the bug in?

anvil

Operating System

macOS (Apple Silicon)

Describe the bug

Trying the callTracer tracer with debug_traceTransaction It works for transactions that have been mined previous to the fork. But transactions added to the chain after the fork locally do not return the call trace.

Example

{"jsonrpc": "2.0","id": "123","method": "debug_traceTransaction","params": ["0x2d70cab1a3481c03fecf2909192cfa6601fb60b3239d982694cfa787e44f2d1e", {"tracer": "callTracer"}]}
{
    "jsonrpc": "2.0",
    "id": "123",
    "result": {
        "failed": false,
        "gas": 119470,
        "returnValue": "",
        "structLogs": []
    }
}

All trace types in fact return this same response.

Works completely fine for transactions that are mined before the fork. I suppose as they result in a direct call to the node.

monokh avatar Aug 15 '24 15:08 monokh