-
Notifications
You must be signed in to change notification settings - Fork 195
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
feat(entropy): Entropy inspection #1588
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 2 Ignored Deployments
|
apps/fortuna/src/command/inspect.rs
Outdated
Some(ethers::contract::MULTICALL_ADDRESS), | ||
) | ||
.await?; | ||
let batch_size = 100; |
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.
suggest putting this in InspectOptions with a default value, just in case it needs to be changed later.
@@ -66,6 +68,9 @@ pub enum Options { | |||
/// Request a random number from the contract. | |||
RequestRandomness(RequestRandomnessOptions), | |||
|
|||
/// Inspect recent requests and find unfulfilled requests with callback. | |||
Inspect(InspectOptions), |
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.
question about this: how do I tell that the request didn't get a callback from the result? It seems like the output simply prints out all of the requests that have happened.
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.
any request still stored in the contract is not fulfilled yet. We just iterate through the requests and find the ones where the callback flag is also true and print them out.
@@ -622,6 +633,52 @@ export class EvmEntropyContract extends Storable { | |||
}; | |||
} | |||
|
|||
async getRequest( |
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.
nit: a 1 sentence doc comment on these methods would be nice. (esp for getUserRandomNumber, would be nice to explain how to get the block
argument if you don't have it)
No description provided.