From 884882039c54fd301be09796c8bdd783f2c866e2 Mon Sep 17 00:00:00 2001 From: kelemeno <34402761+kelemeno@users.noreply.github.com> Date: Wed, 24 Apr 2024 09:32:06 +0100 Subject: [PATCH] fix: migration fix 3 ( enought to merge to main later) (#1771) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## What ❔ ## Why ❔ ## Checklist - [ ] PR title corresponds to the body of PR (we generate changelog entries from PRs). - [ ] Tests for the changes have been added / updated. - [ ] Documentation comments have been added / updated. - [ ] Code has been formatted via `zk fmt` and `zk lint`. - [ ] Spellcheck has been run via `zk spellcheck`. - [ ] Linkcheck has been run via `zk linkcheck`. --------- Signed-off-by: Danil Co-authored-by: Bence Haromi Co-authored-by: Jmunoz Co-authored-by: Lyova Potyomkin Co-authored-by: Stanislav Breadless Co-authored-by: Bence Haromi <56651250+benceharomi@users.noreply.github.com> Co-authored-by: Javier Chatruc Co-authored-by: Francisco Krause Arnim Co-authored-by: Javier Rodríguez Chatruc <49622509+jrchatruc@users.noreply.github.com> Co-authored-by: Francisco Krause Arnim <56402156+fkrause98@users.noreply.github.com> Co-authored-by: Santiago Pittella Co-authored-by: Danil Co-authored-by: Leandro Ferrigno Co-authored-by: Raid Ateir Co-authored-by: fborello-lambda Co-authored-by: mm Co-authored-by: Marcin M <128217157+mm-zk@users.noreply.github.com> Co-authored-by: perekopskiy <53865202+perekopskiy@users.noreply.github.com> Co-authored-by: Alex Ostrovski Co-authored-by: Raid5594 <52794079+Raid5594@users.noreply.github.com> --- contracts | 2 +- .../protocol-upgrade/src/hyperchain-upgrade.ts | 13 ++++++++++++- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/contracts b/contracts index 6e9af1a1835d..501691051a74 160000 --- a/contracts +++ b/contracts @@ -1 +1 @@ -Subproject commit 6e9af1a1835d871c57bff041bd0cd1a6992c1ec5 +Subproject commit 501691051a745bdb03922e57f263497a866701dd diff --git a/infrastructure/protocol-upgrade/src/hyperchain-upgrade.ts b/infrastructure/protocol-upgrade/src/hyperchain-upgrade.ts index 4d5cb98450a3..ce7d434d3af3 100644 --- a/infrastructure/protocol-upgrade/src/hyperchain-upgrade.ts +++ b/infrastructure/protocol-upgrade/src/hyperchain-upgrade.ts @@ -134,11 +134,22 @@ async function hyperchainFullUpgrade() { 'cp etc/env/.init.env etc/env/l1-inits/.init.env && rm ./etc/env/l2-inits/zksync_local.init.env && rm ./etc/env/target/zksync_local.env' ); await spawn('zk env zksync_local'); + env.reload('zksync_local'); env.modify( 'CONTRACTS_ERA_DIAMOND_PROXY_ADDR', process.env.CONTRACTS_DIAMOND_PROXY_ADDR, `etc/env/l1-inits/${process.env.L1_ENV_NAME ? process.env.L1_ENV_NAME : '.init'}.env` ); + env.modify( + 'CONTRACTS_L2_SHARED_BRIDGE_ADDR', + process.env.CONTRACTS_L2_ERC20_BRIDGE_ADDR, + `etc/env/l2-inits/${process.env.ZKSYNC_ENV}.init.env` + ); + env.modify( + 'CONTRACTS_BASE_TOKEN_ADDR', + '0x0000000000000000000000000000000000000001', + `etc/env/l2-inits/${process.env.ZKSYNC_ENV}.init.env` + ); await deploySharedBridgeL2Implementation(); @@ -170,7 +181,7 @@ async function hyperchainFullUpgrade() { async function postPropose() { // we need to set up the prover dal await setupForDal(DalPath.ProverDal, process.env.DATABASE_PROVER_URL); - await 'zk db migrate'; + await spawn('zk db migrate'); } export const command = new Command('hyperchain-upgrade').description('create and publish custom l2 upgrade');