Skip to content
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

release/lotus1.17.2 to main #794

Merged
merged 15 commits into from
Oct 4, 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
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ orbs:
executors:
golang:
docker:
- image: cimg/go:1.17.11
- image: cimg/go:1.18.6
resource_class: 2xlarge
ubuntu:
docker:
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/boostd
/devnet
/booster-http
/booster-bitswap
/docgen-md
/docgen-openrpc
extern/filecoin-ffi/rust/target
Expand Down
18 changes: 14 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,12 @@ booster-http: $(BUILD_DEPS)
.PHONY: booster-http
BINS+=booster-http

booster-bitswap: $(BUILD_DEPS)
rm -f booster-bitswap
$(GOCC) build $(GOFLAGS) -o booster-bitswap ./cmd/booster-bitswap
.PHONY: booster-bitswap
BINS+=booster-bitswap

devnet: $(BUILD_DEPS)
rm -f devnet
$(GOCC) build $(GOFLAGS) -o devnet ./cmd/devnet
Expand Down Expand Up @@ -194,9 +200,9 @@ docsgen-openrpc-boost: docsgen-openrpc-bin

## DOCKER IMAGES
docker_user?=filecoin
lotus_version?=1.17.1-rc2
lotus_version?=1.17.2-rc2
lotus_src_dir?=

ifeq ($(lotus_src_dir),)
lotus_src_dir=/tmp/lotus-$(lotus_version)
lotus_checkout_dir=$(lotus_src_dir)
Expand All @@ -211,7 +217,7 @@ docker_build_cmd=docker build --build-arg LOTUS_TEST_IMAGE=$(lotus_test_image) $
info/lotus-test:
@echo Lotus dir = $(lotus_src_dir)
@echo Lotus ver = $(lotus_version)
.PHONY: info/lotus-test
.PHONY: info/lotus-test
$(lotus_checkout_dir):
git clone --depth 1 --branch v$(lotus_version) https://github.com/filecoin-project/lotus $@
docker/lotus-test: info/lotus-test | $(lotus_checkout_dir)
Expand All @@ -228,9 +234,13 @@ docker/boost: build/.update-modules
-t $(docker_user)/boost-dev:dev --build-arg BUILD_VERSION=dev \
-f docker/devnet/boost/Dockerfile.source .
.PHONY: docker/boost
docker/booster-http:
docker/booster-http:
$(docker_build_cmd) -t $(docker_user)/booster-http-dev:dev --build-arg BUILD_VERSION=dev \
-f docker/devnet/booster-http/Dockerfile.source .
.PHONY: docker/booster-http
docker/booster-bitswap:
$(docker_build_cmd) -t $(docker_user)/booster-bitswap-dev:dev --build-arg BUILD_VERSION=dev \
-f docker/devnet/booster-bitswap/Dockerfile.source .
.PHONY: docker/booster-bitswap
docker/all: docker/lotus-test docker/boost docker/booster-http docker/lotus docker/lotus-miner
.PHONY: docker/all
7 changes: 6 additions & 1 deletion api/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
"github.com/filecoin-project/lotus/chain/types"
"github.com/google/uuid"
"github.com/ipfs/go-cid"
"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/multiformats/go-multihash"
)

Expand Down Expand Up @@ -48,6 +48,11 @@ type Boost interface {
BoostDagstorePiecesContainingMultihash(ctx context.Context, mh multihash.Multihash) ([]cid.Cid, error) //perm:read
BoostDagstoreListShards(ctx context.Context) ([]DagstoreShardInfo, error) //perm:read

// MethodGroup: Blockstore
BlockstoreGet(ctx context.Context, c cid.Cid) ([]byte, error) //perm:read
BlockstoreHas(ctx context.Context, c cid.Cid) (bool, error) //perm:read
BlockstoreGetSize(ctx context.Context, c cid.Cid) (int, error) //perm:read

// RuntimeSubsystems returns the subsystems that are enabled
// in this instance.
RuntimeSubsystems(ctx context.Context) (lapi.MinerSubsystems, error) //perm:read
Expand Down
12 changes: 7 additions & 5 deletions api/docgen/docgen.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ import (
"github.com/google/uuid"
"github.com/ipfs/go-cid"
"github.com/ipfs/go-graphsync"
"github.com/libp2p/go-libp2p-core/metrics"
"github.com/libp2p/go-libp2p-core/network"
"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-core/protocol"
pubsub "github.com/libp2p/go-libp2p-pubsub"
"github.com/libp2p/go-libp2p/core/metrics"
"github.com/libp2p/go-libp2p/core/network"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/libp2p/go-libp2p/core/protocol"
"github.com/multiformats/go-multiaddr"

datatransfer "github.com/filecoin-project/go-data-transfer"
Expand All @@ -45,6 +45,8 @@ import (
"github.com/filecoin-project/lotus/node/repo/imports"
"github.com/filecoin-project/lotus/storage/sealer/sealtasks"
"github.com/filecoin-project/lotus/storage/sealer/storiface"
"golang.org/x/text/cases"
"golang.org/x/text/language"
)

var ExampleValues = map[reflect.Type]interface{}{
Expand Down Expand Up @@ -372,7 +374,7 @@ func exampleStruct(method string, t, parent reflect.Type) interface{} {
if f.Type == parent {
continue
}
if strings.Title(f.Name) == f.Name {
if cases.Title(language.Und, cases.NoLower).String(f.Name) == f.Name {
ns.Elem().Field(i).Set(reflect.ValueOf(ExampleValue(method, f.Type, t)))
}
}
Expand Down
8 changes: 4 additions & 4 deletions api/net.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ import (

lotus_api "github.com/filecoin-project/lotus/api"
lotus_net "github.com/filecoin-project/lotus/node/impl/net"
metrics "github.com/libp2p/go-libp2p-core/metrics"
"github.com/libp2p/go-libp2p-core/network"
"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-core/protocol"
metrics "github.com/libp2p/go-libp2p/core/metrics"
"github.com/libp2p/go-libp2p/core/network"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/libp2p/go-libp2p/core/protocol"
)

// MODIFYING THE API INTERFACE
Expand Down
47 changes: 43 additions & 4 deletions api/proxy_gen.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ import (
"github.com/filecoin-project/go-state-types/abi"
"github.com/ipfs/go-cid"

"github.com/libp2p/go-libp2p-core/peer"
pubsub "github.com/libp2p/go-libp2p-pubsub"
"github.com/libp2p/go-libp2p/core/peer"
ma "github.com/multiformats/go-multiaddr"
)

Expand Down
Binary file modified build/openrpc/boost.json.gz
Binary file not shown.
2 changes: 1 addition & 1 deletion build/params_shared_funcs.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"github.com/filecoin-project/go-address"
"github.com/ipfs/go-cid"

"github.com/libp2p/go-libp2p-core/protocol"
"github.com/libp2p/go-libp2p/core/protocol"

"github.com/filecoin-project/boost/node/modules/dtypes"
)
Expand Down
4 changes: 2 additions & 2 deletions cli/node/node.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ import (
"github.com/filecoin-project/lotus/chain/types"
"github.com/filecoin-project/lotus/chain/wallet"
"github.com/libp2p/go-libp2p"
"github.com/libp2p/go-libp2p-core/crypto"
"github.com/libp2p/go-libp2p-core/host"
"github.com/libp2p/go-libp2p/core/crypto"
"github.com/libp2p/go-libp2p/core/host"
"github.com/mitchellh/go-homedir"
)

Expand Down
6 changes: 3 additions & 3 deletions client/deal.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ import (
"github.com/filecoin-project/lotus/api/v1api"
"github.com/google/uuid"
"github.com/libp2p/go-libp2p"
"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-core/peerstore"
"github.com/libp2p/go-libp2p-peerstore/pstoremem"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/libp2p/go-libp2p/core/peerstore"
"github.com/libp2p/go-libp2p/p2p/host/peerstore/pstoremem"
)

// StorageClient starts storage deals with Boost over libp2p
Expand Down
2 changes: 1 addition & 1 deletion cmd/boost/deal_cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (
lcli "github.com/filecoin-project/lotus/cli"
"github.com/google/uuid"
"github.com/ipfs/go-cid"
inet "github.com/libp2p/go-libp2p-core/network"
inet "github.com/libp2p/go-libp2p/core/network"
"github.com/urfave/cli/v2"
)

Expand Down
2 changes: 1 addition & 1 deletion cmd/boostd/legacy_data_transfers.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
bcli "github.com/filecoin-project/boost/cli"
datatransfer "github.com/filecoin-project/go-data-transfer"
lcli "github.com/filecoin-project/lotus/cli"
"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/urfave/cli/v2"
)

Expand Down
Loading