feat: align frame rpc definitions - #476
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
commit: |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 85aeba5d0f
ℹ️ About Codex in GitHub
Your team has set up Codex to 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 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| @@ -0,0 +1,5 @@ | |||
| --- | |||
| "ox": patch | |||
There was a problem hiding this comment.
Publish the RPC migration as a major change
This commit removes or changes several public RPC fields and types—such as executionGasLimit, numeric frame modes, and the previous FrameReceipt shape—yet the changeset declares only a patch release. Consumers accepting a patch update can therefore encounter compile failures or incompatible RPC payloads; mark this as a major change and include the required before/after migration shape.
AGENTS.md reference: AGENTS.md:L121-L124
Useful? React with 👍 / 👎.
| data: Hex.Hex | ||
| /** Execution gas budget. */ | ||
| executionGasLimit: Hex.Hex | ||
| executionGas: Hex.Hex |
There was a problem hiding this comment.
Update the guide for the renamed RPC frame fields
After this rename, site/src/pages/guides/transactions/eip-8141.mdx:120-124 still says toRpc emits executionGasLimit/stateGasLimit and that modes, flags, and signature schemes are numbers. Users following that handwritten guide will construct the obsolete payload shape that the updated codecs reject, so update the paragraph alongside these RPC changes.
Useful? React with 👍 / 👎.
| 'chainId' | 'gas' | 'input' | 'to' | 'value' | 'r' | 's' | 'v' | 'yParity' | ||
| > & | ||
| ExactPartial< | ||
| Pick< | ||
| Base<type, pending, bigintType, numberType>, | ||
| 'gas' | 'input' | 'to' | 'value' |
There was a problem hiding this comment.
Preserve omitted EIP-8141 aggregate fields in codecs
When an EIP-8141 RPC response omits the newly optional gas or value fields, Transaction.fromRpc still unconditionally materializes them as 0n, and Transaction.toRpc then emits gas: '0x0' and value: '0x0'; input and to are similarly assigned explicitly rather than preserved as absent. This loses the distinction introduced by making these fields optional and makes a response that legitimately omits aggregate transaction fields fail to round-trip, so the conversion paths should special-case EIP-8141 and only map fields that are present.
Useful? React with 👍 / 👎.
| Pick<Log.Rpc, 'address' | 'data' | 'topics'> & | ||
| ExactPartial<Omit<Log.Rpc, 'address' | 'data' | 'topics'>> |
There was a problem hiding this comment.
Decode the newly exposed frame-log quantities
When a frame log includes the metadata newly admitted here, FrameReceipt.fromRpc copies receipt.logs unchanged, so blockNumber, logIndex, and transactionIndex remain hex strings; the decoded Zod schema likewise uses quantityHex() for them. Consequently TransactionReceipt.fromRpc produces bigint/number fields in its ordinary logs array but RPC-shaped strings for the same fields under frameReceipts[].logs, making numeric consumers behave inconsistently. Use a decoded frame-log shape and convert each present metadata quantity in both directions.
Useful? React with 👍 / 👎.
Align frame RPC quantities, signature placeholders, receipts, and Zod schemas with ethereum/execution-apis#907. Run frame tests against Reth.
Equivalent to #475 for
main.