-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
fix: ethrpc: Add missing fields to EthTx #10223
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,7 +37,8 @@ type EthTx struct { | |
Gas EthUint64 `json:"gas"` | ||
MaxFeePerGas EthBigInt `json:"maxFeePerGas"` | ||
MaxPriorityFeePerGas EthBigInt `json:"maxPriorityFeePerGas"` | ||
V EthBigInt `json:"v"` | ||
AccessList []EthHash `json:"accessList"` | ||
V EthBigInt `json:"yParity"` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Afaict what we put here is in fact YParity according to https://github.com/ethereum/EIPs/blob/master/EIPS/eip-2098.md; V is only used for legacy transactions This value seems to be set to 0/1; not 27/28 which are V values Not sure if it makes sense to rename the V field to There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd prefer to rename it to YParity to keep them consistent. |
||
R EthBigInt `json:"r"` | ||
S EthBigInt `json:"s"` | ||
} | ||
|
@@ -86,6 +87,7 @@ func EthTxFromSignedEthMessage(smsg *types.SignedMessage) (EthTx, error) { | |
Gas: EthUint64(txArgs.GasLimit), | ||
MaxFeePerGas: EthBigInt(txArgs.MaxFeePerGas), | ||
MaxPriorityFeePerGas: EthBigInt(txArgs.MaxPriorityFeePerGas), | ||
AccessList: []EthHash{}, | ||
V: v, | ||
R: r, | ||
S: s, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Those come from https://eips.ethereum.org/EIPS/eip-2930, which I don't think are supported in FEVM
Given that those aren't possible to specify (?), and optional, I just add the field and keep it empty, which is enough to keep openrpc happy.