-
Notifications
You must be signed in to change notification settings - Fork 160
ops: integrate op-fetcher #951
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
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #951 +/- ##
==========================================
- Coverage 43.64% 41.92% -1.73%
==========================================
Files 39 40 +1
Lines 2305 2674 +369
==========================================
+ Hits 1006 1121 +115
- Misses 1210 1450 +240
- Partials 89 103 +14 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
dbf4ebd
to
07de2d4
Compare
3b3658d
to
ec4c61f
Compare
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.
A few gaps before this is ready to merge. Specifically:
- Stuff that touches the disk should use an FS helper in
paths
- We should be scanning the disk once for all chain configs/superchains, then using in-memory data for further filtering operations. This is the architecture for other ops tools, and makes things much simpler
Overview
Integrates op-fetcher from the monorepo into this repo in order to pull chain config info on-demand from onchain instead of relying on static, hard-coded addresses in the chain config .toml files. This will help prevent data in the chain config .toml and codegen files from going stale and requiring manual updates. Instead, a daily ci job will run and open a pr to update the following codegen files if it notices any diffs between what is onchain and what is stored offchain in the registry:
addresses.json
chainList.json
chainList.toml
CHAINS.md
Details
The existing
ops/cmd/codegen
command has been modified to useop-fetcher
instead of pulling all of its information from hardcoded information in the chain config .toml files.In addition to contract and roles addresses,
op-fetcher
also outputs afaultProofsStatus
struct. This information is now stored in theChainListEntry
struct that compriseschainList.json
andchainList.toml
.Usage
--chain-ids
flag: this will be used when an individual chain is added or modified. This command will fail if none of the givenl1-rpc-urls
have the appropriate l1 chainId to query the l2(s) contracts.Related Issues
Follow-up Work
Remove all addresses from the individual chain config .toml files except the following ones. The full collection of addresses should be read from the more up-to-date
addresses.json
file, or read on-demand using op-fetcher.