-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: Update go-multiaddr to v0.15-pre #3145
base: master
Are you sure you want to change the base?
Conversation
894e6dc
to
b434cb2
Compare
bd662af
to
e367bc8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some NITs. This is obviously very difficult to review. If there's anything specific you want me to look for I can review again.
withNewPath := withoutPath.EncapsulateC(relativePathComponent) | ||
return url.Parse("multiaddr:" + withNewPath.String()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
append?
@@ -578,11 +578,11 @@ func checkDialWorkerLoopScheduling(t *testing.T, s1, s2 *Swarm, tc schedulingTes | |||
// failDials is used to track dials which should fail in the future | |||
// at appropriate moment a message is sent to dialState.ch to trigger | |||
// failure | |||
failDials := make(map[ma.Multiaddr]dialState) | |||
failDials := make(map[*ma.Multiaddr]dialState) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should add this transform, using the pointer for map key, to release notes if not already added.
@@ -28,25 +28,25 @@ func ToQuicMultiaddr(na net.Addr, version quic.Version) (ma.Multiaddr, error) { | |||
|
|||
func FromQuicMultiaddr(addr ma.Multiaddr) (*net.UDPAddr, quic.Version, error) { | |||
var version quic.Version | |||
var partsBeforeQUIC []ma.Multiaddr | |||
ma.ForEach(addr, func(c ma.Component) bool { | |||
var partsBeforeQUIC ma.Multiaddr |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
initialize with capacity?
@@ -419,7 +419,7 @@ func (t *transport) Resolve(_ context.Context, maddr ma.Multiaddr) ([]ma.Multiad | |||
if err != nil { | |||
return nil, err | |||
} | |||
return []ma.Multiaddr{beforeQuicMA.Encapsulate(quicComponent).Encapsulate(sniComponent).Encapsulate(afterQuicMA)}, nil | |||
return []ma.Multiaddr{beforeQuicMA.EncapsulateC(quicComponent).EncapsulateC(sniComponent).Encapsulate(afterQuicMA)}, nil |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can this be a single append?
As there are no changes to go-multiaddr-fmt, does it mean it's already compatible with the new go-multiaddr representation? |
This kicks off the great multiaddr v0.15 rollout to our dependencies. Tracked in multiformats/go-multiaddr#267.
After this PR is approved, I'll release go-multiaddr v0.15 and start the rollout.