From 68d536862db947899b2cd7fa6ab7ac742d743f65 Mon Sep 17 00:00:00 2001 From: "Masih H. Derkani" Date: Fri, 12 Nov 2021 11:03:15 +0000 Subject: [PATCH] Upgrade to go-data-transfer `v1.11.4` Upgrade to go-data-transfer `v1.11.4` so that it's consistent with the version used in lotus. This is to reduce the changes needed in downstream repos as part of integrating indexing into Lotus. Relates to: - https://github.com/filecoin-project/indexer-reference-provider/issues/90 - https://github.com/filecoin-project/lotus/pull/7622 --- go.mod | 6 +++--- go.sum | 13 ++++++------- legs_test.go | 4 ++-- utils.go | 4 ++-- 4 files changed, 13 insertions(+), 14 deletions(-) diff --git a/go.mod b/go.mod index 5e0328c..3daadde 100644 --- a/go.mod +++ b/go.mod @@ -3,12 +3,12 @@ module github.com/filecoin-project/go-legs go 1.16 require ( - github.com/filecoin-project/go-data-transfer v1.10.1 + github.com/filecoin-project/go-data-transfer v1.11.4 github.com/ipfs/go-cid v0.1.0 github.com/ipfs/go-datastore v0.4.6 - github.com/ipfs/go-graphsync v0.9.3 + github.com/ipfs/go-graphsync v0.10.0 github.com/ipfs/go-log/v2 v2.3.0 - github.com/ipld/go-ipld-prime v0.12.0 + github.com/ipld/go-ipld-prime v0.12.3 github.com/libp2p/go-libp2p v0.15.0 github.com/libp2p/go-libp2p-core v0.9.0 github.com/libp2p/go-libp2p-pubsub v0.5.4 diff --git a/go.sum b/go.sum index b088125..9eb952e 100644 --- a/go.sum +++ b/go.sum @@ -170,8 +170,8 @@ github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7 github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/filecoin-project/go-cbor-util v0.0.0-20191219014500-08c40a1e63a2 h1:av5fw6wmm58FYMgJeoB/lK9XXrgdugYiTqkdxjTy9k8= github.com/filecoin-project/go-cbor-util v0.0.0-20191219014500-08c40a1e63a2/go.mod h1:pqTiPHobNkOVM5thSRsHYjyQfq7O5QSCMhvuu9JoDlg= -github.com/filecoin-project/go-data-transfer v1.10.1 h1:YQNLwhizxkdfFxegAyrnn3l7WjgMjqDlqFzr18iWiYI= -github.com/filecoin-project/go-data-transfer v1.10.1/go.mod h1:CSDMCrPK2lVGodNB1wPEogjFvM9nVGyiL1GNbBRTSdw= +github.com/filecoin-project/go-data-transfer v1.11.4 h1:jKvlx0/C8HSyLRn/G1P9TjtfBtFU9jbCvCVFmWbyYVQ= +github.com/filecoin-project/go-data-transfer v1.11.4/go.mod h1:2MitLI0ebCkLlPKM7NRggP/t9d+gCcREUKkCKqWRCwU= github.com/filecoin-project/go-ds-versioning v0.1.0 h1:y/X6UksYTsK8TLCI7rttCKEvl8btmWxyFMEeeWGUxIQ= github.com/filecoin-project/go-ds-versioning v0.1.0/go.mod h1:mp16rb4i2QPmxBnmanUx8i/XANp+PFCCJWiAb+VW4/s= github.com/filecoin-project/go-statemachine v0.0.0-20200925024713-05bd7c71fbfe h1:dF8u+LEWeIcTcfUcCf3WFVlc81Fr2JKg8zPzIbBDKDw= @@ -389,9 +389,8 @@ github.com/ipfs/go-ds-badger v0.2.7/go.mod h1:02rnztVKA4aZwDuaRPTf8mpqcKmXP7mLl6 github.com/ipfs/go-ds-leveldb v0.0.1/go.mod h1:feO8V3kubwsEF22n0YRQCffeb79OOYIykR4L04tMOYc= github.com/ipfs/go-ds-leveldb v0.4.1/go.mod h1:jpbku/YqBSsBc1qgME8BkWS4AxzF2cEu1Ii2r79Hh9s= github.com/ipfs/go-ds-leveldb v0.4.2/go.mod h1:jpbku/YqBSsBc1qgME8BkWS4AxzF2cEu1Ii2r79Hh9s= -github.com/ipfs/go-graphsync v0.9.1/go.mod h1:J62ahWT9JbPsFL2UWsUM5rOu0lZJ0LOIH1chHdxGGcw= -github.com/ipfs/go-graphsync v0.9.3 h1:oWqUuN3OYqLwu669fxYbgymBrIodB0fD7vFZfF//X7Y= -github.com/ipfs/go-graphsync v0.9.3/go.mod h1:J62ahWT9JbPsFL2UWsUM5rOu0lZJ0LOIH1chHdxGGcw= +github.com/ipfs/go-graphsync v0.10.0 h1:VXljS1ETYp1GmAJ6N45hlcKO+tlvPFUzz3xzEQ0jMbM= +github.com/ipfs/go-graphsync v0.10.0/go.mod h1:cKIshzTaa5rCZjryH5xmSKZVGX9uk1wvwGvz2WEha5Y= github.com/ipfs/go-ipfs-blockstore v0.0.1/go.mod h1:d3WClOmRQKFnJ0Jz/jj/zmksX0ma1gROTlovZKBmN08= github.com/ipfs/go-ipfs-blockstore v0.1.0/go.mod h1:5aD0AvHPi7mZc6Ci1WCAhiBQu2IsfTduLl+422H6Rqw= github.com/ipfs/go-ipfs-blockstore v0.1.4/go.mod h1:Jxm3XMVjh6R17WvxFEiyKBLUGr86HgIYJW/D/MwqeYQ= @@ -464,8 +463,8 @@ github.com/ipfs/go-verifcid v0.0.1/go.mod h1:5Hrva5KBeIog4A+UpqlaIU+DEstipcJYQQZ github.com/ipld/go-codec-dagpb v1.3.0 h1:czTcaoAuNNyIYWs6Qe01DJ+sEX7B+1Z0LcXjSatMGe8= github.com/ipld/go-codec-dagpb v1.3.0/go.mod h1:ga4JTU3abYApDC3pZ00BC2RSvC3qfBb9MSJkMLSwnhA= github.com/ipld/go-ipld-prime v0.11.0/go.mod h1:+WIAkokurHmZ/KwzDOMUuoeJgaRQktHtEaLglS3ZeV8= -github.com/ipld/go-ipld-prime v0.12.0 h1:JapyKWTsJgmhrPI7hfx4V798c/RClr85sXfBZnH1VIw= -github.com/ipld/go-ipld-prime v0.12.0/go.mod h1:hy8b93WleDMRKumOJnTIrr0MbbFbx9GD6Kzxa53Xppc= +github.com/ipld/go-ipld-prime v0.12.3 h1:furVobw7UBLQZwlEwfE26tYORy3PAK8VYSgZOSr3JMQ= +github.com/ipld/go-ipld-prime v0.12.3/go.mod h1:PaeLYq8k6dJLmDUSLrzkEpoGV4PEfe/1OtFN/eALOc8= github.com/jackpal/gateway v1.0.5/go.mod h1:lTpwd4ACLXmpyiCTRtfiNyVnUmqT9RivzCDQetPfnjA= github.com/jackpal/go-nat-pmp v1.0.1/go.mod h1:QPH045xvCAeXUZOxsnwmrtiCoxIr9eob+4orBN1SBKc= github.com/jackpal/go-nat-pmp v1.0.2 h1:KzKSgb7qkJvOUTqYl9/Hg/me3pWgBmERKrTGD7BdWus= diff --git a/legs_test.go b/legs_test.go index 57e94c2..51dde2a 100644 --- a/legs_test.go +++ b/legs_test.go @@ -102,9 +102,9 @@ func TestRoundTripExistingDataTransfer(t *testing.T) { srcLnkS := test.MkLinkSystem(srcStore) gsnet := gsnet.NewFromLibp2pHost(srcHost) - gs := gsimpl.New(context.Background(), gsnet, fakeLsys) - tp := gstransport.NewTransport(srcHost.ID(), gs) dtNet := dtnetwork.NewFromLibp2pHost(srcHost) + gs := gsimpl.New(context.Background(), gsnet, fakeLsys) + tp := gstransport.NewTransport(srcHost.ID(), gs, dtNet) // DataTransfer channels use this file to track cidlist of exchanges // NOTE: It needs to be initialized for the datatransfer not to fail, but diff --git a/utils.go b/utils.go index e1f31f1..216f0cb 100644 --- a/utils.go +++ b/utils.go @@ -80,9 +80,9 @@ func makePubsub(ctx context.Context, h host.Host, topic string) (*pubsub.Topic, func makeDataTransfer(ctx context.Context, host host.Host, ds datastore.Batching, lsys ipld.LinkSystem) (dt.Manager, graphsync.GraphExchange, string, error) { gsnet := gsnet.NewFromLibp2pHost(host) - gs := gsimpl.New(context.Background(), gsnet, lsys) - tp := gstransport.NewTransport(host.ID(), gs) dtNet := dtnetwork.NewFromLibp2pHost(host) + gs := gsimpl.New(context.Background(), gsnet, lsys) + tp := gstransport.NewTransport(host.ID(), gs, dtNet) // DataTransfer channels use this file to track cidlist of exchanges // NOTE: It needs to be initialized for the datatransfer not to fail, but