Skip to content
This repository has been archived by the owner on Jun 20, 2023. It is now read-only.

chore: update go-libp2p to v0.22.0 #35

Merged
merged 1 commit into from
Sep 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 28 additions & 23 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,38 +3,43 @@ module github.com/ipfs/go-ipfs-routing
go 1.18

require (
github.com/gogo/protobuf v1.2.1
github.com/ipfs/go-cid v0.0.5
github.com/ipfs/go-datastore v0.5.0
github.com/gogo/protobuf v1.3.2
github.com/ipfs/go-cid v0.3.2
github.com/ipfs/go-datastore v0.6.0
github.com/ipfs/go-ipfs-delay v0.0.1
github.com/ipfs/go-ipfs-ds-help v0.1.1
github.com/ipfs/go-ipfs-util v0.0.1
github.com/ipfs/go-ipfs-ds-help v1.1.0
github.com/ipfs/go-ipfs-util v0.0.2
github.com/ipfs/go-log v0.0.1
github.com/libp2p/go-libp2p-core v0.0.2
github.com/libp2p/go-libp2p-record v0.1.0
github.com/libp2p/go-libp2p-testing v0.0.3
github.com/multiformats/go-multiaddr v0.0.4
github.com/multiformats/go-multihash v0.0.13
github.com/libp2p/go-libp2p v0.22.0
github.com/libp2p/go-libp2p-record v0.2.0
github.com/libp2p/go-libp2p-testing v0.12.0
github.com/multiformats/go-multiaddr v0.7.0
github.com/multiformats/go-multihash v0.2.1
)

require (
github.com/btcsuite/btcd v0.0.0-20190523000118-16327141da8c // indirect
github.com/google/uuid v1.1.1 // indirect
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/jbenet/goprocess v0.1.4 // indirect
github.com/klauspost/cpuid/v2 v2.1.0 // indirect
github.com/libp2p/go-buffer-pool v0.1.0 // indirect
github.com/libp2p/go-openssl v0.1.0 // indirect
github.com/mattn/go-colorable v0.1.1 // indirect
github.com/mattn/go-isatty v0.0.5 // indirect
github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1 // indirect
github.com/minio/sha256-simd v0.1.1-0.20190913151208-6de447530771 // indirect
github.com/mr-tron/base58 v1.1.3 // indirect
github.com/multiformats/go-base32 v0.0.3 // indirect
github.com/multiformats/go-multibase v0.0.1 // indirect
github.com/multiformats/go-varint v0.0.5 // indirect
github.com/mattn/go-isatty v0.0.16 // indirect
github.com/mattn/go-pointer v0.0.1 // indirect
github.com/minio/sha256-simd v1.0.0 // indirect
github.com/mr-tron/base58 v1.2.0 // indirect
github.com/multiformats/go-base32 v0.0.4 // indirect
github.com/multiformats/go-base36 v0.1.0 // indirect
github.com/multiformats/go-multibase v0.1.1 // indirect
github.com/multiformats/go-multicodec v0.5.0 // indirect
github.com/multiformats/go-varint v0.0.6 // indirect
github.com/opentracing/opentracing-go v1.0.2 // indirect
github.com/spacemonkeygo/openssl v0.0.0-20181017203307-c2dcc5cca94a // indirect
github.com/spacemonkeygo/spacelog v0.0.0-20180420211403-2296661a0572 // indirect
github.com/spaolacci/murmur3 v1.1.0 // indirect
github.com/whyrusleeping/go-logging v0.0.0-20170515211332-0457bb6b88fc // indirect
golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8 // indirect
golang.org/x/net v0.0.0-20190620200207-3b0461eec859 // indirect
golang.org/x/sys v0.0.0-20190412213103-97732733099d // indirect
golang.org/x/crypto v0.0.0-20220525230936-793ad666bf5e // indirect
golang.org/x/net v0.0.0-20220812174116-3211cb980234 // indirect
golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab // indirect
lukechampine.com/blake3 v1.1.7 // indirect
)
167 changes: 82 additions & 85 deletions go.sum

Large diffs are not rendered by default.

14 changes: 6 additions & 8 deletions mock/centralized_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,11 @@ import (
"context"
"time"

cid "github.com/ipfs/go-cid"
"github.com/ipfs/go-cid"
logging "github.com/ipfs/go-log"

"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-core/routing"
"github.com/libp2p/go-libp2p-testing/net"

tnet "github.com/libp2p/go-libp2p-testing/net"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/libp2p/go-libp2p/core/routing"
ma "github.com/multiformats/go-multiaddr"
)

Expand All @@ -22,13 +20,13 @@ type client struct {
peer tnet.Identity
}

// FIXME(brian): is this method meant to simulate putting a value into the network?
// PutValue FIXME(brian): is this method meant to simulate putting a value into the network?
func (c *client) PutValue(ctx context.Context, key string, val []byte, opts ...routing.Option) error {
log.Debugf("PutValue: %s", key)
return c.vs.PutValue(ctx, key, val, opts...)
}

// FIXME(brian): is this method meant to simulate getting a value from the network?
// GetValue FIXME(brian): is this method meant to simulate getting a value from the network?
func (c *client) GetValue(ctx context.Context, key string, opts ...routing.Option) ([]byte, error) {
log.Debugf("GetValue: %s", key)
return c.vs.GetValue(ctx, key, opts...)
Expand Down
10 changes: 4 additions & 6 deletions mock/centralized_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,12 @@ import (
"sync"
"time"

cid "github.com/ipfs/go-cid"
"github.com/ipfs/go-cid"
ds "github.com/ipfs/go-datastore"
dssync "github.com/ipfs/go-datastore/sync"

"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-testing/net"

offline "github.com/ipfs/go-ipfs-routing/offline"
"github.com/ipfs/go-ipfs-routing/offline"
tnet "github.com/libp2p/go-libp2p-testing/net"
"github.com/libp2p/go-libp2p/core/peer"
)

// server is the mockrouting.Client's private interface to the routing server
Expand Down
5 changes: 2 additions & 3 deletions mock/centralized_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,8 @@ import (
"github.com/ipfs/go-cid"
delay "github.com/ipfs/go-ipfs-delay"
u "github.com/ipfs/go-ipfs-util"

"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-testing/net"
tnet "github.com/libp2p/go-libp2p-testing/net"
"github.com/libp2p/go-libp2p/core/peer"
)

func TestKeyNotFound(t *testing.T) {
Expand Down
7 changes: 3 additions & 4 deletions mock/interface.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,9 @@ import (

ds "github.com/ipfs/go-datastore"
delay "github.com/ipfs/go-ipfs-delay"

"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-core/routing"
"github.com/libp2p/go-libp2p-testing/net"
tnet "github.com/libp2p/go-libp2p-testing/net"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/libp2p/go-libp2p/core/routing"
)

// MockValidator is a record validator that always returns success.
Expand Down
10 changes: 4 additions & 6 deletions none/none_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,12 @@ import (
"context"
"errors"

cid "github.com/ipfs/go-cid"
"github.com/ipfs/go-cid"
ds "github.com/ipfs/go-datastore"

"github.com/libp2p/go-libp2p-core/host"
"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-core/routing"

record "github.com/libp2p/go-libp2p-record"
"github.com/libp2p/go-libp2p/core/host"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/libp2p/go-libp2p/core/routing"
)

type nilclient struct {
Expand Down
10 changes: 4 additions & 6 deletions offline/offline.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,14 @@ import (
"errors"
"time"

proto "github.com/gogo/protobuf/proto"
cid "github.com/ipfs/go-cid"
"github.com/gogo/protobuf/proto"
"github.com/ipfs/go-cid"
ds "github.com/ipfs/go-datastore"
dshelp "github.com/ipfs/go-ipfs-ds-help"

"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-core/routing"

record "github.com/libp2p/go-libp2p-record"
pb "github.com/libp2p/go-libp2p-record/pb"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/libp2p/go-libp2p/core/routing"
)

// ErrOffline is returned when trying to perform operations that
Expand Down
4 changes: 2 additions & 2 deletions offline/offline_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (
cid "github.com/ipfs/go-cid"
ds "github.com/ipfs/go-datastore"

"github.com/libp2p/go-libp2p-core/routing"
"github.com/libp2p/go-libp2p-core/test"
"github.com/libp2p/go-libp2p/core/routing"
"github.com/libp2p/go-libp2p/core/test"

mh "github.com/multiformats/go-multihash"
)
Expand Down