-
Notifications
You must be signed in to change notification settings - Fork 72
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
Re-implement "Estimate gas for RRP fulfillments" #1817
Re-implement "Estimate gas for RRP fulfillments" #1817
Conversation
This reverts commit e8cc9ed.
b7adb2f
to
2b273b0
Compare
2b273b0
to
93bc917
Compare
@@ -62,7 +64,8 @@ export const chainTypeSchema = z.literal('evm'); | |||
|
|||
export const airnodeRrpContractSchema = z | |||
.object({ | |||
AirnodeRrp: evmAddressSchema, | |||
AirnodeRrp: evmAddressSchema.optional(), |
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.
Here is a clarification to make it clearer: Although AirnodeRrp shouldn't be optional, I have set both contracts to be optional in this case. The reason behind this decision is to accommodate situations where the user wants to use their own address for one of the contracts, while using default deployments for the other contract. In such cases, the user can define chains.contracts for the desired contract but leave it undefined for the contract they wish to use default deployments for.
Actually this schema is input schema (see here) and supposed to parse input config.json. Enforcing this schema with transforms below, inferred output type for this schema will be {AirnodeRrp: evmAddressSchema, AirnodeRrpDryRun: evmAddressSchema.optional()}
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.
Nice work and I have mostly minor comments. For the PR title, perhaps something like "Re-implement estimate gas for RRP fulfillments"?
I was hoping there was going to be a simple way to incorporate this into an E2E test, but I don't see one at the moment. The airnode-examples
E2E test might be a good candidate, but it would involve hardhat contract deployment similar to AirnodeRrp e.g. after this line.
Closes #1589
This PR basically:
Estimate gas for RRP fulfillments
which was reverted and reason had been nicely told in the Slack threadI think it'll be better to refer the provided Slack thread first. Btw I'm not sure about PR title created by GitHub when reverted the ancestor PR, let me know if it needs to be changed.
Sorry for force pushs, I would like to stick with @dcroote 's commit message protocol :-)