From 8e47138c260769f8246afbcabe204250183a0bc9 Mon Sep 17 00:00:00 2001 From: Haider-Ali-DS Date: Wed, 26 Feb 2025 18:31:19 +0500 Subject: [PATCH] test code cleanup --- chronicle/src/main.rs | 1 - config/envs/local/local-evm.yaml | 5 ----- docker-compose.yml | 1 - gmp/evm/src/lib.rs | 16 ---------------- tc-cli/src/lib.rs | 2 ++ 5 files changed, 2 insertions(+), 23 deletions(-) diff --git a/chronicle/src/main.rs b/chronicle/src/main.rs index 05014d960..a7af175bb 100644 --- a/chronicle/src/main.rs +++ b/chronicle/src/main.rs @@ -84,7 +84,6 @@ async fn main() -> Result<()> { init_logger(); time_primitives::init_ss58_version(); let args = ChronicleArgs::parse(); - tracing::info!("chronicle args are{:?}", args.cctp_sender); if args.cctp_sender.is_some() && args.cctp_attestation.is_none() { anyhow::bail!("Requires cctp attestation url with cctp sender"); diff --git a/config/envs/local/local-evm.yaml b/config/envs/local/local-evm.yaml index cf200adfc..cde108e2b 100644 --- a/config/envs/local/local-evm.yaml +++ b/config/envs/local/local-evm.yaml @@ -1,6 +1,5 @@ config: chronicle_funds: 10. - # timechain_url: 'ws://127.0.0.1:9944' timechain_url: 'ws://validator:9944' prices_path: 'prices.csv' contracts: @@ -15,7 +14,6 @@ networks: blockchain: "anvil" network: "dev" url: "ws://chain-2-evm:8545" - # url: "ws://127.0.0.1:8545" admin_funds: 10. gateway_funds: 1. chronicle_funds: 1. @@ -33,7 +31,6 @@ networks: blockchain: "anvil" network: "dev" url: "ws://chain-3-evm:8545" - # url: "ws://127.0.0.1:8545" admin_funds: 10. gateway_funds: 1. chronicle_funds: 1. @@ -49,5 +46,3 @@ networks: chronicles: - http://timechain-chronicle-2-evm-1:8080 - http://timechain-chronicle-3-evm-1:8080 - # - http://localhost:8080 - # - http://localhost:8081 diff --git a/docker-compose.yml b/docker-compose.yml index 13f6c2618..5289f89e1 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -146,6 +146,5 @@ services: environment: RUST_BACKTRACE: 1 RUST_LOG: 'gmp_evm=info' - RUST_MIN_STACK: "16777216" profiles: - never diff --git a/gmp/evm/src/lib.rs b/gmp/evm/src/lib.rs index a3784a70a..fb51e5fdc 100644 --- a/gmp/evm/src/lib.rs +++ b/gmp/evm/src/lib.rs @@ -401,23 +401,16 @@ impl IConnectorBuilder for Connector { let client = default_client(¶ms.url, None) .await .with_context(|| "Cannot get ws client for url: {url}")?; - if params.cctp_sender.is_some() { - tracing::info!("CCTP is enabled"); - tracing::info!("params. {:?}", params.cctp_attestation) - } let adapter = Adapter(client); let cctp_sender: Result> = params .cctp_sender .map(|item| { - tracing::info!("cctp sender: {}", item); let clean_hex = item.strip_prefix("0x").unwrap_or(&item); let bytes = hex::decode(clean_hex) .map_err(|e| anyhow::anyhow!("Hex decode error: {}", e))?; - tracing::info!("cctp bytes: {:?}", bytes); let arr: Address = bytes .try_into() .map_err(|_| anyhow::anyhow!("Unable to make Address from hex bytes"))?; - tracing::info!("cctp bytes: {:?}", arr); Ok(arr) }) .transpose(); @@ -541,15 +534,6 @@ impl IConnector for Connector { gas_cost: log.gasCost.into(), bytes: log.data.data.into(), }; - tracing::info!("gmp created got hit: {:?}", gmp_message); - tracing::info!( - "gmp created got hit from source: {:?}", - hex::encode(gmp_message.src) - ); - tracing::info!( - "gmp created cctp sender: {:?}", - hex::encode(cctp_sender.unwrap()) - ); if Some(gmp_message.src) == cctp_sender { let mut cctp_queue = self.cctp_queue.lock().await; cctp_queue.push((gmp_message.clone(), 0)); diff --git a/tc-cli/src/lib.rs b/tc-cli/src/lib.rs index fd80db628..3e4f73276 100644 --- a/tc-cli/src/lib.rs +++ b/tc-cli/src/lib.rs @@ -77,6 +77,8 @@ impl Tc { url: network.url.clone(), mnemonic: env.target_mnemonic.clone(), cctp_sender: None, + // TODO move to config? + // This params is for checking cctp attestation with tc-cli cctp_attestation: Some(String::from( "https://iris-api-sandbox.circle.com/attestations/", )),