-
Notifications
You must be signed in to change notification settings - Fork 265
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
refactor: dedupe CallRequest
/TransactionRequest
#178
Conversation
@DaniPopes where do I note breaking changes for the checklist? |
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.
I'm for unifying them, not worth having duplicate versions of the same thing. especially if we want to use this type as the foundation for building transactions.
before we merge this here, I'd like companion prs on foundry and reth so we can merge them in one go.
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.
This is fine w/ me. I'll take care of the foundry companion PR
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.
last nit
gm @onbjerg can this be merged? |
289128b
to
0964673
Compare
Motivation
CallRequest
andTransactionRequest
are basically the same type, with very few differences:TransactionRequest
was missing an optional chain IDTransactionRequest
was missingmax_fee_per_blob_gas
CallRequest
andTransactionRequest
had different blob fieldsSince they also serve the same purpose, this PR dedupes them, to make sure there is only one tx request type, which is important for the network abstraction.
Solution
Dedupe them, porting over fields missing from either.
I removed the blob transaction sidecar, but only because I didn't really know if it is actually a part of the spec. As far as I could tell, only
blob_versioned_hashes
and the gas field is. I asked @mattsse for direction in case he knew, but ultimately we didn't land on anything.This is a breaking change for obvious reasons, and it not simply a "import new type" migration path, as I also ported over
CallInput
forTransactionRequest
PR Checklist