-
Notifications
You must be signed in to change notification settings - Fork 103
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
responseListener.listenForResponseFromTransaction #190
Conversation
tasks/Functions-consumer/request.js
Outdated
spinner.start( | ||
`Request ${requestId} has been initiated. Waiting for fulfillment from the Decentralized Oracle Network...\n` | ||
`Request ${requestTxReceipt.events[2].args.id} has been initiated. Waiting for fulfillment from the Decentralized Oracle Network...\n` |
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 changed other examples to print a transaction hash here and the request ID only after fulfillment. Maybe do the same here?
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.
Is there informational value in having both? something along the lines of:
RequestId ${reqId} is waiting for fulfillment from the Decentralized Oracle Network. Track this fulfillment by its Tx hash ${txHash}.
networks.js
Outdated
@@ -101,7 +101,7 @@ const networks = { | |||
accounts, | |||
verifyApiKey: process.env.POLYGONSCAN_API_KEY || "UNSET", | |||
chainId: 80001, | |||
confirmations: DEFAULT_VERIFICATION_BLOCK_CONFIRMATIONS, | |||
confirmations: DEFAULT_VERIFICATION_BLOCK_CONFIRMATIONS * 4, |
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.
That looks a little weird. Does it actually hurt to keep it at DEFAULT?
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.
do we want to have network specific defaults?
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'll just set this to 10 blocks. I've noticed that it can be a problem if we don't wait long enough before verifying contracts.
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.
10 blocks on Sepolia is 2 minutes, way too slow IMO
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.
LGTM
networks.js
Outdated
@@ -101,7 +101,7 @@ const networks = { | |||
accounts, | |||
verifyApiKey: process.env.POLYGONSCAN_API_KEY || "UNSET", | |||
chainId: 80001, | |||
confirmations: DEFAULT_VERIFICATION_BLOCK_CONFIRMATIONS, | |||
confirmations: DEFAULT_VERIFICATION_BLOCK_CONFIRMATIONS * 4, |
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.
do we want to have network specific defaults?
tasks/Functions-consumer/request.js
Outdated
spinner.start( | ||
`Request ${requestId} has been initiated. Waiting for fulfillment from the Decentralized Oracle Network...\n` | ||
`Request ${requestTxReceipt.events[2].args.id} has been initiated. Waiting for fulfillment from the Decentralized Oracle Network...\n` |
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.
Is there informational value in having both? something along the lines of:
RequestId ${reqId} is waiting for fulfillment from the Decentralized Oracle Network. Track this fulfillment by its Tx hash ${txHash}.
Use new
responseListener.listenForResponseFromTransaction
method from the latest Functions Toolkit release