From c1f68d2fa40b0499c06d06bc2da0960cdd45bf5a Mon Sep 17 00:00:00 2001 From: davidrusu Date: Thu, 27 Aug 2026 08:07:36 +0000 Subject: [PATCH] chore: reduce noisy p2p log levels (dial, Kademlia, blend edge) (#3302) Co-authored-by: Claude Fable 5 --- consensus/cryptarchia-sync/src/libp2p/errors.rs | 2 +- libp2p/src/behaviour/kademlia/behaviour_ext.rs | 2 +- services/blend/src/edge/backends/libp2p/swarm.rs | 2 +- services/network/src/backends/libp2p/swarm/mod.rs | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/consensus/cryptarchia-sync/src/libp2p/errors.rs b/consensus/cryptarchia-sync/src/libp2p/errors.rs index 75c3057b4..960a88624 100644 --- a/consensus/cryptarchia-sync/src/libp2p/errors.rs +++ b/consensus/cryptarchia-sync/src/libp2p/errors.rs @@ -18,7 +18,7 @@ pub enum ChainSyncErrorKind { #[error("Stream error: {0}")] OpenStreamError(#[from] libp2p_stream::OpenStreamError), - #[error("Failed to unpack data from reader: {0}")] + #[error("Packing error: {0}")] PackingError(#[from] PackingError), #[error("Failed to receive data from channel: {0}")] diff --git a/libp2p/src/behaviour/kademlia/behaviour_ext.rs b/libp2p/src/behaviour/kademlia/behaviour_ext.rs index 98ce72619..b3df541a1 100644 --- a/libp2p/src/behaviour/kademlia/behaviour_ext.rs +++ b/libp2p/src/behaviour/kademlia/behaviour_ext.rs @@ -31,7 +31,7 @@ impl Behaviour { ); } RoutingUpdate::Failed => { - tracing::error!( + tracing::debug!( target: LOG_TARGET, "Failed to add address {:?} to peer {:?}", addr, diff --git a/services/blend/src/edge/backends/libp2p/swarm.rs b/services/blend/src/edge/backends/libp2p/swarm.rs index 4d0f153e9..bbcd6f196 100644 --- a/services/blend/src/edge/backends/libp2p/swarm.rs +++ b/services/blend/src/edge/backends/libp2p/swarm.rs @@ -260,7 +260,7 @@ where .unwrap(); let new_dial_attempt_number = dial_attempt.attempt_number.checked_add(1).unwrap(); if new_dial_attempt_number > self.max_dial_attempts_per_connection { - error!( + warn!( target: LOG_TARGET, "Giving up on message delivery: peer {peer_id:?} was not reachable after {} attempts. Dropping the message.", self.max_dial_attempts_per_connection diff --git a/services/network/src/backends/libp2p/swarm/mod.rs b/services/network/src/backends/libp2p/swarm/mod.rs index 1e5e545b6..79545e271 100644 --- a/services/network/src/backends/libp2p/swarm/mod.rs +++ b/services/network/src/backends/libp2p/swarm/mod.rs @@ -212,7 +212,7 @@ impl SwarmHandler { self.pending_dials.remove(&connection_id); } error => { - tracing::error!( + tracing::debug!( target: LOG_TARGET, "Failed to connect to peer: {peer_id:?} {connection_id:?} due to: {error}" );