From 38a8c2831ace964936d3ce544707661e93169da1 Mon Sep 17 00:00:00 2001 From: Cinque McFarlane-Blake <1519017+cinquemb@users.noreply.github.com> Date: Wed, 29 Mar 2023 17:15:08 +0000 Subject: [PATCH] [evm] Deploy on Canto Testnet (#725) * [evm] Deploy on Canto Testnet * Redeploy * Address feedbacks --------- Co-authored-by: Ali Behjati --- governance/xc_governance_sdk_js/src/chains.ts | 1 + package-lock.json | 2 +- .../ethereum/contracts/.env.prod.canto_testnet | 5 +++++ .../ethereum/contracts/networks/7701.json | 16 ++++++++++++++++ .../ethereum/contracts/truffle-config.js | 8 ++++++++ target_chains/ethereum/sdk/js/package.json | 2 +- target_chains/ethereum/sdk/js/src/index.ts | 1 + 7 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 target_chains/ethereum/contracts/.env.prod.canto_testnet create mode 100644 target_chains/ethereum/contracts/networks/7701.json diff --git a/governance/xc_governance_sdk_js/src/chains.ts b/governance/xc_governance_sdk_js/src/chains.ts index eda79b22..9588acfd 100644 --- a/governance/xc_governance_sdk_js/src/chains.ts +++ b/governance/xc_governance_sdk_js/src/chains.ts @@ -10,6 +10,7 @@ export const RECEIVER_CHAINS = { evmos: 60006, neon: 60007, polygon_zkevm: 60008, + canto: 60009, }; // If there is any overlapping value the receiver chain will replace the wormhole diff --git a/package-lock.json b/package-lock.json index c9ae72dd..0d9691c7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -49988,7 +49988,7 @@ }, "target_chains/ethereum/sdk/js": { "name": "@pythnetwork/pyth-evm-js", - "version": "1.10.0", + "version": "1.11.0", "license": "Apache-2.0", "dependencies": { "@pythnetwork/price-service-client": "*", diff --git a/target_chains/ethereum/contracts/.env.prod.canto_testnet b/target_chains/ethereum/contracts/.env.prod.canto_testnet new file mode 100644 index 00000000..4a28dc0c --- /dev/null +++ b/target_chains/ethereum/contracts/.env.prod.canto_testnet @@ -0,0 +1,5 @@ +MIGRATIONS_DIR=./migrations/prod-receiver +MIGRATIONS_NETWORK=canto_testnet +WORMHOLE_CHAIN_NAME=canto +CLUSTER=testnet +VALID_TIME_PERIOD_SECONDS=60 diff --git a/target_chains/ethereum/contracts/networks/7701.json b/target_chains/ethereum/contracts/networks/7701.json new file mode 100644 index 00000000..e597b787 --- /dev/null +++ b/target_chains/ethereum/contracts/networks/7701.json @@ -0,0 +1,16 @@ +[ + { + "contractName": "Migrations", + "address": "0xf5BBe9558F4Bf37F1eB82fb2CEdb1C775FA56832" + }, + { + "contractName": "WormholeReceiver", + "address": "0x8250f4aF4B972684F7b336503E2D6dFeDeB1487a", + "transactionHash": "0x88f723ceda562f62f8694a6636967189f41fd32819dbe9aeebd47fb37182e4cf" + }, + { + "contractName": "PythUpgradable", + "address": "0xA2aa501b19aff244D90cc15a4Cf739D2725B5729", + "transactionHash": "0x96a9388ee29c40f04e306aaaf924e25e228545d443d2ef7b584c043c8f7f9666" + } +] diff --git a/target_chains/ethereum/contracts/truffle-config.js b/target_chains/ethereum/contracts/truffle-config.js index 42dde492..c10a2de3 100644 --- a/target_chains/ethereum/contracts/truffle-config.js +++ b/target_chains/ethereum/contracts/truffle-config.js @@ -152,6 +152,14 @@ module.exports = { gas: 8000000, gasPrice: 300000000000, }, + canto_testnet: { + provider: payerProvider(`https://canto-testnet.plexnode.wtf`), + deploymentPollingInterval: 20000, + network_id: 7701, + networkCheckTimeout: 1000000, + timeoutBlocks: 200, + disableConfirmationListener: true, + }, celo: { provider: payerProvider(`https://forno.celo.org`), network_id: 42220, diff --git a/target_chains/ethereum/sdk/js/package.json b/target_chains/ethereum/sdk/js/package.json index 2f9ed202..dec91a6f 100644 --- a/target_chains/ethereum/sdk/js/package.json +++ b/target_chains/ethereum/sdk/js/package.json @@ -1,6 +1,6 @@ { "name": "@pythnetwork/pyth-evm-js", - "version": "1.10.0", + "version": "1.11.0", "description": "Pyth Network EVM Utils in JS", "homepage": "https://pyth.network", "author": { diff --git a/target_chains/ethereum/sdk/js/src/index.ts b/target_chains/ethereum/sdk/js/src/index.ts index a6392d50..cbfe1a43 100644 --- a/target_chains/ethereum/sdk/js/src/index.ts +++ b/target_chains/ethereum/sdk/js/src/index.ts @@ -42,4 +42,5 @@ export const CONTRACT_ADDR: Record = { neon_devnet: "0x2FF312f50689ad279ABb164dB255Eb568733BD6c", polygon_zkevm_testnet: "0xd54bf1758b1C932F86B178F8b1D5d1A7e2F62C2E", polygon_zkevm: "0xC5E56d6b40F3e3B5fbfa266bCd35C37426537c65", + canto_testnet: "0xA2aa501b19aff244D90cc15a4Cf739D2725B5729", };