From 9daa9c199a726c79ff8fbc4a852337501b5ec1a5 Mon Sep 17 00:00:00 2001 From: Daniel Chew Date: Wed, 14 Aug 2024 14:04:54 +0900 Subject: [PATCH] add mantis testnet --- .../remote_executor/programs/remote-executor/Cargo.toml | 3 ++- .../programs/remote-executor/src/state/governance_payload.rs | 4 ++++ .../programs/remote-executor/src/state/posted_vaa.rs | 3 ++- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/governance/remote_executor/programs/remote-executor/Cargo.toml b/governance/remote_executor/programs/remote-executor/Cargo.toml index db20da538f..dc6db445ea 100644 --- a/governance/remote_executor/programs/remote-executor/Cargo.toml +++ b/governance/remote_executor/programs/remote-executor/Cargo.toml @@ -13,7 +13,7 @@ no-entrypoint = [] no-idl = [] no-log-ix-name = [] cpi = ["no-entrypoint"] -default = ["pythnet"] +default = ["mantis_testnet"] # These features determine the network for deployment: # - Use `pythnet` for deploying on Pythnet # - Use `pythtest` for deploying on Pythtest @@ -24,6 +24,7 @@ pythtest = [] eclipse_devnet = [] eclipse_testnet = [] eclipse_mainnet = [] +mantis_testnet = [] [dependencies] anchor-lang = {version = "0.25.0", features = ["init-if-needed"]} diff --git a/governance/remote_executor/programs/remote-executor/src/state/governance_payload.rs b/governance/remote_executor/programs/remote-executor/src/state/governance_payload.rs index 494ab347d0..5ea9dc6056 100644 --- a/governance/remote_executor/programs/remote-executor/src/state/governance_payload.rs +++ b/governance/remote_executor/programs/remote-executor/src/state/governance_payload.rs @@ -20,6 +20,7 @@ pub const CHAIN_ID_ARRAY: &[(&str, u16)] = &[ ("eclipse_devnet", 40001), ("eclipse_testnet", 40002), ("eclipse_mainnet", 40003), + ("mantis_testnet", 40004), ]; #[cfg(any(feature = "pythnet", feature = "pythtest"))] @@ -34,6 +35,9 @@ pub const CHAIN_ID: u16 = 40002; #[cfg(feature = "eclipse_mainnet")] pub const CHAIN_ID: u16 = 40003; +#[cfg(feature = "mantis_testnet")] +pub const CHAIN_ID: u16 = 40004; + #[derive(AnchorDeserialize, AnchorSerialize, Debug, PartialEq, Eq)] pub struct ExecutorPayload { pub header: GovernanceHeader, diff --git a/governance/remote_executor/programs/remote-executor/src/state/posted_vaa.rs b/governance/remote_executor/programs/remote-executor/src/state/posted_vaa.rs index 4e5e769957..0448456083 100644 --- a/governance/remote_executor/programs/remote-executor/src/state/posted_vaa.rs +++ b/governance/remote_executor/programs/remote-executor/src/state/posted_vaa.rs @@ -23,7 +23,8 @@ impl Owner for AnchorVaa { #[cfg(any( feature = "eclipse_devnet", feature = "eclipse_testnet", - feature = "eclipse_mainnet" + feature = "eclipse_mainnet", + feature = "mantis_testnet", ))] fn owner() -> Pubkey { Pubkey::from_str("HDwcJBJXjL9FpJ7UBsYBtaDjsBUhuLCUYoz3zr8SWWaQ").unwrap()