|
1 | 1 | # Nitro contracts 1.2.1 upgrade
|
2 | 2 | These scripts empower `NitroContracts2Point0Point0UpgradeAction` action contract which performs upgrade to [2.0.0 release](https://github.com/OffchainLabs/nitro-contracts/releases/tag/v2.0.0) of Nitro contracts for existing Orbit chains. Predeployed instances of the upgrade action exists on the chains listed in the following section with vanilla ArbOS31 wasm module root set. If you have a custom nitro machine, you will need to deploy the upgrade action yourself.
|
3 | 3 |
|
4 |
| -NitroContracts1Point2Point1UpgradeAction will perform the following action: |
5 |
| -1. Upgrade SequencerInbox to v1.2.1 |
6 |
| -2. Upgrade ChallengeManager to v1.2.1 |
7 |
| -3. Upgrade OneStepProof to v1.2.1 |
8 |
| -4. Set the wasm module root to the new version |
| 4 | +NitroContracts2Point0Point0UpgradeAction will perform the following action: |
| 5 | +1. Upgrade ChallengeManager to v2.0.0 |
| 6 | +2. Set the wasm module root to the new version |
| 7 | +3. Set the conditional wasm root and one step proof |
9 | 8 |
|
10 |
| -Note that contracts without code changes are not upgraded. It is normal to have some contracts still in the old version after the upgrade as they are equivalent to the new version. After the contract upgrade, you would need to schedule an ArbOS upgrade to ArbOS20 to enable the new features. |
| 9 | +Note that contracts without code changes are not upgraded. It is normal to have some contracts still in the old version after the upgrade as they are equivalent to the new version. After the contract upgrade, you would need to schedule an ArbOS upgrade to ArbOS31 to enable the new features. |
11 | 10 |
|
12 | 11 | ## Requirements
|
13 | 12 | This upgrade only support upgrading from the following [nitro-contract release](https://github.com/OffchainLabs/nitro-contracts/releases):
|
14 | 13 | - Inbox: v1.1.0 - v1.2.1 inclusive
|
15 | 14 | - Outbox: v1.1.0 - v1.2.1 inclusive
|
16 |
| -- SequencerInbox: v1.1.0 or v1.1.1 |
| 15 | +- SequencerInbox: v1.2.1 |
17 | 16 | - Bridge: v1.1.0 - v1.2.1 inclusive
|
18 | 17 | - RollupProxy: v1.1.0 - v1.2.1 inclusive
|
19 | 18 | - RollupAdminLogic: v1.1.0 - v1.2.1 inclusive
|
20 | 19 | - RollupUserLogic: v1.1.0 - v1.2.1 inclusive
|
21 |
| -- ChallengeManager: v1.1.0 - v1.2.1 inclusive |
| 20 | +- ChallengeManager: v1.2.1 |
22 | 21 |
|
23 |
| -Please refers to the top [README](../../README.md) `Check Version and Upgrade Path` on how to determine your current nitro contracts version. |
| 22 | +Please refer to the top [README](../../README.md) `Check Version and Upgrade Path` on how to determine your current nitro contracts version. |
24 | 23 |
|
25 | 24 | ## Deployed instances
|
26 | 25 |
|
27 |
| -- L1 mainnet (eth fee token): 0xC159A3a21aFb34Dbc601a7A42aCD2eCa019393F7 |
28 |
| -- L1 mainnet (custom fee token): 0x2e0c12e2478a0dEc2EF6C2CCC2ED8d4fEd3597d1 |
29 |
| -- L2 Arb1 (eth fee token): 0x606Bb75B1f910F82086557aa14eD2Dc0bEB85D6B |
30 |
| -- L2 Arb1 (custom fee token): 0xb28c89b6997F025BD35205b99a7968C264cCe353 |
31 |
| -- L1 Sepolia (eth fee token): 0xBC1e0ca800781F58F3a2f73dA4D895FdD61B0Cb5 |
32 |
| -- L1 Sepolia (custom fee token): 0xEFf65644557573e3E781B0B586fD7488a26c8E46 |
33 |
| -- L2 ArbSepolia (eth fee token): 0xe9F95d0975e87e8E633fceCDF17fFc0f646cCfb8 |
34 |
| -- L2 ArbSepolia (custom fee token): 0x86AdeeAcF16fdbCAEe615b12E56e064a665fCF47 |
| 26 | +TBD |
35 | 27 |
|
36 | 28 | ## How to use it
|
37 | 29 |
|
38 |
| -1. Setup .env according to the example files, make sure you have everything correctly defined. The script do some sanity checks but not everything can be checked. |
| 30 | +1. Setup .env according to the example files, make sure you have everything correctly defined. The script will do some sanity checks but not everything can be checked. |
39 | 31 |
|
40 | 32 | 2. (Skip this step if you can use the deployed instances of action contract)
|
41 |
| -`DeployNitroContracts1Point2Point1UpgradeAction.s.sol` script deploys OSPs and ChallengeManager templates, blob reader and SequencerInbox template, and finally the upgrade action itself. It can be executed in this directory like this: |
| 33 | +`DeployNitroContracts2Point0Point0UpgradeActionScript.s.sol` script deploys OSPs and ChallengeManager templates, and upgrade action itself. It can be executed in this directory like this: |
42 | 34 | ```bash
|
43 |
| -forge script --sender $DEPLOYER --rpc-url $PARENT_CHAIN_RPC --broadcast --slow ./DeployNitroContracts1Point2Point1UpgradeAction.s.sol -vvv --verify --skip-simulation |
| 35 | +forge script --sender $DEPLOYER --rpc-url $PARENT_CHAIN_RPC --broadcast --slow ./DeployNitroContracts2Point0Point0UpgradeAction.s.sol -vvv --verify --skip-simulation |
44 | 36 | # use --account XXX / --private-key XXX / --interactive / --ledger to set the account to send the transaction from
|
45 | 37 | ```
|
46 | 38 | As a result, all templates and upgrade action are deployed. Note the last deployed address - that's the upgrade action.
|
47 | 39 |
|
48 |
| -3. `ExecuteNitroContracts1Point2Point1Upgrade.s.sol` script uses previously deployed upgrade action to execute the upgrade. It makes following assumptions - L1UpgradeExecutor is the rollup owner, and there is an EOA which has executor rights on the L1UpgradeExecutor. Proceed with upgrade using the owner account (the one with executor rights on L1UpgradeExecutor): |
| 40 | +3. `ExecuteNitroContracts2Point0Point0Upgrade.s.sol` script uses previously deployed upgrade action to execute the upgrade. It makes following assumptions - L1UpgradeExecutor is the rollup owner, and there is an EOA which has executor rights on the L1UpgradeExecutor. Proceed with upgrade using the owner account (the one with executor rights on L1UpgradeExecutor): |
49 | 41 | ```bash
|
50 |
| -forge script --sender $EXECUTOR --rpc-url $PARENT_CHAIN_RPC --broadcast ./ExecuteNitroContracts1Point2Point1Upgrade.s.sol -vvv |
| 42 | +forge script --sender $EXECUTOR --rpc-url $PARENT_CHAIN_RPC --broadcast ./ExecuteNitroContracts2Point0Point0Upgrade.s.sol -vvv |
51 | 43 | # use --account XXX / --private-key XXX / --interactive / --ledger to set the account to send the transaction from
|
52 | 44 | ```
|
53 | 45 | If you have a multisig as executor, you can still run the above command without broadcasting to get the payload for the multisig transaction.
|
|
0 commit comments