diff --git a/scripts/ethcommands.ts b/scripts/ethcommands.ts index bf54d384..d042532a 100644 --- a/scripts/ethcommands.ts +++ b/scripts/ethcommands.ts @@ -411,8 +411,8 @@ export const createERC20Command = { .toString() ); - const l1GatewayRouter = new ethers.Contract(l1l2tokenbridge.l2Network.tokenBridge.l1GatewayRouter, L1GatewayRouter.abi, deployerWallet); - await (await token.functions.approve(l1l2tokenbridge.l2Network.tokenBridge.l1ERC20Gateway, ethers.constants.MaxUint256)).wait(); + const l1GatewayRouter = new ethers.Contract(l1l2tokenbridge.l2Network.tokenBridge.parentGatewayRouter, L1GatewayRouter.abi, deployerWallet); + await (await token.functions.approve(l1l2tokenbridge.l2Network.tokenBridge.parentErc20Gateway, ethers.constants.MaxUint256)).wait(); const supply = await token.totalSupply(); // transfer 90% of supply to l2 const transferAmount = supply.mul(9).div(10); diff --git a/test-node.bash b/test-node.bash index 88274640..4aa8aa74 100755 --- a/test-node.bash +++ b/test-node.bash @@ -9,7 +9,7 @@ BLOCKSCOUT_VERSION=offchainlabs/blockscout:v1.1.0-0e716c8 # 1. authorizing validator signer key since validator wallet is buggy # - gas estimation sent from 0x0000 lead to balance and permission error DEFAULT_NITRO_CONTRACTS_VERSION="v3.1.0" -DEFAULT_TOKEN_BRIDGE_VERSION="v1.2.2" +DEFAULT_TOKEN_BRIDGE_VERSION="v1.2.5" # Set default versions if not overriden by provided env vars : ${NITRO_CONTRACTS_BRANCH:=$DEFAULT_NITRO_CONTRACTS_VERSION} @@ -645,7 +645,7 @@ if $force_init; then if $tokenbridge; then # we deployed an L1 L2 token bridge # we need to pull out the L2 WETH address and pass it as an override to the L2 L3 token bridge deployment - l2Weth=`docker compose run --entrypoint sh tokenbridge -c "cat l1l2_network.json" | jq -r '.l2Network.tokenBridge.l2Weth'` + l2Weth=`docker compose run --entrypoint sh tokenbridge -c "cat l1l2_network.json" | jq -r '.l2Network.tokenBridge.childWeth'` fi docker compose run -e PARENT_WETH_OVERRIDE=$l2Weth -e ROLLUP_OWNER_KEY=$l3ownerkey -e ROLLUP_ADDRESS=$rollupAddress -e PARENT_RPC=http://sequencer:8547 -e PARENT_KEY=$deployer_key -e CHILD_RPC=http://l3node:3347 -e CHILD_KEY=$deployer_key tokenbridge deploy:local:token-bridge docker compose run --entrypoint sh tokenbridge -c "cat network.json && cp network.json l2l3_network.json"