fix(identify): Don't fail on unknown multiaddr protocol #3279
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
With this commit
libp2p-identify
no longer discards the whole identify payload in case a listen addr of the remote node is invalid, but instead logs the failure, skips the invalid multiaddr and parses the remaining identify payload.This is especially relevant when rolling out a new protocol to a live network. Say that most nodes of a network run on an implementation version v1. Say that the
multiaddr
implementation is not aware of thewebrtc/
protocol. Say that a new version (v2) is rolled out to the network with support for thewebrtc/
protocol, listening viawebrtc/
by default. In such case all v1 nodes would discard all identify payloads of v2 nodes, given that the v2 identify payloads would contain thewebrtc/
protocol in theirlisten_addr
addresses.See #3244 for details.
Notes
Brings #3246 merged into
v0.50
intomaster
.Links to any relevant issues
Open Questions
Change checklist