From c8c98bc3dff540b43bb0307ccc83281e17135c94 Mon Sep 17 00:00:00 2001 From: Uncle Stretch Date: Wed, 4 Feb 2026 17:45:47 +0300 Subject: [PATCH] fix compiler warnings Signed-off-by: Uncle Stretch --- Cargo.lock | 2 +- telemetry-shard/Cargo.toml | 2 +- telemetry-shard/src/main.rs | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 8dacfd1..b118171 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -564,7 +564,7 @@ dependencies = [ [[package]] name = "ghost-telemetry-core" -version = "0.1.2" +version = "0.1.3" dependencies = [ "anyhow", "bimap", diff --git a/telemetry-shard/Cargo.toml b/telemetry-shard/Cargo.toml index 0f3e303..e222f87 100644 --- a/telemetry-shard/Cargo.toml +++ b/telemetry-shard/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ghost-telemetry-shard" -version = "0.1.0" +version = "0.1.1" authors = ["Uncle Stinky uncle.stinky@ghostchain.io"] edition = "2021" diff --git a/telemetry-shard/src/main.rs b/telemetry-shard/src/main.rs index 850af58..06d5a61 100644 --- a/telemetry-shard/src/main.rs +++ b/telemetry-shard/src/main.rs @@ -307,14 +307,14 @@ where // Deserialize from JSON, warning in debug mode if deserialization fails: let node_message: json_message::NodeMessage = match serde_json::from_slice(&bytes) { Ok(node_message) => node_message, - #[cfg(debug)] + #[cfg(debug_assertions)] Err(e) => { let bytes: &[u8] = bytes.get(..512).unwrap_or_else(|| &bytes); let msg_start = std::str::from_utf8(bytes).unwrap_or_else(|_| "INVALID UTF8"); log::warn!("Failed to parse node message ({msg_start}): {e}"); continue; }, - #[cfg(not(debug))] + #[cfg(not(debug_assertions))] Err(_) => { continue; }