Skip to content

Commit

Permalink
feat: human readable information for handshake failures (#196)
Browse files Browse the repository at this point in the history
Error message suggesting checking the port configuration.
  • Loading branch information
pompon0 authored Sep 10, 2024
1 parent f3a6417 commit a298f50
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion node/actors/network/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,11 @@ impl Runner {
tracing::info!("new connection");
let (stream, endpoint) = preface::accept(ctx, stream)
.await
.context("preface::accept()")?;
.context("preface::accept()")
.context(
"establishing new incoming TCP connection failed. \
The possible cause is that someone was trying to establish a non-consensus connection to the consensus port. \
If you believe this connection should have succeeded, please check your port configuration")?;
match endpoint {
preface::Endpoint::ConsensusNet => {
if let Some(c) = &self.net.consensus {
Expand Down

0 comments on commit a298f50

Please sign in to comment.