Skip to content

Commit e0af12d

Browse files
feat:(contract-manager): add movement mainnet (#2349)
* feat:(contract-manager): add movement mainnet * fix precommit
1 parent 5602f4b commit e0af12d

File tree

6 files changed

+22
-1
lines changed

6 files changed

+22
-1
lines changed

contract_manager/scripts/sync_wormhole_guardian_set.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import yargs from "yargs";
22
import { hideBin } from "yargs/helpers";
33
import {
4+
AptosWormholeContract,
45
CosmWasmPriceFeedContract,
56
DefaultStore,
67
EvmPriceFeedContract,
@@ -29,7 +30,10 @@ async function main() {
2930
const chains = argv.chain;
3031

3132
for (const contract of Object.values(DefaultStore.wormhole_contracts)) {
32-
if (contract instanceof SuiWormholeContract) {
33+
if (
34+
contract instanceof SuiWormholeContract ||
35+
contract instanceof AptosWormholeContract
36+
) {
3337
if (chains && !chains.includes(contract.getChain().getId())) {
3438
continue;
3539
}

contract_manager/src/contracts/aptos.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,10 @@ export class AptosWormholeContract extends WormholeContract {
7676
return Number(data.chain_id.number);
7777
}
7878

79+
public getChain(): AptosChain {
80+
return this.chain;
81+
}
82+
7983
async getGuardianSet(): Promise<string[]> {
8084
const data = await this.getState();
8185
const client = this.chain.getClient();

contract_manager/store/chains/AptosChains.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,8 @@
2929
mainnet: false
3030
rpcUrl: https://aptos.testnet.bardock.movementlabs.xyz/v1
3131
type: AptosChain
32+
- id: movement_mainnet
33+
wormholeChainName: movement_mainnet
34+
mainnet: true
35+
rpcUrl: https://mainnet.movementnetwork.xyz/v1
36+
type: AptosChain

contract_manager/store/contracts/AptosPriceFeedContracts.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,7 @@
2222
stateId: "0x9357e76fe965c9956a76181ee49f66d51b7f9c3800182a944ed96be86301e49f"
2323
wormholeStateId: "0x9236893d6444b208b7e0b3e8d4be4ace90b6d17817ab7d1584e46a33ef5c50c9"
2424
type: AptosPriceFeedContract
25+
- chain: movement_mainnet
26+
stateId: "0x9357e76fe965c9956a76181ee49f66d51b7f9c3800182a944ed96be86301e49f"
27+
wormholeStateId: "0x9236893d6444b208b7e0b3e8d4be4ace90b6d17817ab7d1584e46a33ef5c50c9"
28+
type: AptosPriceFeedContract

contract_manager/store/contracts/AptosWormholeContracts.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,6 @@
1616
- chain: movement_bardock_testnet
1717
address: "0x9236893d6444b208b7e0b3e8d4be4ace90b6d17817ab7d1584e46a33ef5c50c9"
1818
type: AptosWormholeContract
19+
- chain: movement_mainnet
20+
address: "0x9236893d6444b208b7e0b3e8d4be4ace90b6d17817ab7d1584e46a33ef5c50c9"
21+
type: AptosWormholeContract

governance/xc_admin/packages/xc_admin_common/src/chains.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,7 @@ export const RECEIVER_CHAINS = {
107107
threat_level_midnight: 60074,
108108
just_breathe: 60075,
109109
berachain_mainnet: 60076,
110+
movement_mainnet: 60077,
110111

111112
// Testnets as a separate chain ids (to use stable data sources and governance for them)
112113
injective_testnet: 60013,

0 commit comments

Comments
 (0)