rust-libp2p icon indicating copy to clipboard operation
rust-libp2p copied to clipboard

feat(swarm): add `peer_id` to `ListenFailure`

Open nathanielc opened this issue 1 year ago • 2 comments

Description

It's possible in certain failure modes to know the peer_id of a failed incoming connection. For example when an inbound connection has been negotiated/upgraded but then rejected locally for a connection limit or similar reason. In these cases it makes sense to communicate the peer_id to behaviours in case they have created any internal state about the peer.

Related https://github.com/libp2p/rust-libp2p/pull/4777

Notes & open questions

Change checklist

  • [x] I have performed a self-review of my own code
  • [x] I have made corresponding changes to the documentation
  • [ ] I have added tests that prove my fix is effective or that my feature works
  • [x] A changelog entry has been made in the appropriate crates

nathanielc avatar Nov 07 '23 16:11 nathanielc

This is a breaking change so'll have to hold off on it for a while. I hope that is okay.

Yep all good,no rush on this feature from us.

nathanielc avatar Nov 09 '23 15:11 nathanielc

This pull request has merge conflicts. Could you please resolve them @nathanielc? 🙏

mergify[bot] avatar Dec 18 '23 09:12 mergify[bot]