-
Notifications
You must be signed in to change notification settings - Fork 1
feat: passes sim result to the submit tasks #100
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
Conversation
This stack of pull requests is managed by Graphite. Learn more about stacking. |
4961bf7 to
df3f9a2
Compare
f5c2178 to
a873d45
Compare
95a207e to
9a95da4
Compare
a873d45 to
1fc9892
Compare
9a95da4 to
c2cd1ab
Compare
75b8d71 to
41019b6
Compare
acf2569 to
2234717
Compare
501d86e to
92b1dde
Compare
2c09604 to
a96a88f
Compare
92b1dde to
b69451e
Compare
a96a88f to
aee1dd3
Compare
b69451e to
0f48d3e
Compare
aee1dd3 to
da4a7fd
Compare
3432017 to
6fd3675
Compare
src/tasks/env.rs
Outdated
| /// The signet block environment, for rollup block simulation. | ||
| pub signet: BlockEnv, | ||
| /// The host environment header, for host transaction submission pricing. | ||
| pub host: Header, |
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 isn't used by the simulation process, right? It's only used during blob submission to host. So instead of retrieving it here, why not have the blob submission task retrieve it?
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.
My thinking was that it was a part of the environment, so it made sense to have the EnvTask handle it and update its object, but I can update it to only fetch the Header in the SubmitTask instead.
prestwich
left a comment
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.
NACK on passing the header through the stack, header should be retrieved at the place it's needed
44bc5cd to
8dad7d2
Compare
- adds a SimResult type that binds a BlockEnv to a BuiltBlock - passess that SimResult to the SubmitTask for gas calculations
8dad7d2 to
9f5eaef
Compare
prestwich
left a comment
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.
looks like we're now passing an RU header through instead of host, which is not strictly necessary but seems fine
| debug!(?tx.nonce, "sending transaction with nonce"); | ||
| let result = provider.send_transaction(tx).await.unwrap(); | ||
|
|
||
| // wait for the transaction to mine |
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.
isn't this what the metrics task is for? when did we move this out of the metrics task?
| blockDataHash: *block.contents_hash(), | ||
| }; | ||
| debug!(?header, "built block header"); | ||
| debug!(?header.hostBlockNumber, "built rollup block header"); |
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.
logging host block number but message says rollup block header?

feat: Passes SimResult to the submit task
This PR adds a
SimResulttype that wraps aBuiltBlockand aBlockEnvtogether and sends them both to theSubmitTaskso that a block's environment is known at submission time for gas calculation purposes.SimResulttype that binds aBlockEnvto aBuiltBlockSimResultto theSubmitTaskfor gas calculation purposesBugfixes
Closes ENG-1046