Skip to content

Commit

Permalink
Upgrade go-libp2p (#6066)
Browse files Browse the repository at this point in the history
## Motivation

`go-libp2p` v0.34.0 had to be rolled back because of a bug that was introduced and affected go-spacemesh, for details see: #6017

Since then `go-libp2p` v0.35.1 has been released that fixes the issue. Upgrading to this version would also allow us to update other dependencies that are currently blocked.
  • Loading branch information
fasmat committed Jun 24, 2024
1 parent aa148b3 commit 7bcf5b9
Show file tree
Hide file tree
Showing 4 changed files with 158 additions and 46 deletions.
4 changes: 2 additions & 2 deletions fetch/fetch.go
Original file line number Diff line number Diff line change
Expand Up @@ -294,12 +294,12 @@ func NewFetch(
}
host.Network().Notify(&network.NotifyBundle{
ConnectedF: func(_ network.Network, c network.Conn) {
if !c.Stat().Transient {
if !c.Stat().Limited {
connectedf(c.RemotePeer())
}
},
DisconnectedF: func(_ network.Network, c network.Conn) {
if !c.Stat().Transient && !host.Connected(c.RemotePeer()) {
if !c.Stat().Limited && !host.Connected(c.RemotePeer()) {
f.logger.With().Debug("remove peer", log.Stringer("id", c.RemotePeer()))
f.peers.Delete(c.RemotePeer())
}
Expand Down
44 changes: 30 additions & 14 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ go 1.22.3
require (
cloud.google.com/go/storage v1.42.0
github.com/ALTree/bigfloat v0.2.0
github.com/chaos-mesh/chaos-mesh/api v0.0.0-20240514101152-6411f530b0a5
github.com/chaos-mesh/chaos-mesh/api v0.0.0-20240623075305-82f2d100a2a0
github.com/cosmos/btcutil v1.0.5
github.com/go-llsqlite/crawshaw v0.5.3
github.com/gofrs/flock v0.8.1
Expand All @@ -20,9 +20,9 @@ require (
github.com/ipfs/go-ds-leveldb v0.5.0
github.com/ipfs/go-log/v2 v2.5.1
github.com/jonboulle/clockwork v0.4.0
github.com/libp2p/go-libp2p v0.33.2
github.com/libp2p/go-libp2p v0.35.1
github.com/libp2p/go-libp2p-kad-dht v0.25.2
github.com/libp2p/go-libp2p-pubsub v0.10.0
github.com/libp2p/go-libp2p-pubsub v0.11.0
github.com/libp2p/go-libp2p-record v0.2.0
github.com/libp2p/go-msgio v0.3.0
github.com/libp2p/go-yamux/v4 v4.0.1
Expand All @@ -34,7 +34,7 @@ require (
github.com/prometheus/client_golang v1.19.1
github.com/prometheus/client_model v0.6.1
github.com/prometheus/common v0.54.0
github.com/quic-go/quic-go v0.42.0
github.com/quic-go/quic-go v0.45.1
github.com/rs/cors v1.11.0
github.com/santhosh-tekuri/jsonschema/v5 v5.3.1
github.com/seehuhn/mt19937 v1.0.0
Expand All @@ -55,10 +55,10 @@ require (
github.com/zeebo/blake3 v0.2.3
go.uber.org/mock v0.4.0
go.uber.org/zap v1.27.0
golang.org/x/exp v0.0.0-20240506185415-9bf2ced13842
golang.org/x/exp v0.0.0-20240613232115-7f521ea00fb8
golang.org/x/sync v0.7.0
golang.org/x/time v0.5.0
google.golang.org/genproto/googleapis/rpc v0.0.0-20240528184218-531527333157
google.golang.org/genproto/googleapis/rpc v0.0.0-20240617180043-68d350f18fd4
google.golang.org/grpc v1.64.0
google.golang.org/protobuf v1.34.2
k8s.io/api v0.30.2
Expand Down Expand Up @@ -177,12 +177,28 @@ require (
github.com/opentracing/opentracing-go v1.2.0 // indirect
github.com/pbnjay/memory v0.0.0-20210728143218-7b4eea64cf58 // indirect
github.com/pelletier/go-toml/v2 v2.2.2 // indirect
github.com/pion/datachannel v1.5.6 // indirect
github.com/pion/dtls/v2 v2.2.11 // indirect
github.com/pion/ice/v2 v2.3.25 // indirect
github.com/pion/interceptor v0.1.29 // indirect
github.com/pion/logging v0.2.2 // indirect
github.com/pion/mdns v0.0.12 // indirect
github.com/pion/randutil v0.1.0 // indirect
github.com/pion/rtcp v1.2.14 // indirect
github.com/pion/rtp v1.8.6 // indirect
github.com/pion/sctp v1.8.16 // indirect
github.com/pion/sdp/v3 v3.0.9 // indirect
github.com/pion/srtp/v2 v2.0.18 // indirect
github.com/pion/stun v0.6.1 // indirect
github.com/pion/transport/v2 v2.2.5 // indirect
github.com/pion/turn/v2 v2.1.6 // indirect
github.com/pion/webrtc/v3 v3.2.40 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
github.com/polydawn/refmt v0.89.0 // indirect
github.com/prometheus/procfs v0.12.0 // indirect
github.com/quic-go/qpack v0.4.0 // indirect
github.com/quic-go/webtransport-go v0.6.0 // indirect
github.com/quic-go/webtransport-go v0.8.0 // indirect
github.com/raulk/go-watchdog v1.3.0 // indirect
github.com/robfig/cron/v3 v3.0.1 // indirect
github.com/russross/blackfriday/v2 v2.1.0 // indirect
Expand All @@ -204,14 +220,14 @@ require (
go.uber.org/dig v1.17.1 // indirect
go.uber.org/fx v1.21.1 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/crypto v0.23.0 // indirect
golang.org/x/mod v0.17.0 // indirect
golang.org/x/net v0.25.0 // indirect
golang.org/x/crypto v0.24.0 // indirect
golang.org/x/mod v0.18.0 // indirect
golang.org/x/net v0.26.0 // indirect
golang.org/x/oauth2 v0.21.0 // indirect
golang.org/x/sys v0.20.0 // indirect
golang.org/x/term v0.20.0 // indirect
golang.org/x/text v0.15.0 // indirect
golang.org/x/tools v0.21.0 // indirect
golang.org/x/sys v0.21.0 // indirect
golang.org/x/term v0.21.0 // indirect
golang.org/x/text v0.16.0 // indirect
golang.org/x/tools v0.22.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect
gonum.org/v1/gonum v0.13.0 // indirect
google.golang.org/api v0.183.0 // indirect
Expand Down
Loading

0 comments on commit 7bcf5b9

Please sign in to comment.