-
Notifications
You must be signed in to change notification settings - Fork 33
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
Adopt transparent upgradeability pattern #864
Merged
Merged
Conversation
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
okkothejawa
changed the title
Adopt transparent upgradeability pattern
WIP Adopt transparent upgradeability pattern
Jul 9, 2024
okkothejawa
changed the title
WIP Adopt transparent upgradeability pattern
Adopt transparent upgradeability pattern
Jul 10, 2024
eyusufatik
requested changes
Jul 10, 2024
crates/evm/src/evm/system_contracts/script/GenesisGenerator.s.sol
Outdated
Show resolved
Hide resolved
eyusufatik
approved these changes
Jul 10, 2024
I believe it's not flaky. |
eyusufatik
requested changes
Jul 10, 2024
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.
see my above comment
eyusufatik
approved these changes
Jul 11, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
UUPSUpgradeable
contract which needs to be inherited in all implementation contracts have animmutable
variable which makes our pre-deployment scheme inconvenient. Instead, we adopt transparent proxies like other rollups such as Optimism and Scroll which doesn't have this issue.GenesisGenerator.s.sol
andGenesisToEvmJson.py
. The former is a Foundry script that sets the genesis state directly through Solidity testing environment, and this approach has significant advantages over the old method of manually setting genesis files as it is less error-prone and more intuitive to set. The latter takes the generated genesis data and appends it with extra information and formats it to be compatible with our existingevm.json
format.make genesis
to trigger the scripts above. This command should be run after all changes to the system contracts and any genesis change.BitcoinLightClient
with an obviously false implementation that returns0xdeaddeaddeaddeaddeaddeaddeaddeaddeaddeaddeaddeaddeaddeaddeaddead
for any queried block hash. As this is not possible for any actual block, successful confirmation of this shows that the behavior is updated.Linked Issues
Testing
Existing tests were adapted.
Docs