diff --git a/Cargo.lock b/Cargo.lock index 6c215e16..e89447b4 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3150,7 +3150,7 @@ dependencies = [ [[package]] name = "libp2p-swarm" -version = "0.43.1" +version = "0.43.2" dependencies = [ "async-std", "either", diff --git a/Cargo.toml b/Cargo.toml index 5a3885ed..07ac8ab9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -87,7 +87,7 @@ libp2p-quic = { version = "0.8.0-alpha", path = "transports/quic" } libp2p-relay = { version = "0.16.1", path = "protocols/relay" } libp2p-rendezvous = { version = "0.13.0", path = "protocols/rendezvous" } libp2p-request-response = { version = "0.25.1", path = "protocols/request-response" } -libp2p-swarm = { version = "0.43.1", path = "swarm" } +libp2p-swarm = { version = "0.43.2", path = "swarm" } libp2p-swarm-derive = { version = "0.33.0", path = "swarm-derive" } libp2p-swarm-test = { version = "0.2.0", path = "swarm-test" } libp2p-tcp = { version = "0.40.0", path = "transports/tcp" } diff --git a/swarm/CHANGELOG.md b/swarm/CHANGELOG.md index ecf49a38..b5c33d90 100644 --- a/swarm/CHANGELOG.md +++ b/swarm/CHANGELOG.md @@ -1,3 +1,9 @@ +## 0.43.2 - unreleased +- Display the cause of a `ListenError::Denied`. + See [PR 4232] + +[PR 4232]: https://github.com/libp2p/rust-libp2p/pull/4158 + ## 0.43.1 - Do not announce external address candidate before address translation, unless translation does not apply. diff --git a/swarm/Cargo.toml b/swarm/Cargo.toml index 10bd747e..752491cd 100644 --- a/swarm/Cargo.toml +++ b/swarm/Cargo.toml @@ -3,7 +3,7 @@ name = "libp2p-swarm" edition = "2021" rust-version = { workspace = true } description = "The libp2p swarm" -version = "0.43.1" +version = "0.43.2" authors = ["Parity Technologies "] license = "MIT" repository = "https://github.com/libp2p/rust-libp2p" diff --git a/swarm/src/lib.rs b/swarm/src/lib.rs index f8c8e855..867e4941 100644 --- a/swarm/src/lib.rs +++ b/swarm/src/lib.rs @@ -1684,8 +1684,8 @@ impl fmt::Display for ListenError { ListenError::Transport(_) => { write!(f, "Listen error: Failed to negotiate transport protocol(s)") } - ListenError::Denied { .. } => { - write!(f, "Listen error") + ListenError::Denied { cause } => { + write!(f, "Listen error: Denied: {cause}") } ListenError::LocalPeerId { endpoint } => { write!(f, "Listen error: Local peer ID at {endpoint:?}.")