Skip to content

rpc: eth_estimateGas returns value greater than expected #17869

@canepat

Description

@canepat

A user on Discord is calling eth_estimateGas on erigon 3.2.2:

{
    "jsonrpc": "2.0",
    "method": "eth_estimateGas",
    "params": [
      {
        "from": "0xF21079d225F4f3e7FDd3E258042a55cED651b2a1",
        "to": "0xa9D53f7B4836a595db7E11A7f92F9EF3810E04B6",
        "data": "0x46c474a60000000000000000000000000000000000000000000000000000000000bc614e00000000000000000000000000000000000000000000000000000000000f455a000000000000000000000000125f4b6650e205a987ba92972a87c833dcf5a84700000000000000000000000000000000000000000000000000000000000f455a"
      },
      "latest",
      {
        "0xdAC17F958D2ee523a2206206994597C13D831ec7": {
          "stateDiff": {
            "0xe8668fbdcb49eea01f71c55f2c539b0953b137a92283519b2e33d48a03e1e3e7": "0x000000000000000000000000000000000000000000000000000000000098a0a8",
            "0xa2d1bb9934928c34b005700965f54467eef400cea7fd9fbfc0d1d1eb2184eee8": "0x000000000000000000000000000000000000000000000000000000000098a0a8"
          }
        },
        "0xa9D53f7B4836a595db7E11A7f92F9EF3810E04B6": {
          "stateDiff": {
            "0xe8668fbdcb49eea01f71c55f2c539b0953b137a92283519b2e33d48a03e1e3e7": "0x000000000000000000000000000000000000000000000000000000000098a0a8",
            "0xa2d1bb9934928c34b005700965f54467eef400cea7fd9fbfc0d1d1eb2184eee8": "0x000000000000000000000000000000000000000000000000000000000098a0a8"
          }
        },
        "0xF21079d225F4f3e7FDd3E258042a55cED651b2a1": {
          "nonce": "0x1",
          "balance": "0x2386f26fc10000"
        }
      }
    ],
    "id": 1
  }

and gets 45m as result, while other nodes return significantly less value 97,825 (without stateOverrides the returned value seems good).

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions