Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tracer doesn't detect out-of-gas errors #3394

Open
JackHamer09 opened this issue Dec 17, 2024 · 0 comments
Open

Tracer doesn't detect out-of-gas errors #3394

JackHamer09 opened this issue Dec 17, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@JackHamer09
Copy link
Member

🐛 Bug Report

📝 Description

When making debug_traceBlockByNumber RPC request for transactions that failed with out-of-gas error response would not include anything in the error field.

🔄 Reproduction Steps

curl 'https://mainnet.era.zksync.io' \
  --header 'Content-Type: application/json' \
  --request POST \
  --data-raw '{
    "id": 0,
    "method": "debug_traceTransaction",
    "params": [
      "0x1d55f591f2dec2db4ede9dfdf1e921c38f315daeddfc5f4f690ab13c1fa0cc72",
      {
        "tracer": "flatCallTracer",
        "timeout": "160s"
      }
    ],
    "jsonrpc": "2.0"
  }'

Example transactions:
Block 2558830 -> Tx: 0x1d55f591f2dec2db4ede9dfdf1e921c38f315daeddfc5f4f690ab13c1fa0cc72 (example listed above)
Block 2637427 -> Tx: 0xacb4bb951661950a9cb0df04f3e5ce8dce37c98a684924a07e1bab5f118202c8
Block 2610752 -> Tx: 0x38822e3ef0298e9131790333356986d5051784861e43e602da5a9b97b8c66118
Block 2579103 -> Tx: 0x45634aa7756181707f1b8e6ef6404069c4f2c4506f20466ed637850a113237ab
Block 2642447 -> Tx: 0x94fc982c4c2fb8146912f15a362bb5292e8094a77ec68c6be243e5861cec2321

🤔 Expected Behavior

error field includes error message

😯 Current Behavior

In the response error field would be null.

🖥️ Environment

Mainnet

📋 Additional Context

Github Discussion report - zkSync-Community-Hub/zksync-developers#836

📎 Log Output

{
    "jsonrpc": "2.0",
    "id": 0,
    "result": [{
        "action": {
            "callType": "call",
            "from": "0x0000000000000000000000000000000000000000",
            "gas": "0x1063d5",
            "input": "0xdb6b5246",
            "to": "0x0000000000000000000000000000000000008001",
            "value": "0x470de4df8200000"
        },
        "blockHash": "0x4b8268fa115a5835c6cb7f9e57316feff422ca478d6d7f89fcc34b4e0068bd3f",
        "blockNumber": 2558830,
        "error": null,
        "result": {
            "gasUsed": "0x1063c9",
            "output": "0x"
        },
        "subtraces": 17,
        "traceAddress": [1],
        "transactionHash": "0x1d55f591f2dec2db4ede9dfdf1e921c38f315daeddfc5f4f690ab13c1fa0cc72",
        "transactionPosition": 1,
        "type": "call"
    }]
}
@JackHamer09 JackHamer09 added the bug Something isn't working label Dec 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant