Skip to content

[OpenRPC] Add arbtrace_ method definitions for Arbitrum One#1185

Open
JackReacher0807 wants to merge 3 commits intomainfrom
docs/openrpc/arbtrace-methods
Open

[OpenRPC] Add arbtrace_ method definitions for Arbitrum One#1185
JackReacher0807 wants to merge 3 commits intomainfrom
docs/openrpc/arbtrace-methods

Conversation

@JackReacher0807
Copy link
Copy Markdown
Collaborator

Summary

Adds OpenRPC method definitions for 8 arbtrace_ methods supported on Arbitrum One.

Methods added

  • arbtrace_block — Returns traces created at a given block
  • arbtrace_call — Traces the execution of eth_call within a specific block context
  • arbtrace_callMany — Executes multiple calls and returns traces for each
  • arbtrace_filter — Returns traces matching a given filter
  • arbtrace_get — Returns trace at a given position
  • arbtrace_replayBlockTransactions — Replays all transactions in a block returning requested traces
  • arbtrace_replayTransaction — Replays a transaction returning the requested traces
  • arbtrace_transaction — Returns all traces of a given transaction

Details

  • Location: src/openrpc/chains/_components/arbtrace/methods.yaml
  • Method definitions only — no chain spec references added (Daikon will handle that via a separate config PR)
  • Includes shared schemas: TraceObject, TraceAction, TraceResult, TraceCallResult, TransactionCallObject, TraceTypeArray, TraceFilterObject
  • These are Arbitrum-specific tracing methods for pre-Nitro blocks (before block 22,207,815)
  • Supported on Arbitrum One (ARB_MAINNET) only, NOT Arbitrum Nova
  • Blocked for FREE tier; requires PAYG or Enterprise

Validation

  • pnpm run generate:rpc — passed
  • pnpm run validate:rpc — passed

Linear: DOCS-32

Add 8 arbtrace_ method definitions as component schemas:
- arbtrace_block
- arbtrace_call
- arbtrace_callMany
- arbtrace_filter
- arbtrace_get
- arbtrace_replayBlockTransactions
- arbtrace_replayTransaction
- arbtrace_transaction

These are Arbitrum-specific tracing methods for pre-Nitro blocks
(before block 22,207,815). Includes shared schemas for TraceObject,
TraceAction, TraceResult, TraceCallResult, TransactionCallObject,
TraceTypeArray, and TraceFilterObject.

Method definitions only — chain spec references will be added via
Daikon's automated workflow in a separate config PR.
@JackReacher0807 JackReacher0807 requested a review from a team as a code owner April 7, 2026 18:53
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 7, 2026

🔗 Preview Mode

Name Status Preview Updated (UTC)
Alchemy Docs ✅ Ready 🔗 Visit Preview Apr 7, 2026, 8:07 PM

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 7, 2026

🔍 Link Check

Status: ⏭️ Skipped (no content changes)

View workflow run

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 808a12994e

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines +334 to +335
items: false
prefixItems:
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Use draft-07 tuple schema for arbtrace_callMany

arbtrace_callMany models each call pair with items: false and prefixItems, but OpenRPC 1.2 schema objects follow JSON Schema draft-07 where prefixItems is not a tuple keyword. In draft-07 terms this leaves items: false active while minItems: 2 is also required, making every inner call tuple unsatisfiable and causing real requests to fail schema-driven validation/generation. Please encode this tuple with draft-07 keywords (e.g., items as a 2-element schema array plus additionalItems: false).

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch — prefixItems is indeed a JSON Schema 2020-12 keyword, not available in draft-07 which OpenRPC 1.2 uses. Fixed in 1e2235f: replaced items: false + prefixItems with a draft-07 tuple using items as a 2-element schema array plus additionalItems: false. Validation and generation both pass.

Comment on lines +25 to +26
$ref: "../evm/base-types.yaml#/components/schemas/address"
description: The address of the receiver. Null for contract creation.
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Allow null to for contract-creation trace actions

TraceAction.to is constrained to the non-null address schema, but its own description states this field is null for contract creation. Because this shared schema is used by all arbtrace methods, valid create traces will be rejected (and client types will be wrong) whenever to is returned as null.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Valid point — TraceAction.to is null for contract creation traces, so constraining it to a non-null address schema would reject valid responses. Fixed in 1e2235f: changed the to property to use oneOf: [address, null] so both regular calls and contract-creation traces validate correctly.

- arbtrace_callMany: Replace prefixItems (2020-12) with items array +
  additionalItems: false for draft-07 compatibility
- TraceAction.to: Use oneOf with address | null to allow null for
  contract-creation traces
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

Successfully merging this pull request may close these issues.

1 participant