Skip to content
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

Index rollups creations #6

Merged
merged 9 commits into from
Jan 8, 2024
Merged

Conversation

catalyst17
Copy link
Collaborator

@catalyst17 catalyst17 commented Jan 4, 2024

Detects Arbitrum Nitro rollups in a pretty simple manner by looking only at the transactions which have CreateRollup signature.

For OP stack everything is way more complicated, but in short:

  • for 9 logic contracts (AddressManager, ProxyAdmin, OptimismPortal, L1CrossDomainMessenger, L2OutputOracle, OptimismMintableERC20Factory, SystemConfig, L1StandardBridge, L1ERC721Bridge) it checks for the new contract deployed with the specific hash of a code_change
  • for 7 proxy contracts (corresponding to all the ones above, except AddressManager, ProxyAdmin) it looks for the transactions which have Upgrade or UpgradeAndCall call signatures in the ProxyAdmin contract and the checks the function arguments against already saved implementation addresses

This approach has ways to improve, starting with using Substreams store modules in order to make sure we are correctly enriching one rollup entity instead of creating a new one, because it's pretty much possible that the implementation contracts deployment and proxy settings might happen in different blocks. For now our substreams have no inter-block state management.

Copy link

linear bot commented Jan 4, 2024

@catalyst17 catalyst17 merged commit 831f361 into main Jan 8, 2024
1 check passed
@catalyst17 catalyst17 deleted the block-1368-index-rollups-creations branch January 8, 2024 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants