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

[Request] Support OP Stack Chains' Transaction Receipt Fields #155

Open
MSilb7 opened this issue Dec 17, 2023 · 3 comments
Open

[Request] Support OP Stack Chains' Transaction Receipt Fields #155

MSilb7 opened this issue Dec 17, 2023 · 3 comments

Comments

@MSilb7
Copy link

MSilb7 commented Dec 17, 2023

Is your feature request related to a problem? Please describe.
OP Stack Chains contain extra fields in the transaction receipt that are required to calculate the L1 data fee portion of transaction fees:

  • l1Fee
  • l1FeeScalar
  • l1GasPrice
  • l1GasUsed

This may be due to an upstream ethers-rs dependency, but raising here first.

Describe the solution you'd like

Short-Term:

  • Either include these fields by default, or within the --include-columns all option

Longer-Term

  • Idea: Add a --chain-stack option, since Arbitrum also has its own extra receipt fields (effective_gas_price & gas_used_for_l1), and other stacks likely will as well.

Describe alternatives you've considered
N/A

Additional context

Example receipt response via Alchemy's eth_getTransactionReceipt - Optimism (I cut out logs manually):

{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "transactionHash": "0x38bddf161a79fd4e8a6cb5b84cd533ec8193014c89ba9b0b6a4b3ffd75ba1030",
    "blockHash": "0x5be845b408b60f80b4654836d4d819b787259dcd0235668cc1a08b608359100f",
    "blockNumber": "0x6c53b9b",
    ...
    ...
    ...
    "status": "0x1",
    "to": "0x0684076ee3595221861c50cdb9cb66402ec11cb9",
    "transactionIndex": "0x3",
    "type": "0x2",
    "l1Fee": "0xf422cbc70c6b",
    "l1FeeScalar": "0.684",
    "l1GasPrice": "0x796cdde4f",
    "l1GasUsed": "0x2f08"
  }
}
@ameya-deshmukh
Copy link

@sslivkoff is this something I can take up?

@MSilb7
Copy link
Author

MSilb7 commented Mar 10, 2024

Note for the Ecotone upgrade (Mar 14 - support for blobs) there will be two additional fields: l1BlobBaseFee and l1BlobBaseFeeScalar

See discussion here: ethereum-optimism/op-analytics#382

@MSilb7
Copy link
Author

MSilb7 commented May 9, 2024

Bumping this, there should be similar requirements across other stacks (i.e. Arb has gas used for l1).

Maybe there's an option to just pull all fields in the schema, versus having to pre-select?

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

No branches or pull requests

2 participants