-
Notifications
You must be signed in to change notification settings - Fork 301
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
fix: use simulation to estimate gas used #11211
Open
spypsy
wants to merge
63
commits into
master
Choose a base branch
from
spy/simulate-l1-txs
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+621
−236
Open
Changes from all commits
Commits
Show all changes
63 commits
Select commit
Hold shift + click to select a range
e99a59a
fix: use simulation to estimate gas used
spypsy 5c61192
Merge branch 'master' into spy/simulate-l1-txs
spypsy e4a3640
undo sequencer version bump
spypsy 94be510
upgrade viem in sequencer-client
spypsy caf932c
upgrade all viem
spypsy e3bc173
fix more typings
spypsy 2ed14da
restore block validation
spypsy 950d9ca
remove typo 😬
spypsy 05cd25e
handle node not supporting simulation
spypsy 499bb74
rm unused import
spypsy 2df6ccc
Merge branch 'master' into spy/simulate-l1-txs
spypsy 9a08a1c
Merge branch 'master' into spy/simulate-l1-txs
spypsy 98817bc
Merge branch 'master' into spy/simulate-l1-txs
spypsy aa9cb12
fix archiver tests
spypsy 8e966be
bump simulated gas as well
spypsy 13b3d89
add logging to simulation
spypsy 111a640
fix log
spypsy 77968f5
add logging, significantly bump evaluated gas
spypsy b5b85e1
use same timestamp with validateHeader & check simulation status
spypsy aac8611
temp fix test
spypsy 6a27978
log blob inputs
spypsy 506e398
better logging
spypsy 6a80190
override checkBlobs to false
spypsy dc8198a
add 1s to block time
spypsy 8061b88
Merge branch 'master' into spy/simulate-l1-txs
spypsy d5d5928
improve custom error logging
spypsy 5fd817b
Merge branch 'master' into spy/simulate-l1-txs
spypsy 644d00c
bump %, return entire error from viem
spypsy 040cc63
fix archiver test
spypsy de58c69
fix publisher integration test
spypsy 6b52112
fix testing errors
spypsy b62289b
update error tests
spypsy f901649
update publisher test
spypsy 019acd3
try fixing for reth
spypsy 8d6cdba
try adding gas to call
spypsy f42dbca
fix bad multiplication
spypsy 0f03c60
add nonce
spypsy 0db5e75
more logging fixes
spypsy 38fba15
Update yarn-project/archiver/src/archiver/archiver.test.ts
spypsy 8a76d0e
Update yarn-project/prover-node/src/bond/factory.ts
spypsy ab06ba7
Update yarn-project/sequencer-client/src/publisher/l1-publisher.ts
spypsy 763cab6
don't bump gasLimit option by default
spypsy d51c699
ErrorsAbi
spypsy a50e728
throw error on simulation instead of -1n
spypsy b8bcf63
Merge branch 'master' into spy/simulate-l1-txs
spypsy b694bfc
some more log clarifications for L1
spypsy 4bd5f1f
handle regular ol' errors
spypsy abb34ff
update test
spypsy 33b6e40
fix waitForEthereum
spypsy 5f782c8
add gasLimit to blockOverride (thx reth)
spypsy 30f8648
remove .only
spypsy 5a9177e
fix sepolia values yaml & tf
spypsy 730d120
just ethereum.externalHost
spypsy acba1b0
update 48 vals yaml too
spypsy 4be77a0
Merge branch 'master' into spy/simulate-l1-txs
spypsy ab9ce34
nuke validateHeader
spypsy d50ba48
fix imports
spypsy d432d46
Revert "nuke validateHeader"
spypsy 63fd6e9
re-instate imports
spypsy 7e9c3ce
formatting
spypsy cf85a88
Merge branch 'master' into spy/simulate-l1-txs
spypsy 4c9ffc2
add logging to timed out tx, reduce bot tx interval
spypsy 7e07713
tweak gas config
spypsy File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -528,17 +528,19 @@ describe('L1Publisher integration', () => { | |
await expect(publisher.proposeL2Block(block)).resolves.toEqual(false); | ||
|
||
// Test for both calls | ||
expect(loggerErrorSpy).toHaveBeenCalledTimes(2); | ||
// NOTE: First error is from the simulate fn, which isn't supported by anvil | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The simulate with There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yep |
||
expect(loggerErrorSpy).toHaveBeenCalledTimes(3); | ||
|
||
// Test first call | ||
expect(loggerErrorSpy).toHaveBeenNthCalledWith( | ||
1, | ||
2, | ||
expect.stringMatching(/^L1 transaction 0x[a-f0-9]{64} reverted$/i), | ||
expect.anything(), | ||
); | ||
|
||
// Test second call | ||
expect(loggerErrorSpy).toHaveBeenNthCalledWith( | ||
2, | ||
3, | ||
expect.stringMatching( | ||
/^Rollup process tx reverted\. The contract function "propose" reverted\. Error: Rollup__InvalidInHash/i, | ||
), | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Curious why we have two different env vars