diff --git a/beacon_node/lighthouse_network/src/service/mod.rs b/beacon_node/lighthouse_network/src/service/mod.rs index 6ab5279b8be..9023e7c8e70 100644 --- a/beacon_node/lighthouse_network/src/service/mod.rs +++ b/beacon_node/lighthouse_network/src/service/mod.rs @@ -1469,14 +1469,24 @@ impl Network { connection_id: _, } => { let error_repr = match error { - libp2p::swarm::ListenError::Aborted => "incoming connection aborted".to_string(), - libp2p::swarm::ListenError::WrongPeerId { obtained, endpoint } => format!("wrong peer id, obtained {obtained}, endpoint {endpoint:?}"), - libp2p::swarm::ListenError::LocalPeerId { endpoint } => format!("dialing local peer id {endpoint:?}"), - libp2p::swarm::ListenError::Denied { cause } => format!("connection was denied with cause {cause}"), - libp2p::swarm::ListenError::Transport(t) => { - match t { - libp2p::TransportError::MultiaddrNotSupported(m) => format!("transport error: multiaddr not supported: {m}"), - libp2p::TransportError::Other(e) => format!("transport error: other: {e}"), + libp2p::swarm::ListenError::Aborted => { + "incoming connection aborted".to_string() + } + libp2p::swarm::ListenError::WrongPeerId { obtained, endpoint } => { + format!("wrong peer id, obtained {obtained}, endpoint {endpoint:?}") + } + libp2p::swarm::ListenError::LocalPeerId { endpoint } => { + format!("dialing local peer id {endpoint:?}") + } + libp2p::swarm::ListenError::Denied { cause } => { + format!("connection was denied with cause {cause}") + } + libp2p::swarm::ListenError::Transport(t) => match t { + libp2p::TransportError::MultiaddrNotSupported(m) => { + format!("transport error: multiaddr not supported: {m}") + } + libp2p::TransportError::Other(e) => { + format!("transport error: other: {e}") } }, }; @@ -1551,4 +1561,4 @@ impl Network { pub async fn next_event(&mut self) -> NetworkEvent { futures::future::poll_fn(|cx| self.poll_network(cx)).await } -} \ No newline at end of file +}