Skip to content

Commit

Permalink
Update protocol contracts repo to deploy mainnet
Browse files Browse the repository at this point in the history
  • Loading branch information
andresaiello committed Sep 27, 2023
1 parent b2ae423 commit afbab03
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 12 deletions.
8 changes: 8 additions & 0 deletions data/addresses.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,14 @@
"zetaToken": "",
"zetaTokenConsumerUniV2": "",
"zetaTokenConsumerUniV3": ""
},
"ethereum_mainnet": {
"connector": "",
"erc20Custody": "",
"immutableCreate2Factory": "0x095a03c6a68137fE9a566bBc3e552F299d8b886d",
"tss": "",
"tssUpdater": "",
"zetaToken": ""
}
},
"non_zeta": {
Expand Down
14 changes: 7 additions & 7 deletions lib/contracts.helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import { BaseContract, ContractFactory } from "ethers";
import { ethers } from "hardhat";

export const isEthNetworkName = (networkName: string) =>
networkName === "eth-localnet" || networkName === "goerli" || networkName === "eth-mainnet";
networkName === "eth-localnet" || networkName === "goerli_testnet" || networkName === "ethereum_mainnet";

export const deployZetaConnectorBase = async ({ args }: { args: Parameters<ZetaConnectorBaseFactory["deploy"]> }) => {
const Factory = (await ethers.getContractFactory("ZetaConnectorBase")) as ZetaConnectorBaseFactory;
Expand Down Expand Up @@ -144,13 +144,13 @@ export const getZetaTokenConsumerUniV3Strategy = async (params: GetContractParam

export type GetContractParams<Factory extends ContractFactory> =
| {
deployParams: Parameters<Factory["deploy"]>;
existingContractAddress?: null;
}
deployParams: Parameters<Factory["deploy"]>;

Check failure on line 147 in lib/contracts.helpers.ts

View workflow job for this annotation

GitHub Actions / build

Insert `··`
existingContractAddress?: null;

Check failure on line 148 in lib/contracts.helpers.ts

View workflow job for this annotation

GitHub Actions / build

Insert `··`
}

Check failure on line 149 in lib/contracts.helpers.ts

View workflow job for this annotation

GitHub Actions / build

Insert `··`
| {
deployParams?: null;
existingContractAddress: string;
};
deployParams?: null;

Check failure on line 151 in lib/contracts.helpers.ts

View workflow job for this annotation

GitHub Actions / build

Insert `··`
existingContractAddress: string;

Check failure on line 152 in lib/contracts.helpers.ts

View workflow job for this annotation

GitHub Actions / build

Insert `··`
};

Check failure on line 153 in lib/contracts.helpers.ts

View workflow job for this annotation

GitHub Actions / build

Insert `··`

export const getContract = async <Factory extends ContractFactory, Contract extends BaseContract>({
contractName,
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"@uniswap/v2-periphery": "^1.1.0-beta.0",
"@uniswap/v3-periphery": "^1.4.3",
"@zetachain/addresses": "^0.0.9",
"@zetachain/networks": "^0.0.1",
"@zetachain/networks": "^2.4.2",
"chai": "^4.3.6",
"cpx": "^1.5.0",
"del-cli": "^5.0.0",
Expand Down
15 changes: 11 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2081,10 +2081,12 @@
resolved "https://registry.yarnpkg.com/@zetachain/addresses/-/addresses-0.0.9.tgz#d8ad93242590c0a6d028be8f515ad9f84fd588c2"
integrity sha512-MA/kD8a2NY5xJMFjwPj1oph6P3O7l0g23QB3QTgcBs4DdmwubvTVH6S6/e8CWzLFojTP5qBiqIWBsU0iHP/HFg==

"@zetachain/networks@^0.0.1":
version "0.0.1"
resolved "https://registry.yarnpkg.com/@zetachain/networks/-/networks-0.0.1.tgz#825b27cfb96cd156c079503de4253c8adf580275"
integrity sha512-p646aIgX/3IHkauZlOZBKirRCMY+hyo3Og3IfJGC3tNkqjADt0wrcnizJrRIlXWVJGnlAW7tJPyXPzcfBh2Bwg==
"@zetachain/networks@^2.4.2":
version "2.4.2"
resolved "https://registry.yarnpkg.com/@zetachain/networks/-/networks-2.4.2.tgz#611986d2a7cfd45505c2f61cdbc403aeeff14812"
integrity sha512-Md2SbP9YPIbzkbzWa9853/L8tB1DwdPXmN7uPg2KrbxQk5AEqzSh/RuMq8hXaH14CunbiSqXmEuTq0mOtMsfZw==
dependencies:
dotenv "^16.1.4"

abbrev@1:
version "1.1.1"
Expand Down Expand Up @@ -3546,6 +3548,11 @@ dotenv@^16.0.0:
resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.0.3.tgz#115aec42bac5053db3c456db30cc243a5a836a07"
integrity sha512-7GO6HghkA5fYG9TYnNxi14/7K9f5occMlp3zXAuSxn7CKCxt9xbNWG7yF8hTCSUchlfWSe3uLmlPfigevRItzQ==

dotenv@^16.1.4:
version "16.3.1"
resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.3.1.tgz#369034de7d7e5b120972693352a3bf112172cc3e"
integrity sha512-IPzF4w4/Rd94bA9imS68tZBaYyBWSCE47V1RGuMrB94iyTOIEwRmVL2x/4An+6mETpLrKJ5hQkB8W4kFAadeIQ==

drbg.js@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/drbg.js/-/drbg.js-1.0.1.tgz#3e36b6c42b37043823cdbc332d58f31e2445480b"
Expand Down

0 comments on commit afbab03

Please sign in to comment.