diff --git a/.circleci/config.yml b/.circleci/config.yml index 0c4f29c87..d88bbc9be 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -93,10 +93,10 @@ jobs: - store_artifacts: path: lotus - store_artifacts: - path: lotus-storage-miner + path: lotus-miner - store_artifacts: - path: lotus-seal-worker - - run: mkdir linux && mv lotus lotus-storage-miner lotus-seal-worker linux/ + path: lotus-worker + - run: mkdir linux && mv lotus lotus-miner lotus-worker linux/ - persist_to_workspace: root: "." paths: @@ -223,10 +223,10 @@ jobs: - store_artifacts: path: lotus - store_artifacts: - path: lotus-storage-miner + path: lotus-miner - store_artifacts: - path: lotus-seal-worker - - run: mkdir darwin && mv lotus lotus-storage-miner lotus-seal-worker darwin/ + path: lotus-worker + - run: mkdir darwin && mv lotus lotus-miner lotus-worker darwin/ - persist_to_workspace: root: "." paths: diff --git a/.github/ISSUE_TEMPLATE/sealingfailed.md b/.github/ISSUE_TEMPLATE/sealingfailed.md index d58664415..2084b8dd4 100644 --- a/.github/ISSUE_TEMPLATE/sealingfailed.md +++ b/.github/ISSUE_TEMPLATE/sealingfailed.md @@ -19,15 +19,15 @@ Including what commands you ran, and a description of your setup, is very helpfu **Sectors list** -The output of `./lotus-storage-miner sectors list`. +The output of `./lotus-miner sectors list`. **Sectors status** -The output of `./lotus-storage-miner sectors status --log ` for the failed sector(s). +The output of `./lotus-miner sectors status --log ` for the failed sector(s). -**Lotus storage miner logs** +**Lotus miner logs** -Please go through the logs of your storage miner, and include screenshots of any error-like messages you find. +Please go through the logs of your miner, and include screenshots of any error-like messages you find. **Version** diff --git a/.gitignore b/.gitignore index fce23289f..0424c1f24 100644 --- a/.gitignore +++ b/.gitignore @@ -1,19 +1,21 @@ /lotus -/lotus-storage-miner -/lotus-seal-worker +/lotus-miner +/lotus-worker /lotus-seed /lotus-health +/lotus-chainwatch /lotus-shed -/pond -/townhall -/fountain -/stats -/bench +/lotus-pond +/lotus-townhall +/lotus-fountain +/lotus-stats +/lotus-bench /bench.json /lotuspond/front/node_modules /lotuspond/front/build /cmd/lotus-townhall/townhall/node_modules /cmd/lotus-townhall/townhall/build +/cmd/lotus-townhall/townhall/package-lock.json extern/filecoin-ffi/rust/target **/*.a **/*.pc @@ -24,7 +26,6 @@ build/paramfetch.sh /vendor /blocks.dot /blocks.svg -/chainwatch /chainwatch.db /bundle /darwin diff --git a/Makefile b/Makefile index 4533cc4dc..a1b6a0b93 100644 --- a/Makefile +++ b/Makefile @@ -58,10 +58,10 @@ deps: $(BUILD_DEPS) .PHONY: deps debug: GOFLAGS+=-tags=debug -debug: lotus lotus-storage-miner lotus-seal-worker lotus-seed +debug: lotus lotus-miner lotus-worker lotus-seed 2k: GOFLAGS+=-tags=2k -2k: lotus lotus-storage-miner lotus-seal-worker lotus-seed +2k: lotus lotus-miner lotus-worker lotus-seed lotus: $(BUILD_DEPS) rm -f lotus @@ -71,19 +71,19 @@ lotus: $(BUILD_DEPS) .PHONY: lotus BINS+=lotus -lotus-storage-miner: $(BUILD_DEPS) - rm -f lotus-storage-miner - go build $(GOFLAGS) -o lotus-storage-miner ./cmd/lotus-storage-miner - go run github.com/GeertJohan/go.rice/rice append --exec lotus-storage-miner -i ./build -.PHONY: lotus-storage-miner -BINS+=lotus-storage-miner +lotus-miner: $(BUILD_DEPS) + rm -f lotus-miner + go build $(GOFLAGS) -o lotus-miner ./cmd/lotus-storage-miner + go run github.com/GeertJohan/go.rice/rice append --exec lotus-miner -i ./build +.PHONY: lotus-miner +BINS+=lotus-miner -lotus-seal-worker: $(BUILD_DEPS) - rm -f lotus-seal-worker - go build $(GOFLAGS) -o lotus-seal-worker ./cmd/lotus-seal-worker - go run github.com/GeertJohan/go.rice/rice append --exec lotus-seal-worker -i ./build -.PHONY: lotus-seal-worker -BINS+=lotus-seal-worker +lotus-worker: $(BUILD_DEPS) + rm -f lotus-worker + go build $(GOFLAGS) -o lotus-worker ./cmd/lotus-seal-worker + go run github.com/GeertJohan/go.rice/rice append --exec lotus-worker -i ./build +.PHONY: lotus-worker +BINS+=lotus-worker lotus-shed: $(BUILD_DEPS) rm -f lotus-shed @@ -92,7 +92,7 @@ lotus-shed: $(BUILD_DEPS) .PHONY: lotus-shed BINS+=lotus-shed -build: lotus lotus-storage-miner lotus-seal-worker +build: lotus lotus-miner lotus-worker @[[ $$(type -P "lotus") ]] && echo "Caution: you have \ an existing lotus binary in your PATH. This may cause problems if you don't run 'sudo make install'" || true @@ -100,8 +100,8 @@ an existing lotus binary in your PATH. This may cause problems if you don't run install: install -C ./lotus /usr/local/bin/lotus - install -C ./lotus-storage-miner /usr/local/bin/lotus-storage-miner - install -C ./lotus-seal-worker /usr/local/bin/lotus-seal-worker + install -C ./lotus-miner /usr/local/bin/lotus-miner + install -C ./lotus-worker /usr/local/bin/lotus-worker install-services: install mkdir -p /usr/local/lib/systemd/system @@ -115,7 +115,7 @@ install-services: install clean-services: rm -f /usr/local/lib/systemd/system/lotus-daemon.service rm -f /usr/local/lib/systemd/system/lotus-miner.service - rm -f /usr/local/lib/systemd/system/chainwatch.service + rm -f /usr/local/lib/systemd/system/lotus-chainwatch.service systemctl daemon-reload # TOOLS @@ -134,66 +134,65 @@ benchmarks: @curl -X POST 'http://benchmark.kittyhawk.wtf/benchmark' -d '@bench.json' -u "${benchmark_http_cred}" .PHONY: benchmarks -pond: 2k - go build -o pond ./lotuspond +lotus-pond: 2k + go build -o lotus-pond ./lotuspond (cd lotuspond/front && npm i && CI=false npm run build) -.PHONY: pond -BINS+=pond +.PHONY: lotus-pond +BINS+=lotus-pond -townhall: - rm -f townhall - go build -o townhall ./cmd/lotus-townhall +lotus-townhall: + rm -f lotus-townhall + go build -o lotus-townhall ./cmd/lotus-townhall (cd ./cmd/lotus-townhall/townhall && npm i && npm run build) - go run github.com/GeertJohan/go.rice/rice append --exec townhall -i ./cmd/lotus-townhall -i ./build -.PHONY: townhall -BINS+=townhall + go run github.com/GeertJohan/go.rice/rice append --exec lotus-townhall -i ./cmd/lotus-townhall -i ./build +.PHONY: lotus-townhall +BINS+=lotus-townhall -fountain: - rm -f fountain - go build -o fountain ./cmd/lotus-fountain - go run github.com/GeertJohan/go.rice/rice append --exec fountain -i ./cmd/lotus-fountain -i ./build -.PHONY: fountain -BINS+=fountain +lotus-fountain: + rm -f lotus-fountain + go build -o lotus-fountain ./cmd/lotus-fountain + go run github.com/GeertJohan/go.rice/rice append --exec lotus-fountain -i ./cmd/lotus-fountain -i ./build +.PHONY: lotus-fountain +BINS+=lotus-fountain -chainwatch: - rm -f chainwatch - go build -o chainwatch ./cmd/lotus-chainwatch - go run github.com/GeertJohan/go.rice/rice append --exec chainwatch -i ./cmd/lotus-chainwatch -i ./build -.PHONY: chainwatch -BINS+=chainwatch +lotus-chainwatch: + rm -f lotus-chainwatch + go build -o lotus-chainwatch ./cmd/lotus-chainwatch + go run github.com/GeertJohan/go.rice/rice append --exec lotus-chainwatch -i ./cmd/lotus-chainwatch -i ./build +.PHONY: lotus-chainwatch +BINS+=lotus-chainwatch install-chainwatch-service: chainwatch - install -C ./chainwatch /usr/local/bin/chainwatch - install -C -m 0644 ./scripts/chainwatch.service /usr/local/lib/systemd/system/chainwatch.service + mkdir -p /etc/lotus + install -C ./lotus-chainwatch /usr/local/bin/lotus-chainwatch + install -C -m 0644 ./scripts/lotus-chainwatch.service /usr/local/lib/systemd/system/lotus-chainwatch.service systemctl daemon-reload @echo @echo "chainwatch installed. Don't forget to 'systemctl enable chainwatch' for it to be enabled on startup." -bench: - rm -f bench - go build -o bench ./cmd/lotus-bench - go run github.com/GeertJohan/go.rice/rice append --exec bench -i ./build -.PHONY: bench -BINS+=bench +lotus-bench: + rm -f lotus-bench + go build -o lotus-bench ./cmd/lotus-bench + go run github.com/GeertJohan/go.rice/rice append --exec lotus-bench -i ./build +.PHONY: lotus-bench +BINS+=lotus-bench -stats: - rm -f stats - go build -o stats ./tools/stats - go run github.com/GeertJohan/go.rice/rice append --exec stats -i ./build -.PHONY: stats -BINS+=stats +lotus-stats: + rm -f lotus-stats + go build -o lotus-stats ./cmd/lotus-stats + go run github.com/GeertJohan/go.rice/rice append --exec lotus-stats -i ./build +.PHONY: lotus-stats +BINS+=lotus-stats -health: +lotus-health: rm -f lotus-health go build -o lotus-health ./cmd/lotus-health go run github.com/GeertJohan/go.rice/rice append --exec lotus-health -i ./build - -.PHONY: health -BINS+=health +.PHONY: lotus-health +BINS+=lotus-health testground: go build -tags testground -o /dev/null ./cmd/lotus - .PHONY: testground BINS+=testground @@ -203,15 +202,15 @@ buildall: $(BINS) completions: ./scripts/make-completions.sh lotus - ./scripts/make-completions.sh lotus-storage-miner + ./scripts/make-completions.sh lotus-miner .PHONY: completions install-completions: mkdir -p /usr/share/bash-completion/completions /usr/local/share/zsh/site-functions/ install -C ./scripts/bash-completion/lotus /usr/share/bash-completion/completions/lotus - install -C ./scripts/bash-completion/lotus-storage-miner /usr/share/bash-completion/completions/lotus-storage-miner + install -C ./scripts/bash-completion/lotus-miner /usr/share/bash-completion/completions/lotus-miner install -C ./scripts/zsh-completion/lotus /usr/local/share/zsh/site-functions/_lotus - install -C ./scripts/zsh-completion/lotus-storage-miner /usr/local/share/zsh/site-functions/_lotus-storage-miner + install -C ./scripts/zsh-completion/lotus-miner /usr/local/share/zsh/site-functions/_lotus-miner clean: rm -rf $(CLEAN) $(BINS) diff --git a/api/api_full.go b/api/api_full.go index 6f9f10e39..e63d1592e 100644 --- a/api/api_full.go +++ b/api/api_full.go @@ -52,7 +52,7 @@ type FullNode interface { // the specified block. ChainGetParentReceipts(ctx context.Context, blockCid cid.Cid) ([]*types.MessageReceipt, error) - // ChainGetParentReceipts returns messages stored in parent tipset of the + // ChainGetParentMessages returns messages stored in parent tipset of the // specified block. ChainGetParentMessages(ctx context.Context, blockCid cid.Cid) ([]Message, error) @@ -319,7 +319,7 @@ type FullNode interface { // MsigGetAvailableBalance returns the portion of a multisig's balance that can be withdrawn or spent MsigGetAvailableBalance(context.Context, address.Address, types.TipSetKey) (types.BigInt, error) - // MsigGetAvailableBalance creates a multisig wallet + // MsigCreate creates a multisig wallet // It takes the following params: , , //, , MsigCreate(context.Context, uint64, []address.Address, abi.ChainEpoch, types.BigInt, address.Address, types.BigInt) (cid.Cid, error) diff --git a/api/api_storage.go b/api/api_storage.go index 6402de2b6..321380157 100644 --- a/api/api_storage.go +++ b/api/api_storage.go @@ -46,6 +46,10 @@ type StorageMiner interface { // SectorGetSealDelay gets the time that a newly-created sector // waits for more deals before it starts sealing SectorGetSealDelay(context.Context) (time.Duration, error) + // SectorSetExpectedSealDuration sets the expected time for a sector to seal + SectorSetExpectedSealDuration(context.Context, time.Duration) error + // SectorGetExpectedSealDuration gets the expected time for a sector to seal + SectorGetExpectedSealDuration(context.Context) (time.Duration, error) SectorsUpdate(context.Context, abi.SectorNumber, SectorState) error SectorRemove(context.Context, abi.SectorNumber) error SectorMarkForUpgrade(ctx context.Context, id abi.SectorNumber) error diff --git a/api/apistruct/struct.go b/api/apistruct/struct.go index 54722198c..043bb6986 100644 --- a/api/apistruct/struct.go +++ b/api/apistruct/struct.go @@ -209,15 +209,17 @@ type StorageMinerStruct struct { PledgeSector func(context.Context) error `perm:"write"` - SectorsStatus func(context.Context, abi.SectorNumber) (api.SectorInfo, error) `perm:"read"` - SectorsList func(context.Context) ([]abi.SectorNumber, error) `perm:"read"` - SectorsRefs func(context.Context) (map[string][]api.SealedRef, error) `perm:"read"` - SectorStartSealing func(context.Context, abi.SectorNumber) error `perm:"write"` - SectorSetSealDelay func(context.Context, time.Duration) error `perm:"write"` - SectorGetSealDelay func(context.Context) (time.Duration, error) `perm:"read"` - SectorsUpdate func(context.Context, abi.SectorNumber, api.SectorState) error `perm:"admin"` - SectorRemove func(context.Context, abi.SectorNumber) error `perm:"admin"` - SectorMarkForUpgrade func(ctx context.Context, id abi.SectorNumber) error `perm:"admin"` + SectorsStatus func(context.Context, abi.SectorNumber) (api.SectorInfo, error) `perm:"read"` + SectorsList func(context.Context) ([]abi.SectorNumber, error) `perm:"read"` + SectorsRefs func(context.Context) (map[string][]api.SealedRef, error) `perm:"read"` + SectorStartSealing func(context.Context, abi.SectorNumber) error `perm:"write"` + SectorSetSealDelay func(context.Context, time.Duration) error `perm:"write"` + SectorGetSealDelay func(context.Context) (time.Duration, error) `perm:"read"` + SectorSetExpectedSealDuration func(context.Context, time.Duration) error `perm:"write"` + SectorGetExpectedSealDuration func(context.Context) (time.Duration, error) `perm:"read"` + SectorsUpdate func(context.Context, abi.SectorNumber, api.SectorState) error `perm:"admin"` + SectorRemove func(context.Context, abi.SectorNumber) error `perm:"admin"` + SectorMarkForUpgrade func(ctx context.Context, id abi.SectorNumber) error `perm:"admin"` WorkerConnect func(context.Context, string) error `perm:"admin"` // TODO: worker perm WorkerStats func(context.Context) (map[uint64]storiface.WorkerStats, error) `perm:"admin"` @@ -835,6 +837,14 @@ func (c *StorageMinerStruct) SectorGetSealDelay(ctx context.Context) (time.Durat return c.Internal.SectorGetSealDelay(ctx) } +func (c *StorageMinerStruct) SectorSetExpectedSealDuration(ctx context.Context, delay time.Duration) error { + return c.Internal.SectorSetExpectedSealDuration(ctx, delay) +} + +func (c *StorageMinerStruct) SectorGetExpectedSealDuration(ctx context.Context) (time.Duration, error) { + return c.Internal.SectorGetExpectedSealDuration(ctx) +} + func (c *StorageMinerStruct) SectorsUpdate(ctx context.Context, id abi.SectorNumber, state api.SectorState) error { return c.Internal.SectorsUpdate(ctx, id, state) } diff --git a/api/client/client.go b/api/client/client.go index 20bad2048..4029838fa 100644 --- a/api/client/client.go +++ b/api/client/client.go @@ -34,7 +34,7 @@ func NewFullNodeRPC(addr string, requestHeader http.Header) (api.FullNode, jsonr return &res, closer, err } -// NewStorageMinerRPC creates a new http jsonrpc client for storage miner +// NewStorageMinerRPC creates a new http jsonrpc client for miner func NewStorageMinerRPC(addr string, requestHeader http.Header) (api.StorageMiner, jsonrpc.ClientCloser, error) { var res apistruct.StorageMinerStruct closer, err := jsonrpc.NewMergeClient(addr, "Filecoin", diff --git a/api/test/mining.go b/api/test/mining.go index d2b56758e..dcbd59dd1 100644 --- a/api/test/mining.go +++ b/api/test/mining.go @@ -89,7 +89,7 @@ func TestDealMining(t *testing.T, b APIBuilder, blocktime time.Duration, carExpo ctx := context.Background() n, sn := b(t, 1, []StorageMiner{ {Full: 0, Preseal: PresealGenesis}, - {Full: 0, Preseal: 0}, // TODO: Add support for storage miners on non-first full node + {Full: 0, Preseal: 0}, // TODO: Add support for miners on non-first full node }) client := n[0].FullNode.(*impl.FullNodeAPI) provider := sn[1] diff --git a/api/test/window_post.go b/api/test/window_post.go index dcf6fcebd..874bcadcf 100644 --- a/api/test/window_post.go +++ b/api/test/window_post.go @@ -4,6 +4,8 @@ import ( "context" "fmt" "github.com/filecoin-project/lotus/api" + "github.com/filecoin-project/lotus/build" + "os" "strings" "testing" @@ -35,14 +37,14 @@ func TestPledgeSector(t *testing.T, b APIBuilder, blocktime time.Duration, nSect if err := miner.NetConnect(ctx, addrinfo); err != nil { t.Fatal(err) } - time.Sleep(time.Second) + build.Clock.Sleep(time.Second) mine := true done := make(chan struct{}) go func() { defer close(done) for mine { - time.Sleep(blocktime) + build.Clock.Sleep(blocktime) if err := sn[0].MineOne(ctx, func(bool, error) {}); err != nil { t.Error(err) } @@ -69,7 +71,7 @@ func pledgeSectors(t *testing.T, ctx context.Context, miner TestStorageNode, n i break } - time.Sleep(100 * time.Millisecond) + build.Clock.Sleep(100 * time.Millisecond) } fmt.Printf("All sectors is fsm\n") @@ -94,7 +96,7 @@ func pledgeSectors(t *testing.T, ctx context.Context, miner TestStorageNode, n i } } - time.Sleep(100 * time.Millisecond) + build.Clock.Sleep(100 * time.Millisecond) fmt.Printf("WaitSeal: %d\n", len(s)) } } @@ -115,14 +117,14 @@ func TestWindowPost(t *testing.T, b APIBuilder, blocktime time.Duration, nSector if err := miner.NetConnect(ctx, addrinfo); err != nil { t.Fatal(err) } - time.Sleep(time.Second) + build.Clock.Sleep(time.Second) mine := true done := make(chan struct{}) go func() { defer close(done) for mine { - time.Sleep(blocktime) + build.Clock.Sleep(blocktime) if err := sn[0].MineOne(ctx, func(bool, error) {}); err != nil { t.Error(err) } @@ -150,7 +152,7 @@ func TestWindowPost(t *testing.T, b APIBuilder, blocktime time.Duration, nSector if head.Height()%100 == 0 { fmt.Printf("@%d\n", head.Height()) } - time.Sleep(blocktime) + build.Clock.Sleep(blocktime) } p, err := client.StateMinerPower(ctx, maddr, types.EmptyTSK) diff --git a/build/bootstrap.go b/build/bootstrap.go index 6343a0172..750ed3a17 100644 --- a/build/bootstrap.go +++ b/build/bootstrap.go @@ -41,9 +41,8 @@ func BuiltinBootstrap() ([]peer.AddrInfo, error) { func DrandBootstrap() ([]peer.AddrInfo, error) { addrs := []string{ - "/dnsaddr/pl-eu.testnet.drand.sh/", - "/dnsaddr/pl-us.testnet.drand.sh/", - "/dnsaddr/pl-sin.testnet.drand.sh/", + "/dnsaddr/dev1.drand.sh/", + "/dnsaddr/dev2.drand.sh/", } return addrutil.ParseAddresses(context.TODO(), addrs) } diff --git a/build/clock.go b/build/clock.go new file mode 100644 index 000000000..5b1726720 --- /dev/null +++ b/build/clock.go @@ -0,0 +1,10 @@ +package build + +import "github.com/raulk/clock" + +// Clock is the global clock for the system. In standard builds, +// we use a real-time clock, which maps to the `time` package. +// +// Tests that need control of time can replace this variable with +// clock.NewMock(). +var Clock = clock.New() diff --git a/build/params_shared_vals.go b/build/params_shared_vals.go index 1a1f2bfb4..e770f8c69 100644 --- a/build/params_shared_vals.go +++ b/build/params_shared_vals.go @@ -91,13 +91,12 @@ const VerifSigCacheSize = 32000 // TODO: If this is gonna stay, it should move to specs-actors const BlockMessageLimit = 512 -const BlockGasLimit = 100_000_000_000 +const BlockGasLimit = 7_500_000_000 var DrandConfig = dtypes.DrandConfig{ Servers: []string{ - "https://pl-eu.testnet.drand.sh", - "https://pl-us.testnet.drand.sh", - "https://pl-sin.testnet.drand.sh", + "https://dev1.drand.sh", + "https://dev1.drand.sh", }, - ChainInfoJSON: `{"public_key":"922a2e93828ff83345bae533f5172669a26c02dc76d6bf59c80892e12ab1455c229211886f35bb56af6d5bea981024df","period":25,"genesis_time":1590445175,"hash":"138a324aa6540f93d0dad002aa89454b1bec2b6e948682cde6bd4db40f4b7c9b"}`, + ChainInfoJSON: `{"public_key":"88fdb6f22fcbe671bf91befbf723e159e5934f785168b437c03424cde6361cff5f5d3034390260f210438946f21d867d","period":30,"genesis_time":1589461830,"hash":"e89c9efe5af86ac79fc5d1c0ee0aaa64a81a97bb55d0acc4d2497cc2a0087afe","groupHash":"8f16f0105250b51f34e41fb845d09668b2e3db008dacb3c2d461f0bb2349b854"}`, } diff --git a/chain/beacon/beacon.go b/chain/beacon/beacon.go index 2be2e7f1c..7b998c04f 100644 --- a/chain/beacon/beacon.go +++ b/chain/beacon/beacon.go @@ -2,12 +2,13 @@ package beacon import ( "context" - "time" - "github.com/filecoin-project/lotus/chain/types" "github.com/filecoin-project/specs-actors/actors/abi" logging "github.com/ipfs/go-log" "golang.org/x/xerrors" + + "github.com/filecoin-project/lotus/build" + "github.com/filecoin-project/lotus/chain/types" ) var log = logging.Logger("beacon") @@ -52,7 +53,7 @@ func ValidateBlockValues(b RandomBeacon, h *types.BlockHeader, prevEntry types.B } func BeaconEntriesForBlock(ctx context.Context, beacon RandomBeacon, round abi.ChainEpoch, prev types.BeaconEntry) ([]types.BeaconEntry, error) { - start := time.Now() + start := build.Clock.Now() maxRound := beacon.MaxBeaconRoundForEpoch(round, prev) if maxRound == prev.Round { @@ -81,7 +82,7 @@ func BeaconEntriesForBlock(ctx context.Context, beacon RandomBeacon, round abi.C } } - log.Debugw("fetching beacon entries", "took", time.Since(start), "numEntries", len(out)) + log.Debugw("fetching beacon entries", "took", build.Clock.Since(start), "numEntries", len(out)) reverse(out) return out, nil } diff --git a/chain/beacon/drand/drand.go b/chain/beacon/drand/drand.go index 00ff05f81..1b036bbf0 100644 --- a/chain/beacon/drand/drand.go +++ b/chain/beacon/drand/drand.go @@ -21,6 +21,7 @@ import ( "github.com/filecoin-project/specs-actors/actors/abi" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/beacon" "github.com/filecoin-project/lotus/chain/types" "github.com/filecoin-project/lotus/node/modules/dtypes" @@ -131,7 +132,7 @@ func (db *DrandBeacon) Entry(ctx context.Context, round uint64) <-chan beacon.Re } go func() { - start := time.Now() + start := build.Clock.Now() log.Infow("start fetching randomness", "round", round) resp, err := db.client.Get(ctx, round) @@ -142,7 +143,7 @@ func (db *DrandBeacon) Entry(ctx context.Context, round uint64) <-chan beacon.Re br.Entry.Round = resp.Round() br.Entry.Data = resp.Signature() } - log.Infow("done fetching randomness", "round", round, "took", time.Since(start)) + log.Infow("done fetching randomness", "round", round, "took", build.Clock.Since(start)) out <- br close(out) }() diff --git a/chain/block_receipt_tracker.go b/chain/block_receipt_tracker.go index f182fd180..466adef9d 100644 --- a/chain/block_receipt_tracker.go +++ b/chain/block_receipt_tracker.go @@ -5,6 +5,7 @@ import ( "sync" "time" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/types" "github.com/hashicorp/golang-lru" peer "github.com/libp2p/go-libp2p-core/peer" @@ -37,14 +38,14 @@ func (brt *blockReceiptTracker) Add(p peer.ID, ts *types.TipSet) { if !ok { pset := &peerSet{ peers: map[peer.ID]time.Time{ - p: time.Now(), + p: build.Clock.Now(), }, } brt.cache.Add(ts.Key(), pset) return } - val.(*peerSet).peers[p] = time.Now() + val.(*peerSet).peers[p] = build.Clock.Now() } func (brt *blockReceiptTracker) GetPeers(ts *types.TipSet) []peer.ID { diff --git a/chain/blocksync/blocksync.go b/chain/blocksync/blocksync.go index a9251c419..f5483eeae 100644 --- a/chain/blocksync/blocksync.go +++ b/chain/blocksync/blocksync.go @@ -126,7 +126,7 @@ func (bss *BlockSyncService) HandleStream(s inet.Stream) { } writeDeadline := 60 * time.Second - _ = s.SetDeadline(time.Now().Add(writeDeadline)) + _ = s.SetDeadline(time.Now().Add(writeDeadline)) // always use real time for socket/stream deadlines. if err := cborutil.WriteCborRPC(s, resp); err != nil { log.Warnw("failed to write back response for handle stream", "err", err, "peer", s.Conn().RemotePeer()) return diff --git a/chain/blocksync/blocksync_client.go b/chain/blocksync/blocksync_client.go index daa4b6335..67e4fde8f 100644 --- a/chain/blocksync/blocksync_client.go +++ b/chain/blocksync/blocksync_client.go @@ -21,6 +21,7 @@ import ( "golang.org/x/xerrors" cborutil "github.com/filecoin-project/go-cbor-util" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/store" "github.com/filecoin-project/lotus/chain/types" incrt "github.com/filecoin-project/lotus/lib/increadtimeout" @@ -91,7 +92,7 @@ func (bs *BlockSync) GetBlocks(ctx context.Context, tsk types.TipSetKey, count i // randomize the first few peers so we don't always pick the same peer shufflePrefix(peers) - start := time.Now() + start := build.Clock.Now() var oerr error for _, p := range peers { @@ -117,7 +118,7 @@ func (bs *BlockSync) GetBlocks(ctx context.Context, tsk types.TipSetKey, count i if err != nil { return nil, xerrors.Errorf("success response from peer failed to process: %w", err) } - bs.syncPeers.logGlobalSuccess(time.Since(start)) + bs.syncPeers.logGlobalSuccess(build.Clock.Since(start)) bs.host.ConnManager().TagPeer(p, "bsync", 25) return resp, nil } @@ -197,7 +198,7 @@ func (bs *BlockSync) GetChainMessages(ctx context.Context, h *types.TipSet, coun } var err error - start := time.Now() + start := build.Clock.Now() for _, p := range peers { res, rerr := bs.sendRequestToPeer(ctx, p, req) @@ -208,7 +209,7 @@ func (bs *BlockSync) GetChainMessages(ctx context.Context, h *types.TipSet, coun } if res.Status == StatusOK { - bs.syncPeers.logGlobalSuccess(time.Since(start)) + bs.syncPeers.logGlobalSuccess(build.Clock.Since(start)) return res.Chain, nil } @@ -284,17 +285,17 @@ func (bs *BlockSync) fetchBlocksBlockSync(ctx context.Context, p peer.ID, req *B ctx, span := trace.StartSpan(ctx, "blockSyncFetch") defer span.End() - start := time.Now() + start := build.Clock.Now() s, err := bs.host.NewStream(inet.WithNoDial(ctx, "should already have connection"), p, BlockSyncProtocolID) if err != nil { bs.RemovePeer(p) return nil, xerrors.Errorf("failed to open stream to peer: %w", err) } - _ = s.SetWriteDeadline(time.Now().Add(5 * time.Second)) + _ = s.SetWriteDeadline(time.Now().Add(5 * time.Second)) // always use real time for socket/stream deadlines. if err := cborutil.WriteCborRPC(s, req); err != nil { _ = s.SetWriteDeadline(time.Time{}) - bs.syncPeers.logFailure(p, time.Since(start)) + bs.syncPeers.logFailure(p, build.Clock.Since(start)) return nil, err } _ = s.SetWriteDeadline(time.Time{}) @@ -302,7 +303,7 @@ func (bs *BlockSync) fetchBlocksBlockSync(ctx context.Context, p peer.ID, req *B var res BlockSyncResponse r := incrt.New(s, 50<<10, 5*time.Second) if err := cborutil.ReadCborRPC(bufio.NewReader(r), &res); err != nil { - bs.syncPeers.logFailure(p, time.Since(start)) + bs.syncPeers.logFailure(p, build.Clock.Since(start)) return nil, err } @@ -314,7 +315,7 @@ func (bs *BlockSync) fetchBlocksBlockSync(ctx context.Context, p peer.ID, req *B ) } - bs.syncPeers.logSuccess(p, time.Since(start)) + bs.syncPeers.logSuccess(p, build.Clock.Since(start)) return &res, nil } @@ -475,7 +476,7 @@ func (bpt *bsPeerTracker) addPeer(p peer.ID) { return } bpt.peers[p] = &peerStats{ - firstSeen: time.Now(), + firstSeen: build.Clock.Now(), } } diff --git a/chain/events/events.go b/chain/events/events.go index e11507795..4550fc98a 100644 --- a/chain/events/events.go +++ b/chain/events/events.go @@ -99,7 +99,7 @@ func (e *Events) listenHeadChanges(ctx context.Context) { log.Warnf("not restarting listenHeadChanges: context error: %s", ctx.Err()) return } - time.Sleep(time.Second) + build.Clock.Sleep(time.Second) log.Info("restarting listenHeadChanges") } } diff --git a/chain/gen/gen.go b/chain/gen/gen.go index cd7c2b05e..db2fc0389 100644 --- a/chain/gen/gen.go +++ b/chain/gen/gen.go @@ -9,7 +9,6 @@ import ( "time" "github.com/filecoin-project/go-address" - commcid "github.com/filecoin-project/go-fil-commcid" "github.com/filecoin-project/specs-actors/actors/abi" saminer "github.com/filecoin-project/specs-actors/actors/builtin/miner" "github.com/filecoin-project/specs-actors/actors/crypto" @@ -196,7 +195,7 @@ func NewGeneratorWithSectors(numSectors int) (*ChainGen, error) { *genm2, }, NetworkName: "", - Timestamp: uint64(time.Now().Add(-500 * time.Duration(build.BlockDelaySecs) * time.Second).Unix()), + Timestamp: uint64(build.Clock.Now().Add(-500 * time.Duration(build.BlockDelaySecs) * time.Second).Unix()), } genb, err := genesis2.MakeGenesisBlock(context.TODO(), bs, sys, tpl) @@ -284,7 +283,7 @@ func (cg *ChainGen) GenesisCar() ([]byte, error) { func CarWalkFunc(nd format.Node) (out []*format.Link, err error) { for _, link := range nd.Links() { - if link.Cid.Prefix().MhType == uint64(commcid.FC_SEALED_V1) || link.Cid.Prefix().MhType == uint64(commcid.FC_UNSEALED_V1) { + if link.Cid.Prefix().Codec == cid.FilCommitmentSealed || link.Cid.Prefix().Codec == cid.FilCommitmentUnsealed { continue } out = append(out, link) @@ -472,7 +471,7 @@ func getRandomMessages(cg *ChainGen) ([]*types.SignedMessage, error) { Method: 0, - GasLimit: 10000, + GasLimit: 100_000_000, GasPrice: types.NewInt(0), } diff --git a/chain/gen/genesis/genesis.go b/chain/gen/genesis/genesis.go index d70d6f854..b2c687f62 100644 --- a/chain/gen/genesis/genesis.go +++ b/chain/gen/genesis/genesis.go @@ -317,7 +317,7 @@ func MakeGenesisBlock(ctx context.Context, bs bstore.Blockstore, sys runtime.Sys stateroot, err = SetupStorageMiners(ctx, cs, stateroot, template.Miners) if err != nil { - return nil, xerrors.Errorf("setup storage miners failed: %w", err) + return nil, xerrors.Errorf("setup miners failed: %w", err) } cst := cbor.NewCborStore(bs) diff --git a/chain/market/fundmgr.go b/chain/market/fundmgr.go index 42ad50b2b..1bafda3c9 100644 --- a/chain/market/fundmgr.go +++ b/chain/market/fundmgr.go @@ -70,7 +70,7 @@ func (fm *FundMgr) EnsureAvailable(ctx context.Context, addr, wallet address.Add From: wallet, Value: toAdd, GasPrice: types.NewInt(0), - GasLimit: 1000000, + GasLimit: 100_000_000, Method: builtin.MethodsMarket.AddBalance, Params: params, }) diff --git a/chain/messagepool/messagepool.go b/chain/messagepool/messagepool.go index 545af6c39..7b2f19bbd 100644 --- a/chain/messagepool/messagepool.go +++ b/chain/messagepool/messagepool.go @@ -23,12 +23,15 @@ import ( "golang.org/x/xerrors" "github.com/filecoin-project/go-address" + "github.com/filecoin-project/lotus/api" "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/stmgr" "github.com/filecoin-project/lotus/chain/types" "github.com/filecoin-project/lotus/lib/sigs" "github.com/filecoin-project/lotus/node/modules/dtypes" + + "github.com/raulk/clock" ) var log = logging.Logger("messagepool") @@ -66,7 +69,7 @@ type MessagePool struct { lk sync.Mutex closer chan struct{} - repubTk *time.Ticker + repubTk *clock.Ticker localAddrs map[address.Address]struct{} @@ -188,7 +191,7 @@ func New(api Provider, ds dtypes.MetadataDS, netName dtypes.NetworkName) (*Messa mp := &MessagePool{ closer: make(chan struct{}), - repubTk: time.NewTicker(time.Duration(build.BlockDelaySecs) * 10 * time.Second), + repubTk: build.Clock.Ticker(time.Duration(build.BlockDelaySecs) * 10 * time.Second), localAddrs: make(map[address.Address]struct{}), pending: make(map[address.Address]*msgSet), minGasPrice: types.NewInt(0), diff --git a/chain/metrics/consensus.go b/chain/metrics/consensus.go index bc7e019d2..7d19d5bd6 100644 --- a/chain/metrics/consensus.go +++ b/chain/metrics/consensus.go @@ -3,7 +3,6 @@ package metrics import ( "context" "encoding/json" - "time" "github.com/filecoin-project/specs-actors/actors/abi" "github.com/ipfs/go-cid" @@ -11,6 +10,7 @@ import ( pubsub "github.com/libp2p/go-libp2p-pubsub" "go.uber.org/fx" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/types" "github.com/filecoin-project/lotus/node/impl/full" "github.com/filecoin-project/lotus/node/modules/helpers" @@ -89,7 +89,7 @@ func sendHeadNotifs(ctx context.Context, ps *pubsub.PubSub, topic string, chain } // using unix nano time makes very sure we pick a nonce higher than previous restart - nonce := uint64(time.Now().UnixNano()) + nonce := uint64(build.Clock.Now().UnixNano()) for { select { @@ -107,7 +107,7 @@ func sendHeadNotifs(ctx context.Context, ps *pubsub.PubSub, topic string, chain Height: n.Val.Height(), Weight: w, NodeName: nickname, - Time: uint64(time.Now().UnixNano() / 1000_000), + Time: uint64(build.Clock.Now().UnixNano() / 1000_000), Nonce: nonce, } diff --git a/chain/stmgr/forks_test.go b/chain/stmgr/forks_test.go index 2fbcbbc99..c84b0b7b9 100644 --- a/chain/stmgr/forks_test.go +++ b/chain/stmgr/forks_test.go @@ -179,7 +179,7 @@ func TestForkHeightTriggers(t *testing.T) { To: builtin.InitActorAddr, Method: builtin.MethodsInit.Exec, Params: enc, - GasLimit: 10000, + GasLimit: 100_000_000, GasPrice: types.NewInt(0), } sig, err := cg.Wallet().Sign(ctx, cg.Banker(), m.Cid().Bytes()) @@ -206,7 +206,7 @@ func TestForkHeightTriggers(t *testing.T) { Method: 2, Params: nil, Nonce: nonce, - GasLimit: 10000, + GasLimit: 100_000_000, GasPrice: types.NewInt(0), } nonce++ diff --git a/chain/sub/incoming.go b/chain/sub/incoming.go index 9dfc2d894..0db132562 100644 --- a/chain/sub/incoming.go +++ b/chain/sub/incoming.go @@ -61,7 +61,7 @@ func HandleIncomingBlocks(ctx context.Context, bsub *pubsub.Subscription, s *cha src := msg.GetFrom() go func() { - start := time.Now() + start := build.Clock.Now() log.Debug("about to fetch messages for block from pubsub") bmsgs, err := s.Bsync.FetchMessagesByCids(context.TODO(), blk.BlsMessages) if err != nil { @@ -75,9 +75,9 @@ func HandleIncomingBlocks(ctx context.Context, bsub *pubsub.Subscription, s *cha return } - took := time.Since(start) + took := build.Clock.Since(start) log.Infow("new block over pubsub", "cid", blk.Header.Cid(), "source", msg.GetFrom(), "msgfetch", took) - if delay := time.Now().Unix() - int64(blk.Header.Timestamp); delay > 5 { + if delay := build.Clock.Now().Unix() - int64(blk.Header.Timestamp); delay > 5 { log.Warnf("Received block with large delay %d from miner %s", delay, blk.Header.Miner) } @@ -142,9 +142,9 @@ func (bv *BlockValidator) flagPeer(p peer.ID) { func (bv *BlockValidator) Validate(ctx context.Context, pid peer.ID, msg *pubsub.Message) pubsub.ValidationResult { // track validation time - begin := time.Now() + begin := build.Clock.Now() defer func() { - log.Debugf("block validation time: %s", time.Since(begin)) + log.Debugf("block validation time: %s", build.Clock.Since(begin)) }() stats.Record(ctx, metrics.BlockReceived.M(1)) @@ -233,7 +233,7 @@ func (bv *BlockValidator) Validate(ctx context.Context, pid peer.ID, msg *pubsub func (bv *BlockValidator) isChainNearSynced() bool { ts := bv.chain.GetHeaviestTipSet() timestamp := ts.MinTimestamp() - now := time.Now().UnixNano() + now := build.Clock.Now().UnixNano() cutoff := uint64(now) - uint64(6*time.Hour) return timestamp > cutoff } diff --git a/chain/sync.go b/chain/sync.go index a00767b73..1ed7a3507 100644 --- a/chain/sync.go +++ b/chain/sync.go @@ -620,7 +620,7 @@ func (syncer *Syncer) ValidateBlock(ctx context.Context, b *types.FullBlock) (er return nil } - validationStart := time.Now() + validationStart := build.Clock.Now() defer func() { dur := time.Since(validationStart) durMilli := dur.Seconds() * float64(1000) @@ -632,7 +632,7 @@ func (syncer *Syncer) ValidateBlock(ctx context.Context, b *types.FullBlock) (er defer span.End() if build.InsecurePoStValidation { - log.Warn("insecure test validation is enabled, if you see this outside of a test, it is a severe bug!") + log.Warn("[INSECURE-POST-VALIDATION] if you see this outside of a test, it is a severe bug!") } if err := blockSanityChecks(b.Header); err != nil { @@ -665,12 +665,12 @@ func (syncer *Syncer) ValidateBlock(ctx context.Context, b *types.FullBlock) (er // fast checks first - now := uint64(time.Now().Unix()) + now := uint64(build.Clock.Now().Unix()) if h.Timestamp > now+build.AllowableClockDriftSecs { return xerrors.Errorf("block was from the future (now=%d, blk=%d): %w", now, h.Timestamp, ErrTemporal) } if h.Timestamp > now { - log.Warn("Got block from the future, but within threshold", h.Timestamp, time.Now().Unix()) + log.Warn("Got block from the future, but within threshold", h.Timestamp, build.Clock.Now().Unix()) } if h.Timestamp < baseTs.MinTimestamp()+(build.BlockDelaySecs*uint64(h.Height-baseTs.Height())) { @@ -863,13 +863,13 @@ func (syncer *Syncer) ValidateBlock(ctx context.Context, b *types.FullBlock) (er func (syncer *Syncer) VerifyWinningPoStProof(ctx context.Context, h *types.BlockHeader, prevBeacon types.BeaconEntry, lbst cid.Cid, waddr address.Address) error { if build.InsecurePoStValidation { if len(h.WinPoStProof) == 0 { - return xerrors.Errorf("[TESTING] No winning post proof given") + return xerrors.Errorf("[INSECURE-POST-VALIDATION] No winning post proof given") } if string(h.WinPoStProof[0].ProofBytes) == "valid proof" { return nil } - return xerrors.Errorf("[TESTING] winning post was invalid") + return xerrors.Errorf("[INSECURE-POST-VALIDATION] winning post was invalid") } buf := new(bytes.Buffer) @@ -950,15 +950,24 @@ func (syncer *Syncer) checkBlockMessages(ctx context.Context, b *types.FullBlock return xerrors.Errorf("failed to load base state tree: %w", err) } + pl := vm.PricelistByEpoch(baseTs.Height()) + var sumGasLimit int64 checkMsg := func(msg types.ChainMsg) error { m := msg.VMMessage() // Phase 1: syntactic validation, as defined in the spec - minGas := vm.PricelistByEpoch(baseTs.Height()).OnChainMessage(msg.ChainLength()) + minGas := pl.OnChainMessage(msg.ChainLength()) if err := m.ValidForBlockInclusion(minGas.Total()); err != nil { return err } + // ValidForBlockInclusion checks if any single message does not exceed BlockGasLimit + // So below is overflow safe + sumGasLimit += m.GasLimit + if sumGasLimit > build.BlockGasLimit { + return xerrors.Errorf("block gas limit exceeded") + } + // Phase 2: (Partial) semantic validation: // the sender exists and is an account actor, and the nonces make sense if _, ok := nonces[m.From]; !ok { @@ -1535,6 +1544,6 @@ func (syncer *Syncer) IsEpochBeyondCurrMax(epoch abi.ChainEpoch) bool { return false } - now := uint64(time.Now().Unix()) + now := uint64(build.Clock.Now().Unix()) return epoch > (abi.ChainEpoch((now-g.Timestamp)/build.BlockDelaySecs) + MaxHeightDrift) } diff --git a/chain/syncstate.go b/chain/syncstate.go index b213c7483..aaca88303 100644 --- a/chain/syncstate.go +++ b/chain/syncstate.go @@ -8,6 +8,7 @@ import ( "github.com/filecoin-project/specs-actors/actors/abi" "github.com/filecoin-project/lotus/api" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/types" ) @@ -48,7 +49,7 @@ func (ss *SyncerState) SetStage(v api.SyncStateStage) { defer ss.lk.Unlock() ss.Stage = v if v == api.StageSyncComplete { - ss.End = time.Now() + ss.End = build.Clock.Now() } } @@ -64,7 +65,7 @@ func (ss *SyncerState) Init(base, target *types.TipSet) { ss.Stage = api.StageHeaders ss.Height = 0 ss.Message = "" - ss.Start = time.Now() + ss.Start = build.Clock.Now() ss.End = time.Time{} } @@ -87,7 +88,7 @@ func (ss *SyncerState) Error(err error) { defer ss.lk.Unlock() ss.Message = err.Error() ss.Stage = api.StageSyncErrored - ss.End = time.Now() + ss.End = build.Clock.Now() } func (ss *SyncerState) Snapshot() SyncerState { diff --git a/chain/types/tipset.go b/chain/types/tipset.go index 09483dc5e..57ab91787 100644 --- a/chain/types/tipset.go +++ b/chain/types/tipset.go @@ -112,6 +112,10 @@ func NewTipSet(blks []*BlockHeader) (*TipSet, error) { return nil, fmt.Errorf("cannot create tipset with mismatching heights") } + if len(blks[0].Parents) != len(b.Parents) { + return nil, fmt.Errorf("cannot create tipset with mismatching number of parents") + } + for i, cid := range b.Parents { if cid != blks[0].Parents[i] { return nil, fmt.Errorf("cannot create tipset with mismatching parents") diff --git a/chain/types_test.go b/chain/types_test.go index 55baf4a28..3b49a8d94 100644 --- a/chain/types_test.go +++ b/chain/types_test.go @@ -19,7 +19,7 @@ func TestSignedMessageJsonRoundtrip(t *testing.T) { Method: 1235126, Value: types.NewInt(123123), GasPrice: types.NewInt(1234), - GasLimit: 9992969384, + GasLimit: 100_000_000, Nonce: 123123, }, } diff --git a/chain/vm/gas.go b/chain/vm/gas.go index bee65fd8f..81a5fc8e3 100644 --- a/chain/vm/gas.go +++ b/chain/vm/gas.go @@ -65,7 +65,7 @@ type Pricelist interface { OnMethodInvocation(value abi.TokenAmount, methodNum abi.MethodNum) GasCharge // OnIpldGet returns the gas used for storing an object - OnIpldGet(dataSize int) GasCharge + OnIpldGet() GasCharge // OnIpldPut returns the gas used for storing an object OnIpldPut(dataSize int) GasCharge @@ -84,30 +84,35 @@ type Pricelist interface { var prices = map[abi.ChainEpoch]Pricelist{ abi.ChainEpoch(0): &pricelistV0{ - onChainMessageBase: 0, - onChainMessagePerByte: 2, - onChainReturnValuePerByte: 8, - sendBase: 5, - sendTransferFunds: 5, - sendInvokeMethod: 10, - ipldGetBase: 10, - ipldGetPerByte: 1, - ipldPutBase: 20, - ipldPutPerByte: 2, - createActorBase: 40, // IPLD put + 20 - createActorExtra: 500, - deleteActor: -500, // -createActorExtra - // Dragons: this cost is not persistable, create a LinearCost{a,b} struct that has a `.Cost(x) -> ax + b` - verifySignature: map[crypto.SigType]func(int64) int64{ - crypto.SigTypeBLS: func(x int64) int64 { return 3*x + 2 }, - crypto.SigTypeSecp256k1: func(x int64) int64 { return 3*x + 2 }, + onChainMessageComputeBase: 137137, + onChainMessageStorageBase: 0, // TODO gas + onChainMessageStoragePerByte: 2, // TODO gas + + onChainReturnValuePerByte: 8, // TODO gas + + sendBase: 97236, + sendTransferFunds: 96812, + sendTransferOnlyPremium: 347806, + sendInvokeMethod: -3110, + + ipldGetBase: 417230, + ipldPutBase: 396100, + ipldPutPerByte: 2, // TODO gas + + createActorCompute: 750011, + createActorStorage: 500, // TODO gas + deleteActor: -500, // -createActorStorage + + verifySignature: map[crypto.SigType]int64{ + crypto.SigTypeBLS: 219946580, + crypto.SigTypeSecp256k1: 6726720, }, - hashingBase: 5, - hashingPerByte: 2, - computeUnsealedSectorCidBase: 100, - verifySealBase: 2000, - verifyPostBase: 700, - verifyConsensusFault: 10, + + hashingBase: 110685, + computeUnsealedSectorCidBase: 431890, + verifySealBase: 2000, // TODO gas , it VerifySeal syscall is not used + verifyPostBase: 2621447835, + verifyConsensusFault: 495422, }, } @@ -198,14 +203,14 @@ func (ps pricedSyscalls) VerifyConsensusFault(h1 []byte, h2 []byte, extra []byte } func (ps pricedSyscalls) BatchVerifySeals(inp map[address.Address][]abi.SealVerifyInfo) (map[address.Address][]bool, error) { - var gasChargeSum GasCharge - gasChargeSum.Name = "BatchVerifySeals" count := int64(0) for _, svis := range inp { count += int64(len(svis)) } - gasChargeSum = gasChargeSum.WithExtra(count).WithVirtual(129778623*count+716683250, 0) - ps.chargeGas(gasChargeSum) // TODO: this is only called by the cron actor. Should we even charge gas? + + gasChargeSum := newGasCharge("BatchVerifySeals", 0, 0) + gasChargeSum = gasChargeSum.WithExtra(count).WithVirtual(15075005*count+899741502, 0) + ps.chargeGas(gasChargeSum) // real gas charged by actors defer ps.chargeGas(gasOnActorExec) return ps.under.BatchVerifySeals(inp) diff --git a/chain/vm/gas_v0.go b/chain/vm/gas_v0.go index 5735d0b83..068726d74 100644 --- a/chain/vm/gas_v0.go +++ b/chain/vm/gas_v0.go @@ -20,8 +20,9 @@ type pricelistV0 struct { // Together, these account for the cost of message propagation and validation, // up to but excluding any actual processing by the VM. // This is the cost a block producer burns when including an invalid message. - onChainMessageBase int64 - onChainMessagePerByte int64 + onChainMessageComputeBase int64 + onChainMessageStorageBase int64 + onChainMessageStoragePerByte int64 // Gas cost charged to the originator of a non-nil return value produced // by an on-chain message is given by: @@ -41,15 +42,17 @@ type pricelistV0 struct { // already accounted for). sendTransferFunds int64 + // Gsa cost charged, in addition to SendBase, if message only transfers funds. + sendTransferOnlyPremium int64 + // Gas cost charged, in addition to SendBase, if a message invokes // a method on the receiver. // Accounts for the cost of loading receiver code and method dispatch. sendInvokeMethod int64 - // Gas cost (Base + len*PerByte) for any Get operation to the IPLD store + // Gas cost for any Get operation to the IPLD store // in the runtime VM context. - ipldGetBase int64 - ipldGetPerByte int64 + ipldGetBase int64 // Gas cost (Base + len*PerByte) for any Put operation to the IPLD store // in the runtime VM context. @@ -64,18 +67,17 @@ type pricelistV0 struct { // // Note: this costs assume that the extra will be partially or totally refunded while // the base is covering for the put. - createActorBase int64 - createActorExtra int64 + createActorCompute int64 + createActorStorage int64 // Gas cost for deleting an actor. // // Note: this partially refunds the create cost to incentivise the deletion of the actors. deleteActor int64 - verifySignature map[crypto.SigType]func(len int64) int64 + verifySignature map[crypto.SigType]int64 - hashingBase int64 - hashingPerByte int64 + hashingBase int64 computeUnsealedSectorCidBase int64 verifySealBase int64 @@ -87,57 +89,51 @@ var _ Pricelist = (*pricelistV0)(nil) // OnChainMessage returns the gas used for storing a message of a given size in the chain. func (pl *pricelistV0) OnChainMessage(msgSize int) GasCharge { - return newGasCharge("OnChainMessage", 0, pl.onChainMessageBase+pl.onChainMessagePerByte*int64(msgSize)).WithVirtual(77302, 0) + return newGasCharge("OnChainMessage", pl.onChainMessageComputeBase, + pl.onChainMessageStorageBase+pl.onChainMessageStoragePerByte*int64(msgSize)) } // OnChainReturnValue returns the gas used for storing the response of a message in the chain. func (pl *pricelistV0) OnChainReturnValue(dataSize int) GasCharge { - return newGasCharge("OnChainReturnValue", 0, int64(dataSize)*pl.onChainReturnValuePerByte).WithVirtual(107294, 0) + return newGasCharge("OnChainReturnValue", 0, int64(dataSize)*pl.onChainReturnValuePerByte) } // OnMethodInvocation returns the gas used when invoking a method. func (pl *pricelistV0) OnMethodInvocation(value abi.TokenAmount, methodNum abi.MethodNum) GasCharge { ret := pl.sendBase extra := "" - virtGas := int64(1072944) - if value != abi.NewTokenAmount(0) { - // TODO: fix this, it is comparing pointers instead of values - // see vv - ret += pl.sendTransferFunds - } if big.Cmp(value, abi.NewTokenAmount(0)) != 0 { - virtGas += 497495 + ret += pl.sendTransferFunds if methodNum == builtin.MethodSend { // transfer only - virtGas += 973940 + ret += pl.sendTransferOnlyPremium } extra += "t" } + if methodNum != builtin.MethodSend { - ret += pl.sendInvokeMethod extra += "i" // running actors is cheaper becase we hand over to actors - virtGas += -295779 + ret += pl.sendInvokeMethod } - return newGasCharge("OnMethodInvocation", ret, 0).WithVirtual(virtGas, 0).WithExtra(extra) + return newGasCharge("OnMethodInvocation", ret, 0).WithExtra(extra) } // OnIpldGet returns the gas used for storing an object -func (pl *pricelistV0) OnIpldGet(dataSize int) GasCharge { - return newGasCharge("OnIpldGet", pl.ipldGetBase+int64(dataSize)*pl.ipldGetPerByte, 0). - WithExtra(dataSize).WithVirtual(433685, 0) +func (pl *pricelistV0) OnIpldGet() GasCharge { + return newGasCharge("OnIpldGet", pl.ipldGetBase, 0) } // OnIpldPut returns the gas used for storing an object func (pl *pricelistV0) OnIpldPut(dataSize int) GasCharge { return newGasCharge("OnIpldPut", pl.ipldPutBase, int64(dataSize)*pl.ipldPutPerByte). - WithExtra(dataSize).WithVirtual(88970, 0) + WithExtra(dataSize) } // OnCreateActor returns the gas used for creating an actor func (pl *pricelistV0) OnCreateActor() GasCharge { - return newGasCharge("OnCreateActor", pl.createActorBase, pl.createActorExtra).WithVirtual(65636, 0) + return newGasCharge("OnCreateActor", pl.createActorCompute, pl.createActorStorage) } // OnDeleteActor returns the gas used for deleting an actor @@ -148,50 +144,42 @@ func (pl *pricelistV0) OnDeleteActor() GasCharge { // OnVerifySignature func (pl *pricelistV0) OnVerifySignature(sigType crypto.SigType, planTextSize int) (GasCharge, error) { - costFn, ok := pl.verifySignature[sigType] + cost, ok := pl.verifySignature[sigType] if !ok { return GasCharge{}, fmt.Errorf("cost function for signature type %d not supported", sigType) } - sigName, _ := sigType.Name() - virtGas := int64(0) - switch sigType { - case crypto.SigTypeBLS: - virtGas = 220138570 - case crypto.SigTypeSecp256k1: - virtGas = 7053730 - } - return newGasCharge("OnVerifySignature", costFn(int64(planTextSize)), 0). + sigName, _ := sigType.Name() + return newGasCharge("OnVerifySignature", cost, 0). WithExtra(map[string]interface{}{ "type": sigName, "size": planTextSize, - }).WithVirtual(virtGas, 0), nil + }), nil } // OnHashing func (pl *pricelistV0) OnHashing(dataSize int) GasCharge { - return newGasCharge("OnHashing", pl.hashingBase+int64(dataSize)*pl.hashingPerByte, 0).WithExtra(dataSize).WithVirtual(77300, 0) + return newGasCharge("OnHashing", pl.hashingBase, 0).WithExtra(dataSize) } // OnComputeUnsealedSectorCid func (pl *pricelistV0) OnComputeUnsealedSectorCid(proofType abi.RegisteredSealProof, pieces []abi.PieceInfo) GasCharge { - // TODO: this needs more cost tunning, check with @lotus - return newGasCharge("OnComputeUnsealedSectorCid", pl.computeUnsealedSectorCidBase, 0).WithVirtual(382370, 0) + return newGasCharge("OnComputeUnsealedSectorCid", pl.computeUnsealedSectorCidBase, 0) } // OnVerifySeal func (pl *pricelistV0) OnVerifySeal(info abi.SealVerifyInfo) GasCharge { // TODO: this needs more cost tunning, check with @lotus - return newGasCharge("OnVerifySeal", pl.verifySealBase, 0).WithVirtual(199954003, 0) + // this is not used + return newGasCharge("OnVerifySeal", pl.verifySealBase, 0) } // OnVerifyPost func (pl *pricelistV0) OnVerifyPost(info abi.WindowPoStVerifyInfo) GasCharge { - // TODO: this needs more cost tunning, check with @lotus - return newGasCharge("OnVerifyPost", pl.verifyPostBase, 0).WithVirtual(2629471704, 0).WithExtra(len(info.ChallengedSectors)) + return newGasCharge("OnVerifyPost", pl.verifyPostBase, 0).WithExtra(len(info.ChallengedSectors)) } // OnVerifyConsensusFault func (pl *pricelistV0) OnVerifyConsensusFault() GasCharge { - return newGasCharge("OnVerifyConsensusFault", pl.verifyConsensusFault, 0).WithVirtual(551935, 0) + return newGasCharge("OnVerifyConsensusFault", pl.verifyConsensusFault, 0) } diff --git a/chain/vm/mkactor.go b/chain/vm/mkactor.go index 1a3fd97de..ef4382df1 100644 --- a/chain/vm/mkactor.go +++ b/chain/vm/mkactor.go @@ -30,6 +30,10 @@ var EmptyObjectCid cid.Cid // TryCreateAccountActor creates account actors from only BLS/SECP256K1 addresses. func TryCreateAccountActor(rt *Runtime, addr address.Address) (*types.Actor, aerrors.ActorError) { + if err := rt.chargeGasSafe(PricelistByEpoch(rt.height).OnCreateActor()); err != nil { + return nil, err + } + addrID, err := rt.state.RegisterNewAddress(addr) if err != nil { return nil, aerrors.Escalate(err, "registering actor address") @@ -50,10 +54,6 @@ func TryCreateAccountActor(rt *Runtime, addr address.Address) (*types.Actor, aer } // call constructor on account - if err := rt.chargeGasSafe(PricelistByEpoch(rt.height).OnCreateActor()); err != nil { - return nil, err - } - _, aerr = rt.internalSend(builtin.SystemActorAddr, addrID, builtin.MethodsAccount.Constructor, big.Zero(), p) if aerr != nil { return nil, aerrors.Wrap(aerr, "failed to invoke account constructor") diff --git a/chain/vm/runtime.go b/chain/vm/runtime.go index 62e4d6904..9e64275e3 100644 --- a/chain/vm/runtime.go +++ b/chain/vm/runtime.go @@ -373,8 +373,7 @@ func (rt *Runtime) Send(to address.Address, method abi.MethodNum, m vmr.CBORMars } func (rt *Runtime) internalSend(from, to address.Address, method abi.MethodNum, value types.BigInt, params []byte) ([]byte, aerrors.ActorError) { - - start := time.Now() + start := build.Clock.Now() ctx, span := trace.StartSpan(rt.ctx, "vmc.Send") defer span.End() if span.IsRecordingEvents() { @@ -528,7 +527,7 @@ func (rt *Runtime) chargeGasInternal(gas GasCharge, skip int) aerrors.ActorError var callers [10]uintptr cout := gruntime.Callers(2+skip, callers[:]) - now := time.Now() + now := build.Clock.Now() if rt.lastGasCharge != nil { rt.lastGasCharge.TimeTaken = now.Sub(rt.lastGasChargeTime) } diff --git a/chain/vm/vm.go b/chain/vm/vm.go index 9b83ce259..6bf1c6831 100644 --- a/chain/vm/vm.go +++ b/chain/vm/vm.go @@ -20,7 +20,6 @@ import ( "golang.org/x/xerrors" "github.com/filecoin-project/go-address" - commcid "github.com/filecoin-project/go-fil-commcid" "github.com/filecoin-project/specs-actors/actors/abi" "github.com/filecoin-project/specs-actors/actors/builtin/account" init_ "github.com/filecoin-project/specs-actors/actors/builtin/init" @@ -28,6 +27,7 @@ import ( "github.com/filecoin-project/specs-actors/actors/runtime" "github.com/filecoin-project/specs-actors/actors/runtime/exitcode" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/actors/aerrors" "github.com/filecoin-project/lotus/chain/state" "github.com/filecoin-project/lotus/chain/types" @@ -70,12 +70,12 @@ type gasChargingBlocks struct { } func (bs *gasChargingBlocks) Get(c cid.Cid) (block.Block, error) { - bs.chargeGas(newGasCharge("OnIpldGetStart", 0, 0)) + bs.chargeGas(bs.pricelist.OnIpldGet()) blk, err := bs.under.Get(c) if err != nil { return nil, aerrors.Escalate(err, "failed to get block from blockstore") } - bs.chargeGas(bs.pricelist.OnIpldGet(len(blk.RawData()))) + bs.chargeGas(newGasCharge("OnIpldGetEnd", 0, 0).WithExtra(len(blk.RawData()))) bs.chargeGas(gasOnActorExec) return blk, nil @@ -210,7 +210,6 @@ func (vm *VM) send(ctx context.Context, msg *types.Message, parent *Runtime, parent.lastGasCharge = rt.lastGasCharge }() } - if gasCharge != nil { if err := rt.chargeGasSafe(*gasCharge); err != nil { // this should never happen @@ -219,10 +218,7 @@ func (vm *VM) send(ctx context.Context, msg *types.Message, parent *Runtime, } ret, err := func() ([]byte, aerrors.ActorError) { - if aerr := rt.chargeGasSafe(rt.Pricelist().OnMethodInvocation(msg.Value, msg.Method)); aerr != nil { - return nil, aerrors.Wrap(aerr, "not enough gas for method invocation") - } - + _ = rt.chargeGasSafe(newGasCharge("OnGetActor", 0, 0)) toActor, err := st.GetActor(msg.To) if err != nil { if xerrors.Is(err, init_.ErrAddressNotFound) { @@ -236,6 +232,11 @@ func (vm *VM) send(ctx context.Context, msg *types.Message, parent *Runtime, } } + if aerr := rt.chargeGasSafe(rt.Pricelist().OnMethodInvocation(msg.Value, msg.Method)); aerr != nil { + return nil, aerrors.Wrap(aerr, "not enough gas for method invocation") + } + defer rt.chargeGasSafe(newGasCharge("OnMethodInvocationDone", 0, 0)) + if types.BigCmp(msg.Value, types.NewInt(0)) != 0 { if err := vm.transfer(msg.From, msg.To, msg.Value); err != nil { return nil, aerrors.Wrap(err, "failed to transfer funds") @@ -246,7 +247,6 @@ func (vm *VM) send(ctx context.Context, msg *types.Message, parent *Runtime, var ret []byte _ = rt.chargeGasSafe(gasOnActorExec) ret, err := vm.Invoke(toActor, rt, msg.Method, msg.Params) - _ = rt.chargeGasSafe(newGasCharge("OnActorExecDone", 0, 0)) return ret, err } return nil, nil @@ -286,7 +286,7 @@ func checkMessage(msg *types.Message) error { } func (vm *VM) ApplyImplicitMessage(ctx context.Context, msg *types.Message) (*ApplyRet, error) { - start := time.Now() + start := build.Clock.Now() ret, actorErr, rt := vm.send(ctx, msg, nil, nil, start) rt.finilizeGasTracing() return &ApplyRet{ @@ -303,7 +303,7 @@ func (vm *VM) ApplyImplicitMessage(ctx context.Context, msg *types.Message) (*Ap } func (vm *VM) ApplyMessage(ctx context.Context, cmsg types.ChainMsg) (*ApplyRet, error) { - start := time.Now() + start := build.Clock.Now() ctx, span := trace.StartSpan(ctx, "vm.ApplyMessage") defer span.End() msg := cmsg.VMMessage() @@ -440,6 +440,9 @@ func (vm *VM) ApplyMessage(ctx context.Context, cmsg types.ChainMsg) (*ApplyRet, return nil, xerrors.Errorf("revert state failed: %w", err) } } + + rt.finilizeGasTracing() + gasUsed = rt.gasUsed if gasUsed < 0 { gasUsed = 0 @@ -459,8 +462,6 @@ func (vm *VM) ApplyMessage(ctx context.Context, cmsg types.ChainMsg) (*ApplyRet, return nil, xerrors.Errorf("gas handling math is wrong") } - rt.finilizeGasTracing() - return &ApplyRet{ MessageReceipt: types.MessageReceipt{ ExitCode: errcode, @@ -590,7 +591,7 @@ func copyRec(from, to blockstore.Blockstore, root cid.Cid, cp func(block.Block) return } - if link.Prefix().MhType == mh.IDENTITY || link.Prefix().MhType == uint64(commcid.FC_SEALED_V1) || link.Prefix().MhType == uint64(commcid.FC_UNSEALED_V1) { + if link.Prefix().MhType == mh.IDENTITY || link.Prefix().Codec == cid.FilCommitmentSealed || link.Prefix().Codec == cid.FilCommitmentUnsealed { return } diff --git a/cli/auth.go b/cli/auth.go index d59ac37a5..21bdb54b7 100644 --- a/cli/auth.go +++ b/cli/auth.go @@ -2,6 +2,7 @@ package cli import ( "fmt" + "os" "github.com/urfave/cli/v2" "golang.org/x/xerrors" @@ -126,6 +127,9 @@ var authApiInfoToken = &cli.Command{ } envVar := envForRepo(t) + if _, ok := os.LookupEnv(envForRepo(t)); !ok { + envVar = envForRepoDeprecation(t) + } // TODO: Log in audit log when it is implemented diff --git a/cli/chain.go b/cli/chain.go index c2acee5e5..69f3d7413 100644 --- a/cli/chain.go +++ b/cli/chain.go @@ -935,7 +935,7 @@ var slashConsensusFault = &cli.Command{ From: def, Value: types.NewInt(0), GasPrice: types.NewInt(1), - GasLimit: 10000000, + GasLimit: 100_000_000, Method: builtin.MethodsMiner.ReportConsensusFault, Params: enc, } diff --git a/cli/cmd.go b/cli/cmd.go index 83a1845fc..69194b0d6 100644 --- a/cli/cmd.go +++ b/cli/cmd.go @@ -72,13 +72,25 @@ func flagForRepo(t repo.RepoType) string { case repo.FullNode: return "repo" case repo.StorageMiner: - return "storagerepo" + return "miner-repo" default: panic(fmt.Sprintf("Unknown repo type: %v", t)) } } func envForRepo(t repo.RepoType) string { + switch t { + case repo.FullNode: + return "FULLNODE_API_INFO" + case repo.StorageMiner: + return "MINER_API_INFO" + default: + panic(fmt.Sprintf("Unknown repo type: %v", t)) + } +} + +// TODO remove after deprecation period +func envForRepoDeprecation(t repo.RepoType) string { switch t { case repo.FullNode: return "FULLNODE_API_INFO" @@ -90,14 +102,24 @@ func envForRepo(t repo.RepoType) string { } func GetAPIInfo(ctx *cli.Context, t repo.RepoType) (APIInfo, error) { - if env, ok := os.LookupEnv(envForRepo(t)); ok { + envKey := envForRepo(t) + env, ok := os.LookupEnv(envKey) + if !ok { + // TODO remove after deprecation period + envKey = envForRepoDeprecation(t) + env, ok = os.LookupEnv(envKey) + if ok { + log.Warnf("Use deprecation env(%s) value, please use env(%s) instead.", envKey, envForRepo(t)) + } + } + if ok { sp := strings.SplitN(env, ":", 2) if len(sp) != 2 { - log.Warnf("invalid env(%s) value, missing token or address", envForRepo(t)) + log.Warnf("invalid env(%s) value, missing token or address", envKey) } else { ma, err := multiaddr.NewMultiaddr(sp[1]) if err != nil { - return APIInfo{}, xerrors.Errorf("could not parse multiaddr from env(%s): %w", envForRepo(t), err) + return APIInfo{}, xerrors.Errorf("could not parse multiaddr from env(%s): %w", envKey, err) } return APIInfo{ Addr: ma, diff --git a/cli/multisig.go b/cli/multisig.go index 8230ee140..7baf82fde 100644 --- a/cli/multisig.go +++ b/cli/multisig.go @@ -51,7 +51,8 @@ var msigCreateCmd = &cli.Command{ ArgsUsage: "[address1 address2 ...]", Flags: []cli.Flag{ &cli.Int64Flag{ - Name: "required", + Name: "required", + Usage: "number of required approvals (uses number of signers provided if omitted)", }, &cli.StringFlag{ Name: "value", diff --git a/cli/send.go b/cli/send.go index 9f9c70dde..4a9a39bfc 100644 --- a/cli/send.go +++ b/cli/send.go @@ -77,7 +77,7 @@ var sendCmd = &cli.Command{ From: fromAddr, To: toAddr, Value: types.BigInt(val), - GasLimit: 10000, + GasLimit: 100_000_000, GasPrice: gp, } diff --git a/cli/sync.go b/cli/sync.go index fbb69a870..57553a068 100644 --- a/cli/sync.go +++ b/cli/sync.go @@ -195,7 +195,7 @@ func SyncWait(ctx context.Context, napi api.FullNode) error { case <-ctx.Done(): fmt.Println("\nExit by user") return nil - case <-time.After(1 * time.Second): + case <-build.Clock.After(1 * time.Second): } } } diff --git a/cmd/chain-noise/main.go b/cmd/chain-noise/main.go index a1e92ee96..5a04fbf21 100644 --- a/cmd/chain-noise/main.go +++ b/cmd/chain-noise/main.go @@ -11,6 +11,7 @@ import ( "github.com/filecoin-project/go-address" "github.com/filecoin-project/lotus/api" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/types" lcli "github.com/filecoin-project/lotus/cli" @@ -68,7 +69,7 @@ func sendSmallFundsTxs(ctx context.Context, api api.FullNode, from address.Addre sendSet = append(sendSet, naddr) } - tick := time.NewTicker(time.Second / time.Duration(rate)) + tick := build.Clock.Ticker(time.Second / time.Duration(rate)) for { select { case <-tick.C: @@ -76,7 +77,7 @@ func sendSmallFundsTxs(ctx context.Context, api api.FullNode, from address.Addre From: from, To: sendSet[rand.Intn(20)], Value: types.NewInt(1), - GasLimit: 100000, + GasLimit: 100_000_000, GasPrice: types.NewInt(0), } diff --git a/cmd/lotus-bench/import.go b/cmd/lotus-bench/import.go index 6d5f7f8ff..3c56a5707 100644 --- a/cmd/lotus-bench/import.go +++ b/cmd/lotus-bench/import.go @@ -405,16 +405,19 @@ func getExtras(ex interface{}) (*string, *float64) { func tallyGasCharges(charges map[string]*stats, et types.ExecutionTrace) { for i, gc := range et.GasCharges { name := gc.Name - if name == "OnIpldGetStart" { + if name == "OnIpldGetEnd" { continue } tt := float64(gc.TimeTaken.Nanoseconds()) if name == "OnIpldGet" { - prev := et.GasCharges[i-1] - if prev.Name != "OnIpldGetStart" { - log.Warn("OnIpldGet without OnIpldGetStart") + next := &types.GasTrace{} + if i+1 < len(et.GasCharges) { + next = et.GasCharges[i+1] } - tt += float64(prev.TimeTaken.Nanoseconds()) + if next.Name != "OnIpldGetEnd" { + log.Warn("OnIpldGet without OnIpldGetEnd") + } + tt += float64(next.TimeTaken.Nanoseconds()) } eType, eSize := getExtras(gc.Extra) if eType != nil { @@ -604,7 +607,7 @@ var importAnalyzeCmd = &cli.Command{ timeInActors := actorExec.timeTaken.Mean() * actorExec.timeTaken.n fmt.Printf("Avarage time per epoch in actors: %s (%.1f%%)\n", time.Duration(timeInActors)/time.Duration(totalTipsets), timeInActors/float64(totalTime)*100) } - if actorExecDone, ok := charges["OnActorExecDone"]; ok { + if actorExecDone, ok := charges["OnMethodInvocationDone"]; ok { timeInActors := actorExecDone.timeTaken.Mean() * actorExecDone.timeTaken.n fmt.Printf("Avarage time per epoch in OnActorExecDone %s (%.1f%%)\n", time.Duration(timeInActors)/time.Duration(totalTipsets), timeInActors/float64(totalTime)*100) } diff --git a/cmd/lotus-chainwatch/storage.go b/cmd/lotus-chainwatch/storage.go index 12cb8f243..040cbc8e8 100644 --- a/cmd/lotus-chainwatch/storage.go +++ b/cmd/lotus-chainwatch/storage.go @@ -3,6 +3,7 @@ package main import ( "context" "database/sql" + "strconv" "sync" "time" @@ -330,8 +331,15 @@ create table if not exists miner_sectors_heads primary key (miner_id,miner_sectors_cid) ); - -create type miner_sector_event_type as enum ('ADDED', 'EXTENDED', 'EXPIRED', 'TERMINATED'); +DO $$ +BEGIN + IF NOT EXISTS (SELECT 1 FROM pg_type WHERE typname = 'miner_sector_event_type') THEN + CREATE TYPE miner_sector_event_type AS ENUM + ( + 'ADDED','EXTENDED', 'EXPIRED', 'TERMINATED' + ); + END IF; +END$$; create table if not exists miner_sector_events ( @@ -342,7 +350,50 @@ create table if not exists miner_sector_events constraint miner_sector_events_pk primary key (sector_id, event, miner_id, state_root) -) +); + +create table if not exists market_deal_proposals +( + deal_id bigint not null, + + state_root text not null, + + piece_cid text not null, + padded_piece_size bigint not null, + unpadded_piece_size bigint not null, + is_verified bool not null, + + client_id text not null, + provider_id text not null, + + start_epoch bigint not null, + end_epoch bigint not null, + slashed_epoch bigint, + storage_price_per_epoch text not null, + + provider_collateral text not null, + client_collateral text not null, + + constraint market_deal_proposal_pk + primary key (deal_id) +); + +create table if not exists market_deal_states +( + deal_id bigint not null, + + sector_start_epoch bigint not null, + last_update_epoch bigint not null, + slash_epoch bigint not null, + + state_root text not null, + + unique (deal_id, sector_start_epoch, last_update_epoch, slash_epoch), + + constraint market_deal_states_pk + primary key (deal_id, state_root) + +); /* create or replace function miner_tips(epoch bigint) @@ -854,7 +905,7 @@ func (st *storage) updateMinerSectors(minerTips map[types.TipSetKey][]*minerStat } for _, added := range changes.Added { - if _, err := eventStmt.Exec(miner.addr.String(), added.SectorNumber, miner.stateroot.String(), "ADDED"); err != nil { + if _, err := eventStmt.Exec(added.SectorNumber, "ADDED", miner.addr.String(), miner.stateroot.String()); err != nil { return err } } @@ -902,6 +953,172 @@ func (st *storage) updateMinerSectors(minerTips map[types.TipSetKey][]*minerStat return updateTx.Commit() } +func (st *storage) storeMarketActorDealStates(marketTips map[types.TipSetKey]*marketStateInfo, tipHeights []tipsetKeyHeight, api api.FullNode) error { + start := time.Now() + defer func() { + log.Infow("Stored Market Deal States", "duration", time.Since(start).String()) + }() + tx, err := st.db.Begin() + if err != nil { + return err + } + if _, err := tx.Exec(`create temp table mds (like market_deal_states excluding constraints) on commit drop;`); err != nil { + return err + } + stmt, err := tx.Prepare(`copy mds (deal_id, sector_start_epoch, last_update_epoch, slash_epoch, state_root) from STDIN`) + if err != nil { + return err + } + for _, th := range tipHeights { + mt := marketTips[th.tsKey] + dealStates, err := api.StateMarketDeals(context.TODO(), mt.tsKey) + if err != nil { + return err + } + + for dealID, ds := range dealStates { + id, err := strconv.ParseUint(dealID, 10, 64) + if err != nil { + return err + } + + if _, err := stmt.Exec( + id, + ds.State.SectorStartEpoch, + ds.State.LastUpdatedEpoch, + ds.State.SlashEpoch, + mt.stateroot.String(), + ); err != nil { + return err + } + + } + } + if err := stmt.Close(); err != nil { + return err + } + + if _, err := tx.Exec(`insert into market_deal_states select * from mds on conflict do nothing`); err != nil { + return err + } + + return tx.Commit() +} + +func (st *storage) storeMarketActorDealProposals(marketTips map[types.TipSetKey]*marketStateInfo, tipHeights []tipsetKeyHeight, api api.FullNode) error { + start := time.Now() + defer func() { + log.Infow("Stored Market Deal Proposals", "duration", time.Since(start).String()) + }() + tx, err := st.db.Begin() + if err != nil { + return err + } + + if _, err := tx.Exec(`create temp table mdp (like market_deal_proposals excluding constraints) on commit drop;`); err != nil { + return xerrors.Errorf("prep temp: %w", err) + } + + stmt, err := tx.Prepare(`copy mdp (deal_id, state_root, piece_cid, padded_piece_size, unpadded_piece_size, is_verified, client_id, provider_id, start_epoch, end_epoch, slashed_epoch, storage_price_per_epoch, provider_collateral, client_collateral) from STDIN`) + if err != nil { + return err + } + + // insert in sorted order (lowest height -> highest height) since dealid is pk of table. + for _, th := range tipHeights { + mt := marketTips[th.tsKey] + dealStates, err := api.StateMarketDeals(context.TODO(), mt.tsKey) + if err != nil { + return err + } + + for dealID, ds := range dealStates { + id, err := strconv.ParseUint(dealID, 10, 64) + if err != nil { + return err + } + + if _, err := stmt.Exec( + id, + mt.stateroot.String(), + ds.Proposal.PieceCID.String(), + ds.Proposal.PieceSize, + ds.Proposal.PieceSize.Unpadded(), + ds.Proposal.VerifiedDeal, + ds.Proposal.Client.String(), + ds.Proposal.Provider.String(), + ds.Proposal.StartEpoch, + ds.Proposal.EndEpoch, + nil, // slashed_epoch + ds.Proposal.StoragePricePerEpoch.String(), + ds.Proposal.ProviderCollateral.String(), + ds.Proposal.ClientCollateral.String(), + ); err != nil { + return err + } + + } + } + if err := stmt.Close(); err != nil { + return err + } + if _, err := tx.Exec(`insert into market_deal_proposals select * from mdp on conflict do nothing`); err != nil { + return err + } + + return tx.Commit() + +} + +func (st *storage) updateMarketActorDealProposals(marketTip map[types.TipSetKey]*marketStateInfo, tipHeights []tipsetKeyHeight, api api.FullNode) error { + start := time.Now() + defer func() { + log.Infow("Updated Market Deal Proposals", "duration", time.Since(start).String()) + }() + pred := state.NewStatePredicates(api) + + tx, err := st.db.Begin() + if err != nil { + return err + } + + stmt, err := tx.Prepare(`update market_deal_proposals set slashed_epoch=$1 where deal_id=$2`) + if err != nil { + return err + } + + for _, th := range tipHeights { + mt := marketTip[th.tsKey] + stateDiff := pred.OnStorageMarketActorChanged(pred.OnDealStateChanged(pred.OnDealStateAmtChanged())) + + changed, val, err := stateDiff(context.TODO(), mt.parentTsKey, mt.tsKey) + if err != nil { + log.Warnw("error getting market deal state diff", "error", err) + } + if !changed { + continue + } + changes, ok := val.(*state.MarketDealStateChanges) + if !ok { + return xerrors.Errorf("Unknown type returned by Deal State AMT predicate: %T", val) + } + + for _, modified := range changes.Modified { + if modified.From.SlashEpoch != modified.To.SlashEpoch { + if _, err := stmt.Exec(modified.To.SlashEpoch, modified.ID); err != nil { + return err + } + } + } + } + + if err := stmt.Close(); err != nil { + return err + } + + return tx.Commit() +} + func (st *storage) storeHeaders(bhs map[cid.Cid]*types.BlockHeader, sync bool) error { st.headerLk.Lock() defer st.headerLk.Unlock() diff --git a/cmd/lotus-chainwatch/sync.go b/cmd/lotus-chainwatch/sync.go index 660efc383..cb866a408 100644 --- a/cmd/lotus-chainwatch/sync.go +++ b/cmd/lotus-chainwatch/sync.go @@ -7,6 +7,7 @@ import ( "encoding/json" "fmt" "math" + "sort" "sync" "time" @@ -18,6 +19,7 @@ import ( "github.com/filecoin-project/specs-actors/actors/abi" "github.com/filecoin-project/specs-actors/actors/abi/big" "github.com/filecoin-project/specs-actors/actors/builtin" + "github.com/filecoin-project/specs-actors/actors/builtin/market" "github.com/filecoin-project/specs-actors/actors/builtin/miner" "github.com/filecoin-project/specs-actors/actors/builtin/power" "github.com/filecoin-project/specs-actors/actors/builtin/reward" @@ -81,6 +83,20 @@ type minerStateInfo struct { psize uint64 } +type marketStateInfo struct { + // common + act types.Actor + stateroot cid.Cid + + // calculating changes + // calculating changes + tsKey types.TipSetKey + parentTsKey types.TipSetKey + + // market actor specific + state market.State +} + type actorInfo struct { stateroot cid.Cid tsKey types.TipSetKey @@ -88,6 +104,11 @@ type actorInfo struct { state string } +type tipsetKeyHeight struct { + height abi.ChainEpoch + tsKey types.TipSetKey +} + func syncHead(ctx context.Context, api api.FullNode, st *storage, headTs *types.TipSet, maxBatch int) { var alk sync.Mutex @@ -169,6 +190,9 @@ func syncHead(ctx context.Context, api api.FullNode, st *storage, headTs *types. log.Infow("Starting Sync", "height", minH, "numBlocks", len(toSync), "maxBatch", maxBatch) + // relate tipset keys to height so they may be processed in ascending order. + var tipHeights []tipsetKeyHeight + tipsSeen := make(map[types.TipSetKey]struct{}) // map of addresses to changed actors var changes map[string]types.Actor // collect all actor state that has changes between block headers @@ -276,9 +300,20 @@ func syncHead(ctx context.Context, api api.FullNode, st *storage, headTs *types. parentTsKey: pts.Parents(), } addressToID[addr] = address.Undef + if _, ok := tipsSeen[pts.Key()]; !ok { + tipHeights = append(tipHeights, tipsetKeyHeight{ + height: pts.Height(), + tsKey: pts.Key(), + }) + } + tipsSeen[pts.Key()] = struct{}{} alk.Unlock() } }) + // sort tipHeights in ascending order. + sort.Slice(tipHeights, func(i, j int) bool { + return tipHeights[i].height < tipHeights[j].height + }) // map of tipset to reward state rewardTips := make(map[types.TipSetKey]*rewardStateInfo, len(changes)) @@ -313,23 +348,28 @@ func syncHead(ctx context.Context, api api.FullNode, st *storage, headTs *types. log.Infof("Getting actor change info") + // highly likely that the market actor will change at every epoch + marketActorChanges := make(map[types.TipSetKey]*marketStateInfo, len(changes)) + minerChanges := 0 for addr, m := range actors { for actor, c := range m { - // reward actor - if actor.Code == builtin.RewardActorCodeID { - rewardTips[c.tsKey] = &rewardStateInfo{ - stateroot: c.stateroot, - baselinePower: big.Zero(), - } + // only want actors with head change events + if _, found := headsSeen[actor.Head]; found { continue } + headsSeen[actor.Head] = struct{}{} - // miner actors with head change events - if actor.Code == builtin.StorageMinerActorCodeID { - if _, found := headsSeen[actor.Head]; found { - continue + switch actor.Code { + case builtin.StorageMarketActorCodeID: + marketActorChanges[c.tsKey] = &marketStateInfo{ + act: actor, + stateroot: c.stateroot, + tsKey: c.tsKey, + parentTsKey: c.parentTsKey, + state: market.State{}, } + case builtin.StorageMinerActorCodeID: minerChanges++ minerTips[c.tsKey] = append(minerTips[c.tsKey], &minerStateInfo{ @@ -346,10 +386,14 @@ func syncHead(ctx context.Context, api api.FullNode, st *storage, headTs *types. rawPower: big.Zero(), qalPower: big.Zero(), }) - - headsSeen[actor.Head] = struct{}{} + // reward actor + case builtin.RewardActorCodeID: + rewardTips[c.tsKey] = &rewardStateInfo{ + stateroot: c.stateroot, + baselinePower: big.Zero(), + } } - continue + } } @@ -440,6 +484,21 @@ func syncHead(ctx context.Context, api api.FullNode, st *storage, headTs *types. }) log.Infow("Completed Miner Processing", "duration", time.Since(minerProcessingStartedAt).String(), "processed", minerChanges) + log.Info("Getting market actor info") + // TODO: consider taking the min of the array length and using that for concurrency param, e.g: + // concurrency := math.Min(len(marketActorChanges), 50) + parmap.Par(50, parmap.MapArr(marketActorChanges), func(mrktInfo *marketStateInfo) { + astb, err := api.ChainReadObj(ctx, mrktInfo.act.Head) + if err != nil { + log.Error(err) + return + } + if err := mrktInfo.state.UnmarshalCBOR(bytes.NewReader(astb)); err != nil { + log.Error(err) + return + } + }) + log.Info("Getting receipts") receipts := fetchParentReceipts(ctx, api, toSync) @@ -501,6 +560,24 @@ func syncHead(ctx context.Context, api api.FullNode, st *storage, headTs *types. return } + log.Info("Storing market actor deal proposal info") + if err := st.storeMarketActorDealProposals(marketActorChanges, tipHeights, api); err != nil { + log.Error(err) + return + } + + log.Info("Storing market actor deal state info") + if err := st.storeMarketActorDealStates(marketActorChanges, tipHeights, api); err != nil { + log.Error(err) + return + } + + log.Info("Updating market actor deal proposal info") + if err := st.updateMarketActorDealProposals(marketActorChanges, tipHeights, api); err != nil { + log.Error(err) + return + } + log.Infof("Storing messages") if err := st.storeMessages(msgs); err != nil { diff --git a/cmd/lotus-fountain/main.go b/cmd/lotus-fountain/main.go index 089072992..b9c0fe26a 100644 --- a/cmd/lotus-fountain/main.go +++ b/cmd/lotus-fountain/main.go @@ -281,7 +281,7 @@ func (h *handler) send(w http.ResponseWriter, r *http.Request) { To: to, GasPrice: types.NewInt(0), - GasLimit: 10000, + GasLimit: 100_000_000, }) if err != nil { w.WriteHeader(400) @@ -355,7 +355,7 @@ func (h *handler) mkminer(w http.ResponseWriter, r *http.Request) { To: owner, GasPrice: types.NewInt(0), - GasLimit: 10000, + GasLimit: 100_000_000, }) if err != nil { w.WriteHeader(400) @@ -391,7 +391,7 @@ func (h *handler) mkminer(w http.ResponseWriter, r *http.Request) { Method: builtin.MethodsPower.CreateMiner, Params: params, - GasLimit: 10000000, + GasLimit: 100_000_000, GasPrice: types.NewInt(0), } @@ -424,7 +424,7 @@ func (h *handler) msgwait(w http.ResponseWriter, r *http.Request) { if mw.Receipt.ExitCode != 0 { w.WriteHeader(400) - w.Write([]byte(xerrors.Errorf("create storage miner failed: exit code %d", mw.Receipt.ExitCode).Error())) + w.Write([]byte(xerrors.Errorf("create miner failed: exit code %d", mw.Receipt.ExitCode).Error())) return } w.WriteHeader(200) @@ -447,7 +447,7 @@ func (h *handler) msgwaitaddr(w http.ResponseWriter, r *http.Request) { if mw.Receipt.ExitCode != 0 { w.WriteHeader(400) - w.Write([]byte(xerrors.Errorf("create storage miner failed: exit code %d", mw.Receipt.ExitCode).Error())) + w.Write([]byte(xerrors.Errorf("create miner failed: exit code %d", mw.Receipt.ExitCode).Error())) return } w.WriteHeader(200) diff --git a/cmd/lotus-fountain/site/_miner.html b/cmd/lotus-fountain/site/_miner.html index d83f90d72..a0ee95628 100644 --- a/cmd/lotus-fountain/site/_miner.html +++ b/cmd/lotus-fountain/site/_miner.html @@ -1,14 +1,14 @@ - Creating Storage Miner - Lotus Fountain + Creating Miner - Lotus Fountain
- [CREATING STORAGE MINER] + [CREATING MINER]
@@ -26,7 +26,7 @@ Waiting for transaction on chain..
- When creating storage miner, DO NOT REFRESH THE PAGE, wait for it to load. This can take more than 5min. + When creating miner, DO NOT REFRESH THE PAGE, wait for it to load. This can take more than 5min.
If you don't have an owner/worker address, you can create it by following these instructions. diff --git a/cmd/lotus-fountain/site/wait.html b/cmd/lotus-fountain/site/wait.html index ea2d64236..953db16a5 100644 --- a/cmd/lotus-fountain/site/wait.html +++ b/cmd/lotus-fountain/site/wait.html @@ -1,14 +1,14 @@ - Creating Storage Miner (wait) - Lotus Fountain + Creating Miner (wait) - Lotus Fountain
- [CREATING STORAGE MINER] + [CREATING MINER]
Gas Funds:    - WAIT @@ -17,12 +17,12 @@ Miner Actor:  - WAIT
diff --git a/cmd/lotus-seal-worker/main.go b/cmd/lotus-seal-worker/main.go index 2ec186eaa..bf0b420f0 100644 --- a/cmd/lotus-seal-worker/main.go +++ b/cmd/lotus-seal-worker/main.go @@ -36,7 +36,9 @@ import ( var log = logging.Logger("main") -const FlagStorageRepo = "workerrepo" +const FlagWorkerRepo = "worker-repo" +// TODO remove after deprecation period +const FlagWorkerRepoDeprecation = "workerrepo" func main() { lotuslog.SetupLogLevels() @@ -48,19 +50,23 @@ func main() { } app := &cli.App{ - Name: "lotus-seal-worker", - Usage: "Remote storage miner worker", + Name: "lotus-worker", + Usage: "Remote miner worker", Version: build.UserVersion(), Flags: []cli.Flag{ &cli.StringFlag{ - Name: FlagStorageRepo, - EnvVars: []string{"WORKER_PATH"}, + Name: FlagWorkerRepo, + Aliases: []string{FlagWorkerRepoDeprecation}, + EnvVars: []string{"LOTUS_WORKER_PATH", "WORKER_PATH"}, Value: "~/.lotusworker", // TODO: Consider XDG_DATA_HOME + Usage: fmt.Sprintf("Specify worker repo path. flag %s and env WORKER_PATH are DEPRECATION, will REMOVE SOON", FlagWorkerRepoDeprecation), }, &cli.StringFlag{ - Name: "storagerepo", - EnvVars: []string{"LOTUS_STORAGE_PATH"}, - Value: "~/.lotusstorage", // TODO: Consider XDG_DATA_HOME + Name: "miner-repo", + Aliases: []string{"storagerepo"}, + EnvVars: []string{"LOTUS_MINER_PATH", "LOTUS_STORAGE_PATH"}, + Value: "~/.lotusminer", // TODO: Consider XDG_DATA_HOME + Usage: fmt.Sprintf("Specify miner repo path. flag storagerepo and env LOTUS_STORAGE_PATH are DEPRECATION, will REMOVE SOON"), }, &cli.BoolFlag{ Name: "enable-gpu-proving", @@ -143,7 +149,7 @@ var runCmd = &cli.Command{ return err } if v.APIVersion != build.APIVersion { - return xerrors.Errorf("lotus-storage-miner API version doesn't match: local: ", api.Version{APIVersion: build.APIVersion}) + return xerrors.Errorf("lotus-miner API version doesn't match: local: ", api.Version{APIVersion: build.APIVersion}) } log.Infof("Remote version %s", v) @@ -186,7 +192,7 @@ var runCmd = &cli.Command{ // Open repo - repoPath := cctx.String(FlagStorageRepo) + repoPath := cctx.String(FlagWorkerRepo) r, err := repo.NewFS(repoPath) if err != nil { return err diff --git a/cmd/lotus-shed/nonce-fix.go b/cmd/lotus-shed/nonce-fix.go index 4fb30300a..c85e91797 100644 --- a/cmd/lotus-shed/nonce-fix.go +++ b/cmd/lotus-shed/nonce-fix.go @@ -89,7 +89,7 @@ var noncefix = &cli.Command{ From: addr, To: addr, Value: types.NewInt(1), - GasLimit: 10000, + GasLimit: 100_000_000, GasPrice: types.NewInt(1), Nonce: i, } diff --git a/cmd/lotus-shed/verifreg.go b/cmd/lotus-shed/verifreg.go index 747a233a5..3641ac2df 100644 --- a/cmd/lotus-shed/verifreg.go +++ b/cmd/lotus-shed/verifreg.go @@ -76,7 +76,7 @@ var verifRegAddVerifierCmd = &cli.Command{ From: fromk, Method: builtin.MethodsVerifiedRegistry.AddVerifier, GasPrice: types.NewInt(1), - GasLimit: 300000, + GasLimit: 100_000_000, Params: params, } @@ -152,7 +152,7 @@ var verifRegVerifyClientCmd = &cli.Command{ From: fromk, Method: builtin.MethodsVerifiedRegistry.AddVerifiedClient, GasPrice: types.NewInt(1), - GasLimit: 300000, + GasLimit: 100_000_000, Params: params, } diff --git a/cmd/lotus-storage-miner/info.go b/cmd/lotus-storage-miner/info.go index 99c09dde2..7dff5b36c 100644 --- a/cmd/lotus-storage-miner/info.go +++ b/cmd/lotus-storage-miner/info.go @@ -23,7 +23,7 @@ import ( var infoCmd = &cli.Command{ Name: "info", - Usage: "Print storage miner info", + Usage: "Print miner info", Flags: []cli.Flag{ &cli.BoolFlag{Name: "color"}, }, diff --git a/cmd/lotus-storage-miner/init.go b/cmd/lotus-storage-miner/init.go index 208c17d03..8468c7f96 100644 --- a/cmd/lotus-storage-miner/init.go +++ b/cmd/lotus-storage-miner/init.go @@ -50,7 +50,7 @@ import ( var initCmd = &cli.Command{ Name: "init", - Usage: "Initialize a lotus storage miner repo", + Usage: "Initialize a lotus miner repo", Flags: []cli.Flag{ &cli.StringFlag{ Name: "actor", @@ -107,7 +107,7 @@ var initCmd = &cli.Command{ }, }, Action: func(cctx *cli.Context) error { - log.Info("Initializing lotus storage miner") + log.Info("Initializing lotus miner") sectorSizeInt, err := units.RAMInBytes(cctx.String("sector-size")) if err != nil { @@ -151,7 +151,7 @@ var initCmd = &cli.Command{ log.Info("Checking if repo exists") - repoPath := cctx.String(FlagStorageRepo) + repoPath := cctx.String(FlagMinerRepo) r, err := repo.NewFS(repoPath) if err != nil { return err @@ -162,7 +162,7 @@ var initCmd = &cli.Command{ return err } if ok { - return xerrors.Errorf("repo at '%s' is already initialized", cctx.String(FlagStorageRepo)) + return xerrors.Errorf("repo at '%s' is already initialized", cctx.String(FlagMinerRepo)) } log.Info("Checking full node version") @@ -236,7 +236,7 @@ var initCmd = &cli.Command{ } if err := storageMinerInit(ctx, cctx, api, r, ssize, gasPrice); err != nil { - log.Errorf("Failed to initialize lotus-storage-miner: %+v", err) + log.Errorf("Failed to initialize lotus-miner: %+v", err) path, err := homedir.Expand(repoPath) if err != nil { return err @@ -249,7 +249,7 @@ var initCmd = &cli.Command{ } // TODO: Point to setting storage price, maybe do it interactively or something - log.Info("Storage miner successfully created, you can now start it with 'lotus-storage-miner run'") + log.Info("Miner successfully created, you can now start it with 'lotus-miner run'") return nil }, @@ -454,11 +454,11 @@ func storageMinerInit(ctx context.Context, cctx *cli.Context, api lapi.FullNode, cerr := configureStorageMiner(ctx, api, a, peerid, gasPrice) if err := m.Stop(ctx); err != nil { - log.Error("failed to shut down storage miner: ", err) + log.Error("failed to shut down miner: ", err) } if cerr != nil { - return xerrors.Errorf("failed to configure storage miner: %w", cerr) + return xerrors.Errorf("failed to configure miner: %w", cerr) } } @@ -492,7 +492,7 @@ func storageMinerInit(ctx context.Context, cctx *cli.Context, api lapi.FullNode, } if err := configureStorageMiner(ctx, api, a, peerid, gasPrice); err != nil { - return xerrors.Errorf("failed to configure storage miner: %w", err) + return xerrors.Errorf("failed to configure miner: %w", err) } addr = a @@ -505,7 +505,7 @@ func storageMinerInit(ctx context.Context, cctx *cli.Context, api lapi.FullNode, addr = a } - log.Infof("Created new storage miner: %s", addr) + log.Infof("Created new miner: %s", addr) if err := mds.Put(datastore.NewKey("miner-address"), addr.Bytes()); err != nil { return err } @@ -557,7 +557,7 @@ func configureStorageMiner(ctx context.Context, api lapi.FullNode, addr address. Params: enc, Value: types.NewInt(0), GasPrice: gasPrice, - GasLimit: 99999999, + GasLimit: 100_000_000, } smsg, err := api.MpoolPushMessage(ctx, msg) @@ -636,7 +636,7 @@ func createStorageMiner(ctx context.Context, api lapi.FullNode, peerid peer.ID, Method: builtin.MethodsPower.CreateMiner, Params: params, - GasLimit: 10000000, + GasLimit: 100_000_000, GasPrice: gasPrice, } @@ -654,7 +654,7 @@ func createStorageMiner(ctx context.Context, api lapi.FullNode, peerid peer.ID, } if mw.Receipt.ExitCode != 0 { - return address.Undef, xerrors.Errorf("create storage miner failed: exit code %d", mw.Receipt.ExitCode) + return address.Undef, xerrors.Errorf("create miner failed: exit code %d", mw.Receipt.ExitCode) } var retval power.CreateMinerReturn @@ -662,6 +662,6 @@ func createStorageMiner(ctx context.Context, api lapi.FullNode, peerid peer.ID, return address.Undef, err } - log.Infof("New storage miners address is: %s (%s)", retval.IDAddress, retval.RobustAddress) + log.Infof("New miners address is: %s (%s)", retval.IDAddress, retval.RobustAddress) return retval.IDAddress, nil } diff --git a/cmd/lotus-storage-miner/main.go b/cmd/lotus-storage-miner/main.go index ae8ea79e7..9576aae0b 100644 --- a/cmd/lotus-storage-miner/main.go +++ b/cmd/lotus-storage-miner/main.go @@ -2,6 +2,7 @@ package main import ( "context" + "fmt" "os" logging "github.com/ipfs/go-log/v2" @@ -20,7 +21,9 @@ import ( var log = logging.Logger("main") -const FlagStorageRepo = "storagerepo" +const FlagMinerRepo = "miner-repo" +// TODO remove after deprecation period +const FlagMinerRepoDeprecation = "storagerepo" func main() { lotuslog.SetupLogLevels() @@ -61,8 +64,8 @@ func main() { } app := &cli.App{ - Name: "lotus-storage-miner", - Usage: "Filecoin decentralized storage network storage miner", + Name: "lotus-miner", + Usage: "Filecoin decentralized storage network miner", Version: build.UserVersion(), EnableBashCompletion: true, Flags: []cli.Flag{ @@ -79,9 +82,11 @@ func main() { Value: "~/.lotus", // TODO: Consider XDG_DATA_HOME }, &cli.StringFlag{ - Name: FlagStorageRepo, - EnvVars: []string{"LOTUS_STORAGE_PATH"}, - Value: "~/.lotusstorage", // TODO: Consider XDG_DATA_HOME + Name: FlagMinerRepo, + Aliases: []string{FlagMinerRepoDeprecation}, + EnvVars: []string{"LOTUS_MINER_PATH", "LOTUS_STORAGE_PATH"}, + Value: "~/.lotusminer", // TODO: Consider XDG_DATA_HOME + Usage: fmt.Sprintf("Specify miner repo path. flag(%s) and env(LOTUS_STORAGE_PATH) are DEPRECATION, will REMOVE SOON", FlagMinerRepoDeprecation), }, }, diff --git a/cmd/lotus-storage-miner/market.go b/cmd/lotus-storage-miner/market.go index 4a82d5162..8bc00ae49 100644 --- a/cmd/lotus-storage-miner/market.go +++ b/cmd/lotus-storage-miner/market.go @@ -6,6 +6,7 @@ import ( "fmt" "os" "path/filepath" + "strconv" "text/tabwriter" "time" @@ -296,6 +297,7 @@ var storageDealsCmd = &cli.Command{ setBlocklistCmd, getBlocklistCmd, resetBlocklistCmd, + setSealDurationCmd, }, } @@ -357,7 +359,7 @@ var dealsListCmd = &cli.Command{ var getBlocklistCmd = &cli.Command{ Name: "get-blocklist", - Usage: "List the contents of the storage miner's piece CID blocklist", + Usage: "List the contents of the miner's piece CID blocklist", Flags: []cli.Flag{ &CidBaseFlag, }, @@ -388,7 +390,7 @@ var getBlocklistCmd = &cli.Command{ var setBlocklistCmd = &cli.Command{ Name: "set-blocklist", - Usage: "Set the storage miner's list of blocklisted piece CIDs", + Usage: "Set the miner's list of blocklisted piece CIDs", ArgsUsage: "[ (optional, will read from stdin if omitted)]", Flags: []cli.Flag{}, Action: func(cctx *cli.Context) error { @@ -435,7 +437,7 @@ var setBlocklistCmd = &cli.Command{ var resetBlocklistCmd = &cli.Command{ Name: "reset-blocklist", - Usage: "Remove all entries from the storage miner's piece CID blocklist", + Usage: "Remove all entries from the miner's piece CID blocklist", Flags: []cli.Flag{}, Action: func(cctx *cli.Context) error { api, closer, err := lcli.GetStorageMinerAPI(cctx) @@ -447,3 +449,29 @@ var resetBlocklistCmd = &cli.Command{ return api.DealsSetPieceCidBlocklist(lcli.DaemonContext(cctx), []cid.Cid{}) }, } + +var setSealDurationCmd = &cli.Command{ + Name: "set-seal-duration", + Usage: "Set the expected time, in minutes, that you expect sealing sectors to take. Deals that start before this duration will be rejected.", + ArgsUsage: "", + Action: func(cctx *cli.Context) error { + nodeApi, closer, err := lcli.GetStorageMinerAPI(cctx) + if err != nil { + return err + } + defer closer() + ctx := lcli.ReqContext(cctx) + if cctx.Args().Len() != 1 { + return xerrors.Errorf("must pass duration in minutes") + } + + hs, err := strconv.ParseUint(cctx.Args().Get(0), 10, 64) + if err != nil { + return xerrors.Errorf("could not parse duration: %w", err) + } + + delay := hs * uint64(time.Minute) + + return nodeApi.SectorSetExpectedSealDuration(ctx, time.Duration(delay)) + }, +} diff --git a/cmd/lotus-storage-miner/run.go b/cmd/lotus-storage-miner/run.go index 29634d17d..8b10e7c1e 100644 --- a/cmd/lotus-storage-miner/run.go +++ b/cmd/lotus-storage-miner/run.go @@ -30,7 +30,7 @@ import ( var runCmd = &cli.Command{ Name: "run", - Usage: "Start a lotus storage miner process", + Usage: "Start a lotus miner process", Flags: []cli.Flag{ &cli.StringFlag{ Name: "api", @@ -86,8 +86,8 @@ var runCmd = &cli.Command{ } } - storageRepoPath := cctx.String(FlagStorageRepo) - r, err := repo.NewFS(storageRepoPath) + minerRepoPath := cctx.String(FlagMinerRepo) + r, err := repo.NewFS(minerRepoPath) if err != nil { return err } @@ -97,7 +97,7 @@ var runCmd = &cli.Command{ return err } if !ok { - return xerrors.Errorf("repo at '%s' is not initialized, run 'lotus-storage-miner init' to set it up", storageRepoPath) + return xerrors.Errorf("repo at '%s' is not initialized, run 'lotus-miner init' to set it up", minerRepoPath) } shutdownChan := make(chan struct{}) diff --git a/cmd/lotus-storage-miner/stop.go b/cmd/lotus-storage-miner/stop.go index 0cc10b73c..186a15616 100644 --- a/cmd/lotus-storage-miner/stop.go +++ b/cmd/lotus-storage-miner/stop.go @@ -10,7 +10,7 @@ import ( var stopCmd = &cli.Command{ Name: "stop", - Usage: "Stop a running lotus storage miner", + Usage: "Stop a running lotus miner", Flags: []cli.Flag{}, Action: func(cctx *cli.Context) error { api, closer, err := lcli.GetAPI(cctx) diff --git a/cmd/lotus-storage-miner/storage.go b/cmd/lotus-storage-miner/storage.go index 5abe6c889..0a5505b6a 100644 --- a/cmd/lotus-storage-miner/storage.go +++ b/cmd/lotus-storage-miner/storage.go @@ -278,7 +278,7 @@ var storageFindCmd = &cli.Command{ } if !cctx.Args().Present() { - return xerrors.New("Usage: lotus-storage-miner storage find [sector number]") + return xerrors.New("Usage: lotus-miner storage find [sector number]") } snum, err := strconv.ParseUint(cctx.Args().First(), 10, 64) diff --git a/documentation/en/.glossary.json b/documentation/en/.glossary.json index bdc43e319..79d96664a 100644 --- a/documentation/en/.glossary.json +++ b/documentation/en/.glossary.json @@ -69,7 +69,7 @@ }, "filecoin-decentralized-storage-market": { "title": "Filecoin Decentralized Storage Market", - "value": "Storage Market subsystem is the data entry point into the network. Storage miners only earn power from data stored in a storage deal and all deals live on the Filecoin network." + "value": "Storage Market subsystem is the data entry point into the network. Miners only earn power from data stored in a storage deal and all deals live on the Filecoin network." }, "filecoin-proof-parameters": { "title": "Filecoin Proof Parameters", @@ -96,12 +96,12 @@ "value": "The Block Producer Miner's logic. It currently shares an interface and process with the Lotus Node. A Block Producer chooses which messages to include in a block and is rewarded according to each message’s gas price and consumption, forming a market." }, "lotus-storage-miner": { - "title": "Storage Miner (lotus-storage-miner)", - "value": "The Storage Miner's logic. It has its own dedicated process. Contributes to the network through Sector commitments and Proofs of Spacetime to prove that it is storing the sectors it has commited to." + "title": "Miner (lotus-miner)", + "value": "The Miner's logic. It has its own dedicated process. Contributes to the network through Sector commitments and Proofs of Spacetime to prove that it is storing the sectors it has commited to." }, "swarm-port": { "title": "Swarm Port (Libp2p)", - "value": "The LibP2P Swarm manages groups of connections to peers, handles incoming and outgoing streams, and is part of the storage miners implementation. The port value is part of the Host interface." + "value": "The LibP2P Swarm manages groups of connections to peers, handles incoming and outgoing streams, and is part of the miners implementation. The port value is part of the Host interface." }, "daemon": { "title": "Lotus Daemon", @@ -129,7 +129,7 @@ }, "total-network-power": { "title": "Total Network Power", - "value": "A reference to all the Power Tables for every subchain, accounting for each Lotus Storage Miner on chain." + "value": "A reference to all the Power Tables for every subchain, accounting for each Lotus Miner on chain." }, "chain-block-height": { "title": "Chain Block Height", diff --git a/documentation/en/.library.json b/documentation/en/.library.json index 545eb4a5b..55681b90b 100644 --- a/documentation/en/.library.json +++ b/documentation/en/.library.json @@ -83,9 +83,9 @@ "value": null, "posts": [ { - "title": "Lotus Seal Worker", - "slug": "en+lotus-seal-worker", - "github": "en/mining-lotus-seal-worker.md", + "title": "Lotus Worker", + "slug": "en+lotus-worker", + "github": "en/mining-lotus-worker.md", "value": null }, { diff --git a/documentation/en/api-scripting-support.md b/documentation/en/api-scripting-support.md index 9d07aa3c8..653f144ed 100644 --- a/documentation/en/api-scripting-support.md +++ b/documentation/en/api-scripting-support.md @@ -1,6 +1,6 @@ # Remote API Support -You may want to delegate the work **Lotus Storage Miner** or **Lotus Node** performs to other machines. +You may want to delegate the work **Lotus Miner** or **Lotus Node** performs to other machines. Here is how to setup the necessary authorization and environment variables. ## Environment variables @@ -13,13 +13,13 @@ Using the [JWT you generated](https://lotu.sh/en+api#how-do-i-generate-a-token-1 # Lotus Node FULLNODE_API_INFO="JWT_TOKEN:/ip4/127.0.0.1/tcp/1234/http" -# Lotus Storage Miner -STORAGE_API_INFO="JWT_TOKEN:/ip4/127.0.0.1/tcp/2345/http" +# Lotus Miner +MINER_API_INFO="JWT_TOKEN:/ip4/127.0.0.1/tcp/2345/http" ``` You can also use `lotus auth api-info --perm admin` to quickly create _API_INFO env vars - The **Lotus Node**'s `mutliaddr` is in `~/.lotus/api`. - The default token is in `~/.lotus/token`. -- The **Lotus Storage Miner**'s `multiaddr` is in `~/.lotusstorage/config`. -- The default token is in `~/.lotusstorage/token`. +- The **Lotus Miner**'s `multiaddr` is in `~/.lotusminer/config`. +- The default token is in `~/.lotusminer/token`. diff --git a/documentation/en/api.md b/documentation/en/api.md index ed42ec325..055bd7104 100644 --- a/documentation/en/api.md +++ b/documentation/en/api.md @@ -18,9 +18,9 @@ Options: For now, you can look into different files to find methods available to you based on your needs: -- [Both Lotus node + storage miner APIs](https://github.com/filecoin-project/lotus/blob/master/api/api_common.go) +- [Both Lotus node + miner APIs](https://github.com/filecoin-project/lotus/blob/master/api/api_common.go) - [Lotus node API](https://github.com/filecoin-project/lotus/blob/master/api/api_full.go) -- [Storage miner API](https://github.com/filecoin-project/lotus/blob/master/api/api_storage.go) +- [Lotus miner API](https://github.com/filecoin-project/lotus/blob/master/api/api_storage.go) The necessary permissions for each are in [api/struct.go](https://github.com/filecoin-project/lotus/blob/master/api/struct.go). @@ -46,7 +46,7 @@ If the request requires authorization, add an authorization header: ```sh curl -X POST \ -H "Content-Type: application/json" \ - -H "Authorization: Bearer $(cat ~/.lotusstorage/token)" \ + -H "Authorization: Bearer $(cat ~/.lotusminer/token)" \ --data '{ "jsonrpc": "2.0", "method": "Filecoin.ChainHead", "params": [], "id": 3 }' \ 'http://127.0.0.1:1234/rpc/v0' ``` @@ -58,10 +58,10 @@ curl -X POST \ To authorize your request, you will need to include the **JWT** in a HTTP header, for example: ```sh --H "Authorization: Bearer $(cat ~/.lotusstorage/token)" +-H "Authorization: Bearer $(cat ~/.lotusminer/token)" ``` -Admin token is stored in `~/.lotus/token` for the **Lotus Node** or `~/.lotusstorage/token` for the **Lotus Storage Miner**. +Admin token is stored in `~/.lotus/token` for the **Lotus Node** or `~/.lotusminer/token` for the **Lotus Miner**. ## How do I generate a token? @@ -71,8 +71,8 @@ To generate a JWT with custom permissions, use this command: # Lotus Node lotus auth create-token --perm admin -# Lotus Storage Miner -lotus-storage-miner auth create-token --perm admin +# Lotus Miner +lotus-miner auth create-token --perm admin ``` ## What authorization level should I use? diff --git a/documentation/en/architecture.md b/documentation/en/architecture.md index e4808a877..619e04f05 100644 --- a/documentation/en/architecture.md +++ b/documentation/en/architecture.md @@ -344,7 +344,7 @@ At the end of the `Repo()` function we see two mutually exclusive configuration ApplyIf(isType(repo.FullNode), ConfigFullNode(c)), ApplyIf(isType(repo.StorageMiner), ConfigStorageMiner(c)), ``` -As we said, the repo fully identifies the node so a repo type is also a *node* type, in this case a full node or a storage miner. (FIXME: What is the difference between the two, does *full* imply miner?) In this case the `daemon` command will create a `FullNode`, this is specified in the command logic itself in `main.DaemonCmd()`, the `FsRepo` created (and passed to `node.Repo()`) will be initiated with that type (see `(*FsRepo).Init(t RepoType)`). +As we said, the repo fully identifies the node so a repo type is also a *node* type, in this case a full node or a miner. (FIXME: What is the difference between the two, does *full* imply miner?) In this case the `daemon` command will create a `FullNode`, this is specified in the command logic itself in `main.DaemonCmd()`, the `FsRepo` created (and passed to `node.Repo()`) will be initiated with that type (see `(*FsRepo).Init(t RepoType)`). ## Online diff --git a/documentation/en/dev-tools-pond-ui.md b/documentation/en/dev-tools-pond-ui.md index e5c992073..cc3605339 100644 --- a/documentation/en/dev-tools-pond-ui.md +++ b/documentation/en/dev-tools-pond-ui.md @@ -19,7 +19,7 @@ Now go to `http://127.0.0.1:2222`. ## What can I test? - The `Spawn Node` button starts a new **Lotus Node** in a new draggable window. -- Click `[Spawn Storage Miner]` to start a **Lotus Storage Miner**. This require's the node's wallet to have funds. +- Click `[Spawn Miner]` to start a **Lotus Miner**. This require's the node's wallet to have funds. - Click on `[Client]` to open the **Lotus Node**'s client interface and propose a deal with an existing Miner. If successful you'll see a payment channel open up with that Miner. Don't leave Pond unattended for more than 10 hours, the web client will eventually consume all available RAM. @@ -27,6 +27,6 @@ Don't leave Pond unattended for more than 10 hours, the web client will eventual ## Troubleshooting - Turn it off and on - Start at the top -- `rm -rf ~/.lotus ~/.lotusstorage/`, this command will delete chain sync data, stored wallets, and other configurations so be careful. +- `rm -rf ~/.lotus ~/.lotusminer/`, this command will delete chain sync data, stored wallets, and other configurations so be careful. - Verify you have the correct versions of dependencies - If stuck on a bad fork, try `lotus chain sethead --genesis` diff --git a/documentation/en/dev/WIP-arch-complementary-notes.md b/documentation/en/dev/WIP-arch-complementary-notes.md index 00bedb56a..013a7bbac 100644 --- a/documentation/en/dev/WIP-arch-complementary-notes.md +++ b/documentation/en/dev/WIP-arch-complementary-notes.md @@ -32,7 +32,7 @@ Gossip sub spec and some introduction. # Look at the constructor of a miner -Follow the `lotus-storage-miner` command to see how a miner is created, from the command to the message to the storage power logic. +Follow the `lotus-miner` command to see how a miner is created, from the command to the message to the storage power logic. # Directory structure so far, main structures seen, their relation diff --git a/documentation/en/faqs.md b/documentation/en/faqs.md index dd6610aeb..e19dc333c 100644 --- a/documentation/en/faqs.md +++ b/documentation/en/faqs.md @@ -22,9 +22,9 @@ along the way. It can also facilitate the creation of new storage deals. If you interested in providing your own storage to the network, and do not want to produce blocks yourself, then the Lotus Node is all you need! -The Lotus Storage Miner does everything you need for the registration of storage, and the -production of new blocks. The Lotus Storage Miner communicates with the network -by talking to a Lotus Node over the JSON-RPC API. +The Lotus Miner does everything you need for the registration of storage, and the +production of new blocks. The Lotus Miner communicates with the network by talking +to a Lotus Node over the JSON-RPC API. ## Setting up a Lotus Node @@ -49,11 +49,16 @@ To update Lotus, follow the instructions [here](https://lotu.sh/en+updating-lotu ### How do I prepare a fresh installation of Lotus? Stop the Lotus daemon, and delete all related files, including sealed and chain data by -running `rm ~/.lotus ~/.lotusstorage`. +running `rm ~/.lotus ~/.lotusminer`. Then, install Lotus afresh by following the instructions found [here](https://docs.lotu.sh/en+getting-started). +### Can I configure where the node's config and data goes? + +Yes! The `LOTUS_PATH` variable sets the path for where the Lotus node's data is written. +The `LOTUS_MINER_PATH` variable does the same for miner-specific information. + ## Interacting with a Lotus Node ### How can I communicate with a Lotus Node? @@ -126,13 +131,8 @@ Community-contributed Docker and Docker Compose examples are available ### How can I run two miners on the same machine? You can do so by changing the storage path variable for the second miner, e.g., -`LOTUS_STORAGE_PATH=~/.lotusstorage2`. You will also need to make sure that no ports collide. +`LOTUS_MINER_PATH=~/.lotusminer2`. You will also need to make sure that no ports collide. ### How do I setup my own local devnet? Follow the instructions found [here](https://lotu.sh/en+setup-local-dev-net). - -### Are there any other implementations of Filecoin? - -Yes! Check out the [go-filecoin](https://github.com/filecoin-project/go-filecoin#filecoin-go-filecoin) -implementation, which is fully interoperable with Lotus! diff --git a/documentation/en/getting-started.md b/documentation/en/getting-started.md index 7acd03f34..b15c5e390 100644 --- a/documentation/en/getting-started.md +++ b/documentation/en/getting-started.md @@ -9,15 +9,15 @@ For more details about Filecoin, check out the [Filecoin Docs](https://docs.file - How to install Lotus on [Arch Linux](https://docs.lotu.sh/en+install-lotus-arch), [Ubuntu](https://docs.lotu.sh/en+install-lotus-ubuntu), or [MacOS](https://docs.lotu.sh/en+install-lotus-macos). - Joining the [Lotus Testnet](https://docs.lotu.sh/en+join-testnet). - [Storing](https://docs.lotu.sh/en+storing-data) or [retrieving](https://docs.lotu.sh/en+retrieving-data) data. -- Mining Filecoin using the **Lotus Storage Miner** in your [CLI](https://docs.lotu.sh/en+mining). +- Mining Filecoin using the **Lotus Miner** in your [CLI](https://docs.lotu.sh/en+mining). ## How is Lotus designed? Lotus is architected modularly to keep clean API boundaries while using the same process. Installing Lotus will include two separate programs: - The **Lotus Node** -- The **Lotus Storage Miner** +- The **Lotus Miner** -The **Lotus Storage Miner** is intended to be run on the machine that manages a single storage miner instance, and is meant to communicate with the **Lotus Node** via the websocket **JSON-RPC** API for all of the chain interaction needs. +The **Lotus Miner** is intended to be run on the machine that manages a single miner instance, and is meant to communicate with the **Lotus Node** via the websocket **JSON-RPC** API for all of the chain interaction needs. -This way, a mining operation may easily run a **Lotus Storage Miner** or many of them, connected to one or many **Lotus Node** instances. +This way, a mining operation may easily run a **Lotus Miner** or many of them, connected to one or many **Lotus Node** instances. diff --git a/documentation/en/hardware-mining.md b/documentation/en/hardware-mining.md index 459b6074b..d421f6fb1 100644 --- a/documentation/en/hardware-mining.md +++ b/documentation/en/hardware-mining.md @@ -1,6 +1,6 @@ # Protocol Labs Standard Testing Configuration -> This documentation page describes the standard testing configuration the Protocol Labs team has used to test **Lotus Storage Miner**s on Lotus. There is no guarantee this testing configuration will be suitable for Filecoin storage mining at MainNet launch. If you need to buy new hardware to join the Filecoin Testnet, we recommend to buy no more hardware than you require for testing. To learn more please read this [Protocol Labs Standard Testing Configuration post](https://filecoin.io/blog/filecoin-testnet-mining/). +> This documentation page describes the standard testing configuration the Protocol Labs team has used to test **Lotus Miner**s on Lotus. There is no guarantee this testing configuration will be suitable for Filecoin storage mining at MainNet launch. If you need to buy new hardware to join the Filecoin Testnet, we recommend to buy no more hardware than you require for testing. To learn more please read this [Protocol Labs Standard Testing Configuration post](https://filecoin.io/blog/filecoin-testnet-mining/). **Sector sizes** and **minimum pledged storage** required to mine blocks are two very important Filecoin Testnet parameters that impact hardware decisions. We will continue to refine all parameters during Testnet. diff --git a/documentation/en/local-dev-net.md b/documentation/en/local-dev-net.md index e11d9b358..27d9efd13 100644 --- a/documentation/en/local-dev-net.md +++ b/documentation/en/local-dev-net.md @@ -34,13 +34,13 @@ Then, in another console, import the genesis miner key: Set up the genesis miner: ```sh -./lotus-storage-miner init --genesis-miner --actor=t01000 --sector-size=2KiB --pre-sealed-sectors=~/.genesis-sectors --pre-sealed-metadata=~/.genesis-sectors/pre-seal-t01000.json --nosync +./lotus-miner init --genesis-miner --actor=t01000 --sector-size=2KiB --pre-sealed-sectors=~/.genesis-sectors --pre-sealed-metadata=~/.genesis-sectors/pre-seal-t01000.json --nosync ``` Now, finally, start up the miner: ```sh -./lotus-storage-miner run --nosync +./lotus-miner run --nosync ``` If all went well, you will have your own local Lotus Devnet running. diff --git a/documentation/en/miner-deals.md b/documentation/en/miner-deals.md index 793479385..0aee0e1af 100644 --- a/documentation/en/miner-deals.md +++ b/documentation/en/miner-deals.md @@ -6,7 +6,7 @@ to install a Lotus node and sync to the top of the chain. ## Set up an ask ``` -lotus-storage-miner set-price +lotus-miner set-price ``` This command will set up your miner to accept deal proposals that meet the input price. diff --git a/documentation/en/mining-lotus-seal-worker.md b/documentation/en/mining-lotus-worker.md similarity index 53% rename from documentation/en/mining-lotus-seal-worker.md rename to documentation/en/mining-lotus-worker.md index aba115661..144fbc954 100644 --- a/documentation/en/mining-lotus-seal-worker.md +++ b/documentation/en/mining-lotus-worker.md @@ -1,10 +1,10 @@ -# Lotus Seal Worker +# Lotus Worker -The **Lotus Seal Worker** is an extra process that can offload heavy processing tasks from your **Lotus Storage Miner**. The sealing process automatically runs in the **Lotus Storage Miner** process, but you can use the Seal Worker on another machine communicating over a fast network to free up resources on the machine running the mining process. +The **Lotus Worker** is an extra process that can offload heavy processing tasks from your **Lotus Miner**. The sealing process automatically runs in the **Lotus Miner** process, but you can use the Worker on another machine communicating over a fast network to free up resources on the machine running the mining process. -## Note: Using the Lotus Seal Worker from China +## Note: Using the Lotus Worker from China -If you are trying to use `lotus-seal-worker` from China. You should set this **environment variable** on your machine: +If you are trying to use `lotus-worker` from China. You should set this **environment variable** on your machine: ```sh IPFS_GATEWAY="https://proof-parameters.s3.cn-south-1.jdcloud-oss.com/ipfs/" @@ -12,17 +12,17 @@ IPFS_GATEWAY="https://proof-parameters.s3.cn-south-1.jdcloud-oss.com/ipfs/" ## Get Started -Make sure that the `lotus-seal-worker` is compiled and installed by running: +Make sure that the `lotus-worker` is compiled and installed by running: ```sh -make lotus-seal-worker +make lotus-worker ``` -## Setting up the Storage Miner +## Setting up the Miner -First, you will need to ensure your `lotus-storage-miner`'s API is accessible over the network. +First, you will need to ensure your `lotus-miner`'s API is accessible over the network. -To do this, open up `~/.lotusstorage/config.toml` (Or if you manually set `LOTUS_STORAGE_PATH`, look under that directory) and look for the API field. +To do this, open up `~/.lotusminer/config.toml` (Or if you manually set `LOTUS_MINER_PATH`, look under that directory) and look for the API field. Default config: @@ -40,22 +40,22 @@ A more permissive and less secure option is to change it to `0.0.0.0`. This will Next, you will need to [create an authentication token](https://docs.lotu.sh/en+api-scripting-support#generate-a-jwt-46). All Lotus APIs require authentication tokens to ensure your processes are as secure against attackers attempting to make unauthenticated requests to them. -### Connect the Lotus Seal Worker +### Connect the Lotus Worker -On the machine that will run `lotus-seal-worker`, set the `STORAGE_API_INFO` environment variable to `TOKEN:STORAGE_NODE_MULTIADDR`. Where `TOKEN` is the token we created above, and `STORAGE_NODE_MULTIADDR` is the `multiaddr` of the **Lotus Storage Miner** API that was set in `config.toml`. +On the machine that will run `lotus-worker`, set the `MINER_API_INFO` environment variable to `TOKEN:MINER_NODE_MULTIADDR`. Where `TOKEN` is the token we created above, and `NIMER_NODE_MULTIADDR` is the `multiaddr` of the **Lotus Miner** API that was set in `config.toml`. Once this is set, run: ```sh -lotus-seal-worker run --address 192.168.2.10:2345 +lotus-worker run --address 192.168.2.10:2345 ``` Replace `192.168.2.10:2345` with the proper IP and port. -To check that the **Lotus Seal Worker** is connected to your **Lotus Storage Miner**, run `lotus-storage-miner workers list` and check that the remote worker count has increased. +To check that the **Lotus Worker** is connected to your **Lotus Miner**, run `lotus-miner workers list` and check that the remote worker count has increased. ```sh -why@computer ~/lotus> lotus-storage-miner workers list +why@computer ~/lotus> lotus-miner workers list Worker 0, host computer CPU: [ ] 0 core(s) in use RAM: [|||||||||||||||||| ] 28% 18.1 GiB/62.7 GiB @@ -71,11 +71,11 @@ Worker 1, host othercomputer ### Running locally for manually managing process priority -You can also run the **Lotus Seal Worker** on the same machine as your **Lotus Storage Miner**, so you can manually manage the process priority. +You can also run the **Lotus Worker** on the same machine as your **Lotus Miner**, so you can manually manage the process priority. To do so you have to first __disable all seal task types__ in the miner config. This is important to prevent conflicts between the two processes. -You can then run the storage miner on your local-loopback interface; +You can then run the miner on your local-loopback interface; ```sh -lotus-seal-worker run --address 127.0.0.1:2345 +lotus-worker run --address 127.0.0.1:2345 ``` \ No newline at end of file diff --git a/documentation/en/mining-troubleshooting.md b/documentation/en/mining-troubleshooting.md index 561031c5d..98af6fa72 100644 --- a/documentation/en/mining-troubleshooting.md +++ b/documentation/en/mining-troubleshooting.md @@ -16,16 +16,16 @@ The **Bellman** lockfile is created to lock a GPU for a process. This bug can oc mining block failed: computing election proof: github.com/filecoin-project/lotus/miner.(*Miner).mineOne ``` -This bug occurs when the storage miner can't acquire the `bellman.lock`. To fix it you need to stop the `lotus-storage-miner` and remove `/tmp/bellman.lock`. +This bug occurs when the miner can't acquire the `bellman.lock`. To fix it you need to stop the `lotus-miner` and remove `/tmp/bellman.lock`. ## Error: Failed to get api endpoint ```sh -lotus-storage-miner info -# WARN main lotus-storage-miner/main.go:73 failed to get api endpoint: (/Users/myrmidon/.lotusstorage) %!w(*errors.errorString=&{API not running (no endpoint)}): +lotus-miner info +# WARN main lotus-storage-miner/main.go:73 failed to get api endpoint: (/Users/myrmidon/.lotusminer) %!w(*errors.errorString=&{API not running (no endpoint)}): ``` -If you see this, that means your **Lotus Storage Miner** isn't ready yet. You need to finish [syncing the chain](https://docs.lotu.sh/en+join-testnet). +If you see this, that means your **Lotus Miner** isn't ready yet. You need to finish [syncing the chain](https://docs.lotu.sh/en+join-testnet). ## Error: Your computer may not be fast enough @@ -38,7 +38,7 @@ If you see this, that means your computer is too slow and your blocks are not in ## Error: No space left on device ```sh -lotus-storage-miner sectors pledge +lotus-miner sectors pledge # No space left on device (os error 28) ``` diff --git a/documentation/en/mining.md b/documentation/en/mining.md index 3b1f5a8a3..80a447927 100644 --- a/documentation/en/mining.md +++ b/documentation/en/mining.md @@ -4,9 +4,9 @@ Here are instructions to learn how to perform storage mining. For hardware speci It is useful to [join the Testnet](https://docs.lotu.sh/en+join-testnet) prior to attempting storage mining for the first time. -## Note: Using the Lotus Storage Miner from China +## Note: Using the Lotus Miner from China -If you are trying to use `lotus-storage-miner` from China. You should set this **environment variable** on your machine. +If you are trying to use `lotus-miner` from China. You should set this **environment variable** on your machine. ```sh IPFS_GATEWAY="https://proof-parameters.s3.cn-south-1.jdcloud-oss.com/ipfs/" @@ -35,21 +35,21 @@ With your wallet address: The task will be complete when you see: ```sh -New storage miners address is: +New miners address is: ``` -## Initialize the storage miner +## Initialize the miner In a CLI window, use the following command to start your miner: ```sh -lotus-storage-miner init --actor=ACTOR_VALUE_RECEIVED --owner=OWNER_VALUE_RECEIVED +lotus-miner init --actor=ACTOR_VALUE_RECEIVED --owner=OWNER_VALUE_RECEIVED ``` Example ```sh -lotus-storage-miner init --actor=t01424 --owner=t3spmep2xxsl33o4gxk7yjxcobyohzgj3vejzerug25iinbznpzob6a6kexcbeix73th6vjtzfq7boakfdtd6a +lotus-miner init --actor=t01424 --owner=t3spmep2xxsl33o4gxk7yjxcobyohzgj3vejzerug25iinbznpzob6a6kexcbeix73th6vjtzfq7boakfdtd6a ``` You will have to wait some time for this operation to complete. @@ -59,7 +59,7 @@ You will have to wait some time for this operation to complete. To mine: ```sh -lotus-storage-miner run +lotus-miner run ``` If you are downloading **Filecoin Proof Parameters**, the download can take some time. @@ -67,14 +67,14 @@ If you are downloading **Filecoin Proof Parameters**, the download can take some Get information about your miner: ```sh -lotus-storage-miner info +lotus-miner info # example: miner id `t0111` ``` **Seal** random data to start producing **PoSts**: ```sh -lotus-storage-miner sectors pledge +lotus-miner sectors pledge ``` - Warning: On Linux configurations, this command will write data to `$TMPDIR` which is not usually the largest partition. You should point the value to a larger partition if possible. @@ -94,8 +94,8 @@ lotus state sectors ### `FIL_PROOFS_MAXIMIZE_CACHING=1` Environment variable -This env var can be used with `lotus-storage-miner`, `lotus-seal-worker`, and `lotus-bench` to make the precommit1 step faster at the cost of some memory use (1x sector size) +This env var can be used with `lotus-miner`, `lotus-worker`, and `lotus-bench` to make the precommit1 step faster at the cost of some memory use (1x sector size) ### `FIL_PROOFS_USE_GPU_COLUMN_BUILDER=1` Environment variable -This env var can be used with `lotus-storage-miner`, `lotus-seal-worker`, and `lotus-bench` to enable experimental precommit2 GPU acceleration +This env var can be used with `lotus-miner`, `lotus-worker`, and `lotus-bench` to enable experimental precommit2 GPU acceleration diff --git a/documentation/en/retrieving-data.md b/documentation/en/retrieving-data.md index 56f8296e8..6bc9a8991 100644 --- a/documentation/en/retrieving-data.md +++ b/documentation/en/retrieving-data.md @@ -2,7 +2,7 @@ > There are recent bug reports with these instructions. If you happen to encounter any problems, please create a [GitHub issue](https://github.com/filecoin-project/lotus/issues/new) and a maintainer will address the problem as soon as they can. -Here are the operations you can perform after you have stored and sealed a **Data CID** with the **Lotus Storage Miner** in the network. +Here are the operations you can perform after you have stored and sealed a **Data CID** with the **Lotus Miner** in the network. If you would like to learn how to store a **Data CID** on a miner, read the instructions [here](https://docs.lotu.sh/en+storing-data). diff --git a/documentation/en/setting-a-static-port.md b/documentation/en/setting-a-static-port.md index 714f455b0..97ac6528e 100644 --- a/documentation/en/setting-a-static-port.md +++ b/documentation/en/setting-a-static-port.md @@ -1,10 +1,10 @@ # Static Ports -Depending on how your network is set up, you may need to set a static port to successfully connect to peers to perform storage deals with your **Lotus Storage Miner**. +Depending on how your network is set up, you may need to set a static port to successfully connect to peers to perform storage deals with your **Lotus Miner**. ## Setup -To change the random **swarm port**, you may edit the `config.toml` file located under `$LOTUS_STORAGE_PATH`. The default location of this file is `$HOME/.lotusstorage`. +To change the random **swarm port**, you may edit the `config.toml` file located under `$LOTUS_MINER_PATH`. The default location of this file is `$HOME/.lotusminer`. To change the port to `1347`: diff --git a/documentation/en/setup-troubleshooting.md b/documentation/en/setup-troubleshooting.md index 8a23544d9..a1c78b51b 100644 --- a/documentation/en/setup-troubleshooting.md +++ b/documentation/en/setup-troubleshooting.md @@ -5,7 +5,7 @@ Here is a command that will delete your chain data, stored wallets, stored data and any miners you have set up: ```sh -rm -rf ~/.lotus ~/.lotusstorage +rm -rf ~/.lotus ~/.lotusminer ``` This command usually resolves any issues with running `lotus` but it is not always required for updates. We will share information about when resetting your chain data and miners is required for an update in the future. diff --git a/documentation/en/storing-data-troubleshooting.md b/documentation/en/storing-data-troubleshooting.md index 2f1a6b607..7e263deb1 100644 --- a/documentation/en/storing-data-troubleshooting.md +++ b/documentation/en/storing-data-troubleshooting.md @@ -21,7 +21,7 @@ WARN main lotus/main.go:72 failed to start deal: computing commP failed: gene In order to retrieve a file, it must be sealed. Miners can check sealing progress with this command: ```sh -lotus-storage-miner sectors list +lotus-miner sectors list ``` -When sealing is complete, `pSet: NO` will become `pSet: YES`. From now on the **Data CID** is [retrievable](https://docs.lotu.sh/en+retrieving-data) from the **Lotus Storage Miner**. +When sealing is complete, `pSet: NO` will become `pSet: YES`. From now on the **Data CID** is [retrievable](https://docs.lotu.sh/en+retrieving-data) from the **Lotus Miner**. diff --git a/documentation/en/storing-data.md b/documentation/en/storing-data.md index 357ebc064..67d2b1533 100644 --- a/documentation/en/storing-data.md +++ b/documentation/en/storing-data.md @@ -59,4 +59,4 @@ lotus client list-deals Upon success, this command will return a **Deal CID**. -The storage miner will need to **seal** the file before it can be retrieved. If the **Lotus Storage Miner** is not running on a machine designed for sealing, the process will take a very long time. +The miner will need to **seal** the file before it can be retrieved. If the **Lotus Miner** is not running on a machine designed for sealing, the process will take a very long time. diff --git a/extern/filecoin-ffi b/extern/filecoin-ffi index 6a143e06f..cddc56607 160000 --- a/extern/filecoin-ffi +++ b/extern/filecoin-ffi @@ -1 +1 @@ -Subproject commit 6a143e06f923f3a4f544c7a652e8b4df420a3d28 +Subproject commit cddc56607e1d851ea6d09d49404bd7db70cb3c2e diff --git a/go.mod b/go.mod index b9b805688..8aa536a81 100644 --- a/go.mod +++ b/go.mod @@ -12,24 +12,24 @@ require ( github.com/coreos/go-systemd/v22 v22.0.0 github.com/dgraph-io/badger/v2 v2.0.3 github.com/docker/go-units v0.4.0 - github.com/drand/drand v0.9.2-0.20200616080806-a94e9c1636a4 - github.com/drand/kyber v1.1.0 + github.com/drand/drand v1.0.3-0.20200714175734-29705eaf09d4 + github.com/drand/kyber v1.1.1 github.com/fatih/color v1.8.0 - github.com/filecoin-project/chain-validation v0.0.6-0.20200713102302-1bc823b1e01d - github.com/filecoin-project/filecoin-ffi v0.26.1-0.20200508175440-05b30afeb00d + github.com/filecoin-project/chain-validation v0.0.6-0.20200716223212-b3309d1a82f5 + github.com/filecoin-project/filecoin-ffi v0.30.4-0.20200716204036-cddc56607e1d github.com/filecoin-project/go-address v0.0.2-0.20200504173055-8b6f2fb2b3ef github.com/filecoin-project/go-amt-ipld/v2 v2.0.1-0.20200424220931-6263827e49f2 github.com/filecoin-project/go-bitfield v0.0.4-0.20200703174658-f4a5758051a1 github.com/filecoin-project/go-cbor-util v0.0.0-20191219014500-08c40a1e63a2 github.com/filecoin-project/go-crypto v0.0.0-20191218222705-effae4ea9f03 - github.com/filecoin-project/go-data-transfer v0.4.0 - github.com/filecoin-project/go-fil-commcid v0.0.0-20200208005934-2b8bd03caca5 - github.com/filecoin-project/go-fil-markets v0.4.0 + github.com/filecoin-project/go-data-transfer v0.4.1-0.20200715144713-b3311844e1a5 + github.com/filecoin-project/go-fil-commcid v0.0.0-20200716160307-8f644712406f + github.com/filecoin-project/go-fil-markets v0.4.1-0.20200715201050-c141144ea312 github.com/filecoin-project/go-jsonrpc v0.1.1-0.20200602181149-522144ab4e24 github.com/filecoin-project/go-paramfetch v0.0.2-0.20200701152213-3e0f0afdc261 github.com/filecoin-project/go-statestore v0.1.0 github.com/filecoin-project/go-storedcounter v0.0.0-20200421200003-1c99c62e8a5b - github.com/filecoin-project/sector-storage v0.0.0-20200712023225-1d67dcfa3c15 + github.com/filecoin-project/sector-storage v0.0.0-20200716210653-a846ac9b39ff github.com/filecoin-project/specs-actors v0.7.3-0.20200716231407-60a2ae96d2e6 github.com/filecoin-project/specs-storage v0.1.1-0.20200622113353-88a9704877ea github.com/filecoin-project/storage-fsm v0.0.0-20200717125541-d575c3a5f7f2 @@ -53,7 +53,7 @@ require ( github.com/ipfs/go-ds-measure v0.1.0 github.com/ipfs/go-filestore v1.0.0 github.com/ipfs/go-fs-lock v0.0.1 - github.com/ipfs/go-graphsync v0.0.6-0.20200708073926-caa872f68b2c + github.com/ipfs/go-graphsync v0.0.6-0.20200715142715-e2f27c4754e6 github.com/ipfs/go-hamt-ipld v0.1.1-0.20200605182717-0310ad2b0b1f github.com/ipfs/go-ipfs-blockstore v1.0.0 github.com/ipfs/go-ipfs-chunker v0.0.5 @@ -101,8 +101,9 @@ require ( github.com/multiformats/go-multiaddr-dns v0.2.0 github.com/multiformats/go-multiaddr-net v0.1.5 github.com/multiformats/go-multibase v0.0.3 - github.com/multiformats/go-multihash v0.0.13 + github.com/multiformats/go-multihash v0.0.14 github.com/opentracing/opentracing-go v1.1.0 + github.com/raulk/clock v1.1.0 github.com/stretchr/objx v0.2.0 // indirect github.com/stretchr/testify v1.6.1 github.com/syndtr/goleveldb v1.0.0 @@ -128,3 +129,5 @@ require ( replace github.com/golangci/golangci-lint => github.com/golangci/golangci-lint v1.18.0 replace github.com/filecoin-project/filecoin-ffi => ./extern/filecoin-ffi + +replace github.com/dgraph-io/badger/v2 => github.com/dgraph-io/badger/v2 v2.0.1-rc1.0.20200716180832-3ab515320794 diff --git a/go.sum b/go.sum index 86b64d802..350e4746f 100644 --- a/go.sum +++ b/go.sum @@ -82,6 +82,7 @@ github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkY github.com/aryann/difflib v0.0.0-20170710044230-e206f873d14a/go.mod h1:DAHtR1m6lCRdSC2Tm3DSWRPvIPr6xNKyeHdqDQSQT+A= github.com/aws/aws-lambda-go v1.13.3/go.mod h1:4UKl9IzQMoD+QF79YdCuzCwp8VbmG4VAQwij/eHl5CU= github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= +github.com/aws/aws-sdk-go v1.32.11/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= github.com/aws/aws-sdk-go-v2 v0.18.0/go.mod h1:JWVYvqSMppoMJC0x5wdwiImzgXTI9FuZwxzkQq9wy+g= github.com/beevik/ntp v0.2.0/go.mod h1:hIHWr+l3+/clUnF44zdK+CWW7fO8dR5cIylAQ76NRpg= github.com/benbjohnson/clock v1.0.1/go.mod h1:bGMdMPoPVvcYyt1gHDf4J2KE153Yf9BuiUKYMaxlTDM= @@ -93,6 +94,8 @@ github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/bradfitz/go-smtpd v0.0.0-20170404230938-deb6d6237625/go.mod h1:HYsPBTaaSFSlLx/70C2HPIMNZpVV8+vt/A+FMnYP11g= +github.com/briandowns/spinner v1.11.1 h1:OixPqDEcX3juo5AjQZAnFPbeUA0jvkp2qzB5gOZJ/L0= +github.com/briandowns/spinner v1.11.1/go.mod h1:QOuQk7x+EaDASo80FEXwlwiA+j/PPIcX3FScO+3/ZPQ= github.com/btcsuite/btcd v0.0.0-20190213025234-306aecffea32/go.mod h1:DrZx5ec/dmnfpw9KyYoQyYo7d0KEvTkk/5M/vbZjAr8= github.com/btcsuite/btcd v0.0.0-20190523000118-16327141da8c/go.mod h1:3J08xEfcugPacsc34/LKRU2yO7YmuT8yt28J8k2+rrI= github.com/btcsuite/btcd v0.0.0-20190605094302-a0d1e3e36d50/go.mod h1:3J08xEfcugPacsc34/LKRU2yO7YmuT8yt28J8k2+rrI= @@ -167,11 +170,12 @@ github.com/dgraph-io/badger v1.6.0-rc1/go.mod h1:zwt7syl517jmP8s94KqSxTlM6IMsdhY github.com/dgraph-io/badger v1.6.0/go.mod h1:zwt7syl517jmP8s94KqSxTlM6IMsdhYy6psNgSztDR4= github.com/dgraph-io/badger v1.6.1 h1:w9pSFNSdq/JPM1N12Fz/F/bzo993Is1W+Q7HjPzi7yg= github.com/dgraph-io/badger v1.6.1/go.mod h1:FRmFw3uxvcpa8zG3Rxs0th+hCLIuaQg8HlNV5bjgnuU= -github.com/dgraph-io/badger/v2 v2.0.3 h1:inzdf6VF/NZ+tJ8RwwYMjJMvsOALTHYdozn0qSl6XJI= -github.com/dgraph-io/badger/v2 v2.0.3/go.mod h1:3KY8+bsP8wI0OEnQJAKpd4wIJW/Mm32yw2j/9FUVnIM= -github.com/dgraph-io/ristretto v0.0.2-0.20200115201040-8f368f2f2ab3/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= +github.com/dgraph-io/badger/v2 v2.0.1-rc1.0.20200716180832-3ab515320794 h1:PIPH4SLjYXMMlX/cQqV7nIRatv7556yqUfWY+KBjrtQ= +github.com/dgraph-io/badger/v2 v2.0.1-rc1.0.20200716180832-3ab515320794/go.mod h1:26P/7fbL4kUZVEVKLAKXkBXKOydDmM2p1e+NhhnBCAE= github.com/dgraph-io/ristretto v0.0.2 h1:a5WaUrDa0qm0YrAAS1tUykT5El3kt62KNZZeMxQn3po= github.com/dgraph-io/ristretto v0.0.2/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= +github.com/dgraph-io/ristretto v0.0.3-0.20200630154024-f66de99634de h1:t0UHb5vdojIDUqktM6+xJAfScFBsVpXZmqC9dsgJmeA= +github.com/dgraph-io/ristretto v0.0.3-0.20200630154024-f66de99634de/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= github.com/dgryski/go-farm v0.0.0-20190104051053-3adb47b1fb0f/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2 h1:tdlZCpZ/P9DhczCTSixgIKmwPv6+wP5DGjqLYw5SUiA= @@ -180,13 +184,13 @@ github.com/docker/go-units v0.4.0 h1:3uh0PgVws3nIA0Q+MwDC8yjEPf9zjRfZZWXZYDct3Tw github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/drand/bls12-381 v0.3.2 h1:RImU8Wckmx8XQx1tp1q04OV73J9Tj6mmpQLYDP7V1XE= github.com/drand/bls12-381 v0.3.2/go.mod h1:dtcLgPtYT38L3NO6mPDYH0nbpc5tjPassDqiniuAt4Y= -github.com/drand/drand v0.9.2-0.20200616080806-a94e9c1636a4 h1:wEpu4hGFF0m0uDq/gxT9Ca/HWek0tvsMqsyPpLBWJ/E= -github.com/drand/drand v0.9.2-0.20200616080806-a94e9c1636a4/go.mod h1:Bu8QYdU0YdB2ZQZezHxabmOIciddiwLRnyV4nuZ2HQE= +github.com/drand/drand v1.0.3-0.20200714175734-29705eaf09d4 h1:+Rov3bfUriGWFR/lUVXnpimx+HMr9BXRC4by0BxuQ8k= +github.com/drand/drand v1.0.3-0.20200714175734-29705eaf09d4/go.mod h1:SnqWL9jksIMK63UKkfmWI6f9PDN8ROoCgg+Z4zWk7hg= github.com/drand/kyber v1.0.1-0.20200110225416-8de27ed8c0e2/go.mod h1:UpXoA0Upd1N9l4TvRPHr1qAUBBERj6JQ/mnKI3BPEmw= github.com/drand/kyber v1.0.2 h1:dHjtWJZJdn3zBBZ9pqLsLfcR9ScvDvSqzS1sWA8seao= github.com/drand/kyber v1.0.2/go.mod h1:x6KOpK7avKj0GJ4emhXFP5n7M7W7ChAPmnQh/OL6vRw= -github.com/drand/kyber v1.1.0 h1:uBfD8gwpVufr+7Dvbxi4jGQ+qoMCO5tRfhYPyn+Tpqk= -github.com/drand/kyber v1.1.0/go.mod h1:x6KOpK7avKj0GJ4emhXFP5n7M7W7ChAPmnQh/OL6vRw= +github.com/drand/kyber v1.1.1 h1:mwCY2XGRB+Qc1MPfrnRuVuXELkPhcq/r9yMoJIcDhHI= +github.com/drand/kyber v1.1.1/go.mod h1:x6KOpK7avKj0GJ4emhXFP5n7M7W7ChAPmnQh/OL6vRw= github.com/drand/kyber-bls12381 v0.1.0 h1:/P4C65VnyEwxzR5ZYYVMNzY1If+aYBrdUU5ukwh7LQw= github.com/drand/kyber-bls12381 v0.1.0/go.mod h1:N1emiHpm+jj7kMlxEbu3MUyOiooTgNySln564cgD9mk= github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= @@ -212,8 +216,8 @@ github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5Kwzbycv github.com/fatih/color v1.8.0 h1:5bzFgL+oy7JITMTxUPJ00n7VxmYd/PdMp5mHFX40/RY= github.com/fatih/color v1.8.0/go.mod h1:3l45GVGkyrnYNl9HoIjnp2NnNWvh6hLAqD8yTfGjnw8= github.com/fd/go-nat v1.0.0/go.mod h1:BTBu/CKvMmOMUPkKVef1pngt2WFH/lg7E6yQnulfp6E= -github.com/filecoin-project/chain-validation v0.0.6-0.20200713102302-1bc823b1e01d h1:6mOOHCn8iJfWPRELM7LPE4X9mBmCTvQORsgzsA/u0Wg= -github.com/filecoin-project/chain-validation v0.0.6-0.20200713102302-1bc823b1e01d/go.mod h1:293UFGwKduXCuIC2/5pIepH7lof+L9fNiPku/+arST4= +github.com/filecoin-project/chain-validation v0.0.6-0.20200716223212-b3309d1a82f5 h1:C2OX+TDZ5rN5wvtRBW/oWz7gKhD75Z+WzLIzSJxgO80= +github.com/filecoin-project/chain-validation v0.0.6-0.20200716223212-b3309d1a82f5/go.mod h1:4P0WlDnvDvrOsg2018Z8xISJUP3eBHXzHE+2Ks6EANo= github.com/filecoin-project/go-address v0.0.0-20200107215422-da8eea2842b5/go.mod h1:SAOwJoakQ8EPjwNIsiakIQKsoKdkcbx8U3IapgCg9R0= github.com/filecoin-project/go-address v0.0.2-0.20200218010043-eb9bb40ed5be/go.mod h1:SAOwJoakQ8EPjwNIsiakIQKsoKdkcbx8U3IapgCg9R0= github.com/filecoin-project/go-address v0.0.2-0.20200504173055-8b6f2fb2b3ef h1:Wi5E+P1QfHP8IF27eUiTx5vYfqQZwfPxzq3oFEq8w8U= @@ -223,7 +227,6 @@ github.com/filecoin-project/go-amt-ipld/v2 v2.0.1-0.20200424220931-6263827e49f2 github.com/filecoin-project/go-amt-ipld/v2 v2.0.1-0.20200424220931-6263827e49f2/go.mod h1:boRtQhzmxNocrMxOXo1NYn4oUc1NGvR8tEa79wApNXg= github.com/filecoin-project/go-bitfield v0.0.0-20200416002808-b3ee67ec9060/go.mod h1:iodsLxOFZnqKtjj2zkgqzoGNrv6vUqj69AT/J8DKXEw= github.com/filecoin-project/go-bitfield v0.0.1/go.mod h1:Ry9/iUlWSyjPUzlAvdnfy4Gtvrq4kWmWDztCU1yEgJY= -github.com/filecoin-project/go-bitfield v0.0.2-0.20200518150651-562fdb554b6e h1:gkG/7G+iKy4He+IiQNeQn+nndFznb/vCoOR8iRQsm60= github.com/filecoin-project/go-bitfield v0.0.2-0.20200518150651-562fdb554b6e/go.mod h1:Ry9/iUlWSyjPUzlAvdnfy4Gtvrq4kWmWDztCU1yEgJY= github.com/filecoin-project/go-bitfield v0.0.3/go.mod h1:Ry9/iUlWSyjPUzlAvdnfy4Gtvrq4kWmWDztCU1yEgJY= github.com/filecoin-project/go-bitfield v0.0.4-0.20200703174658-f4a5758051a1 h1:xuHlrdznafh7ul5t4xEncnA4qgpQvJZEw+mr98eqHXw= @@ -232,12 +235,13 @@ github.com/filecoin-project/go-cbor-util v0.0.0-20191219014500-08c40a1e63a2 h1:a github.com/filecoin-project/go-cbor-util v0.0.0-20191219014500-08c40a1e63a2/go.mod h1:pqTiPHobNkOVM5thSRsHYjyQfq7O5QSCMhvuu9JoDlg= github.com/filecoin-project/go-crypto v0.0.0-20191218222705-effae4ea9f03 h1:2pMXdBnCiXjfCYx/hLqFxccPoqsSveQFxVLvNxy9bus= github.com/filecoin-project/go-crypto v0.0.0-20191218222705-effae4ea9f03/go.mod h1:+viYnvGtUTgJRdy6oaeF4MTFKAfatX071MPDPBL11EQ= -github.com/filecoin-project/go-data-transfer v0.4.0 h1:xiC0qVZten8VtqEs5rRjyz2n/nZ8prbZSWvAr1V+CBE= -github.com/filecoin-project/go-data-transfer v0.4.0/go.mod h1:5ksROBkSREsb2O4h5vBcGMr9lXTpfeyjHo8o0yxf6FQ= -github.com/filecoin-project/go-fil-commcid v0.0.0-20200208005934-2b8bd03caca5 h1:yvQJCW9mmi9zy+51xA01Ea2X7/dL7r8eKDPuGUjRmbo= +github.com/filecoin-project/go-data-transfer v0.4.1-0.20200715144713-b3311844e1a5 h1:/OZ+nr0x3uMZCPrreuUbS5EUOFm9DDo4ljgdav8rp/s= +github.com/filecoin-project/go-data-transfer v0.4.1-0.20200715144713-b3311844e1a5/go.mod h1:duGDSKvsOxiKl6Dueh8DNA6ZbiM30PWUWlSKjo9ac+o= github.com/filecoin-project/go-fil-commcid v0.0.0-20200208005934-2b8bd03caca5/go.mod h1:JbkIgFF/Z9BDlvrJO1FuKkaWsH673/UdFaiVS6uIHlA= -github.com/filecoin-project/go-fil-markets v0.4.0 h1:toDPViYyQOHtUs6jl0KB9EzgdfCxXR11dZO/rqWbFtU= -github.com/filecoin-project/go-fil-markets v0.4.0/go.mod h1:VAH6h+sWuhPAsSwAS9Kecx8MI/dIjFkrLO8jJUmLWQc= +github.com/filecoin-project/go-fil-commcid v0.0.0-20200716160307-8f644712406f h1:GxJzR3oRIMTPtpZ0b7QF8FKPK6/iPAc7trhlL5k/g+s= +github.com/filecoin-project/go-fil-commcid v0.0.0-20200716160307-8f644712406f/go.mod h1:Eaox7Hvus1JgPrL5+M3+h7aSPHc0cVqpSxA+TxIEpZQ= +github.com/filecoin-project/go-fil-markets v0.4.1-0.20200715201050-c141144ea312 h1:oVZggNjDWZWEjomkxPl8U3jrOLURoS4QSZA6t4YU5BY= +github.com/filecoin-project/go-fil-markets v0.4.1-0.20200715201050-c141144ea312/go.mod h1:MvrpKOiETu39e9H167gdQzdzLNcvHsUp48UkXqPSdtU= github.com/filecoin-project/go-jsonrpc v0.1.1-0.20200602181149-522144ab4e24 h1:Jc7vkplmZYVuaEcSXGHDwefvZIdoyyaoGDLqSr8Svms= github.com/filecoin-project/go-jsonrpc v0.1.1-0.20200602181149-522144ab4e24/go.mod h1:j6zV//WXIIY5kky873Q3iIKt/ViOE8rcijovmpxrXzM= github.com/filecoin-project/go-padreader v0.0.0-20200210211231-548257017ca6 h1:92PET+sx1Hb4W/8CgFwGuxaKbttwY+UNspYZTvXY0vs= @@ -246,10 +250,9 @@ github.com/filecoin-project/go-paramfetch v0.0.1/go.mod h1:fZzmf4tftbwf9S37XRifo github.com/filecoin-project/go-paramfetch v0.0.2-0.20200218225740-47c639bab663/go.mod h1:fZzmf4tftbwf9S37XRifoJlz7nCjRdIrMGLR07dKLCc= github.com/filecoin-project/go-paramfetch v0.0.2-0.20200701152213-3e0f0afdc261 h1:A256QonvzRaknIIAuWhe/M2dpV2otzs3NBhi5TWa/UA= github.com/filecoin-project/go-paramfetch v0.0.2-0.20200701152213-3e0f0afdc261/go.mod h1:fZzmf4tftbwf9S37XRifoJlz7nCjRdIrMGLR07dKLCc= -github.com/filecoin-project/go-statemachine v0.0.0-20200226041606-2074af6d51d9 h1:k9qVR9ItcziSB2rxtlkN/MDWNlbsI6yzec+zjUatLW0= github.com/filecoin-project/go-statemachine v0.0.0-20200226041606-2074af6d51d9/go.mod h1:FGwQgZAt2Gh5mjlwJUlVB62JeYdo+if0xWxSEfBD9ig= -github.com/filecoin-project/go-statemachine v0.0.0-20200703171610-a74a697973b9 h1:NagIOq5osclBprc95ILEnGCOpubuhalqwWvayYJmXLQ= -github.com/filecoin-project/go-statemachine v0.0.0-20200703171610-a74a697973b9/go.mod h1:FGwQgZAt2Gh5mjlwJUlVB62JeYdo+if0xWxSEfBD9ig= +github.com/filecoin-project/go-statemachine v0.0.0-20200714194326-a77c3ae20989 h1:1GjCS3xy/CRIw7Tq0HfzX6Al8mklrszQZ3iIFnjPzHk= +github.com/filecoin-project/go-statemachine v0.0.0-20200714194326-a77c3ae20989/go.mod h1:FGwQgZAt2Gh5mjlwJUlVB62JeYdo+if0xWxSEfBD9ig= github.com/filecoin-project/go-statestore v0.1.0 h1:t56reH59843TwXHkMcwyuayStBIiWBRilQjQ+5IiwdQ= github.com/filecoin-project/go-statestore v0.1.0/go.mod h1:LFc9hD+fRxPqiHiaqUEZOinUJB4WARkRfNl10O7kTnI= github.com/filecoin-project/go-storedcounter v0.0.0-20200421200003-1c99c62e8a5b h1:fkRZSPrYpk42PV3/lIXiL0LHetxde7vyYYvSsttQtfg= @@ -257,6 +260,8 @@ github.com/filecoin-project/go-storedcounter v0.0.0-20200421200003-1c99c62e8a5b/ github.com/filecoin-project/sector-storage v0.0.0-20200615154852-728a47ab99d6/go.mod h1:M59QnAeA/oV+Z8oHFLoNpGMv0LZ8Rll+vHVXX7GirPM= github.com/filecoin-project/sector-storage v0.0.0-20200712023225-1d67dcfa3c15 h1:miw6hiusb/MkV1ryoqUKKWnvHhPW00AYtyeCj0L8pqo= github.com/filecoin-project/sector-storage v0.0.0-20200712023225-1d67dcfa3c15/go.mod h1:salgVdX7qeXFo/xaiEQE29J4pPkjn71T0kt0n+VDBzo= +github.com/filecoin-project/sector-storage v0.0.0-20200716210653-a846ac9b39ff h1:Hdk6IsANKd3sJEqpaOuI98jAuDWnffmOCQmlrd89/Hc= +github.com/filecoin-project/sector-storage v0.0.0-20200716210653-a846ac9b39ff/go.mod h1:7EE+f7jM4kCy2MKHoiiwNDQGJSb+QQzZ+y+/17ugq4w= github.com/filecoin-project/specs-actors v0.0.0-20200210130641-2d1fbd8672cf/go.mod h1:xtDZUB6pe4Pksa/bAJbJ693OilaC5Wbot9jMhLm3cZA= github.com/filecoin-project/specs-actors v0.3.0/go.mod h1:nQYnFbQ7Y0bHZyq6HDEuVlCPR+U3z5Q3wMOQ+2aiV+Y= github.com/filecoin-project/specs-actors v0.6.0/go.mod h1:dRdy3cURykh2R8O/DKqy8olScl70rmIS7GrB4hB1IDY= @@ -269,9 +274,13 @@ github.com/filecoin-project/specs-storage v0.1.0 h1:PkDgTOT5W5Ao7752onjDl4QSv+sg github.com/filecoin-project/specs-storage v0.1.0/go.mod h1:Pr5ntAaxsh+sLG/LYiL4tKzvA83Vk5vLODYhfNwOg7k= github.com/filecoin-project/specs-storage v0.1.1-0.20200622113353-88a9704877ea h1:iixjULRQFPn7Q9KlIqfwLJnlAXO10bbkI+xy5GKGdLY= github.com/filecoin-project/specs-storage v0.1.1-0.20200622113353-88a9704877ea/go.mod h1:Pr5ntAaxsh+sLG/LYiL4tKzvA83Vk5vLODYhfNwOg7k= +github.com/filecoin-project/storage-fsm v0.0.0-20200715191202-7e92e888bf41 h1:K2DI5+IKuY0cOjX/r1Agy6rYcAhU89LVNOjutCUib4g= +github.com/filecoin-project/storage-fsm v0.0.0-20200715191202-7e92e888bf41/go.mod h1:TDNjb0HYG2fppxWH5EsiNCZu97iJZNuPYmivSK13Ao0= github.com/filecoin-project/storage-fsm v0.0.0-20200717125541-d575c3a5f7f2 h1:A9zUXOMuVnSTp9a0i0KtHkB05hA8mRWVLls6Op9Czuo= github.com/filecoin-project/storage-fsm v0.0.0-20200717125541-d575c3a5f7f2/go.mod h1:1CGbd11KkHuyWPT+xwwCol1zl/jnlpiKD2L4fzKxaiI= github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568/go.mod h1:xEzjJPgXI435gkrCt3MPfRiAkVrwSbHsst4LCFVfpJc= +github.com/flynn/noise v0.0.0-20180327030543-2492fe189ae6 h1:u/UEqS66A5ckRmS4yNpjmVH56sVtS/RfclBAYocb4as= +github.com/flynn/noise v0.0.0-20180327030543-2492fe189ae6/go.mod h1:1i71OnUq3iUe1ma7Lr6yG6/rjvM3emb6yoL7xLFzcVQ= github.com/francoispqt/gojay v1.2.13 h1:d2m3sFjloqoIUQU3TsHBgj6qg/BVGlTBeHDUmyJnXKk= github.com/francoispqt/gojay v1.2.13/go.mod h1:ehT5mTG4ua4581f1++1WLG0vPdaA9HaiDsoyrBGkyDY= github.com/franela/goblin v0.0.0-20200105215937-c9ffbefa60db/go.mod h1:7dvUGVsVBjqR7JHJk0brhHOZYGmfBYOrK0ZhYMEtBr4= @@ -298,6 +307,7 @@ github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG github.com/go-ole/go-ole v1.2.4 h1:nNBDSCOigTSiarFpYE9J/KtEA1IOW4CNeqT9TQDqCxI= github.com/go-ole/go-ole v1.2.4/go.mod h1:XCwSNxSkXRo4vlyPy93sltvi/qJq0jqQhjqQNIwKuxM= github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= +github.com/go-sql-driver/mysql v1.5.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= github.com/go-stack/stack v1.8.0 h1:5SgMzNM5HxrEjV0ww2lTmX6E2Izsfxas4+YHWRs3Lsk= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/godbus/dbus v0.0.0-20190402143921-271e53dc4968 h1:s+PDl6lozQ+dEUtUtQnO7+A2iPG3sK1pI4liU+jxn90= @@ -305,7 +315,6 @@ github.com/godbus/dbus v0.0.0-20190402143921-271e53dc4968/go.mod h1:/YcGZj5zSblf github.com/godbus/dbus/v5 v5.0.3 h1:ZqHaoEF7TBzh4jzPmqVhE/5A1z9of6orkAe5uHoAeME= github.com/godbus/dbus/v5 v5.0.3/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/gogo/googleapis v0.0.0-20180223154316-0cd9801be74a/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= -github.com/gogo/googleapis v1.1.0 h1:kFkMAZBNAn4j7K0GiZr8cRYzejq68VbheufiV3YuyFI= github.com/gogo/googleapis v1.1.0/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= github.com/gogo/googleapis v1.4.0 h1:zgVt4UpGxcqVOw97aRGxT4svlcmdK35fynLNctY32zI= github.com/gogo/googleapis v1.4.0/go.mod h1:5YRNX2z1oM5gXdAkurHa942MDgEJyk02w4OecKY87+c= @@ -315,13 +324,11 @@ github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zV github.com/gogo/protobuf v1.3.0/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.1 h1:DqDEcV5aeaTmdFBePNpYsp3FlcVH/2ISVVM9Qf8PSls= github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= -github.com/gogo/status v1.0.3 h1:WkVBY59mw7qUNTr/bLwO7J2vesJ0rQ2C3tMXrTd3w5M= github.com/gogo/status v1.0.3/go.mod h1:SavQ51ycCLnc7dGyJxp8YAmudx8xqiVrRf+6IXRsugc= github.com/gogo/status v1.1.0 h1:+eIkrewn5q6b30y+g/BJINVVdi2xH7je5MPJ3ZPK3JA= github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY1WM= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6 h1:ZgQEtGgCBiWRM39fZuwSd1LwSqqSW0hOdXCYYDX0R3I= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e h1:1r7pUrabqp18hOBcwBwiTsbnFeTZHV9eER/QT5JVZxY= @@ -330,7 +337,6 @@ github.com/golang/lint v0.0.0-20180702182130-06c8688daad7/go.mod h1:tluoj9z5200j github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= -github.com/golang/mock v1.4.0 h1:Rd1kQnQu0Hq3qvJppYSG0HtP+f5LPPUiDswTLiEegLg= github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.3 h1:GV+pQPG/EUUbkh47niozDcADz6go/dUwhVzdUQHIVRw= github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= @@ -344,7 +350,6 @@ github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= -github.com/golang/protobuf v1.4.0 h1:oOuy+ugB+P/kBdUnG5QaMXSIyJ1q38wWSojYCb3z5VQ= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8= github.com/golang/protobuf v1.4.2 h1:+Z5KGCizgyZCbGh1KZqA0fcLLkwbsjIzS4aV2v7wJX0= @@ -396,7 +401,6 @@ github.com/gorilla/websocket v1.4.2 h1:+/TMaTYc4QFitKJxsQ7Yye35DkWvkdLcvGKqM+x0U github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= -github.com/grpc-ecosystem/go-grpc-middleware v1.1.0 h1:THDBEeQ9xZ8JEaCLyLQqXMMdRqNr0QAUJTIkQAUtFjg= github.com/grpc-ecosystem/go-grpc-middleware v1.1.0/go.mod h1:f5nM7jw/oeRSadq3xCzHAvxcr8HZnzsqU6ILg/0NiiE= github.com/grpc-ecosystem/go-grpc-middleware v1.2.0 h1:0IKlLyQ3Hs9nDaiK5cSHAGmcQEIC8l2Ts1u6x5Dfrqg= github.com/grpc-ecosystem/go-grpc-middleware v1.2.0/go.mod h1:mJzapYve32yjrKlk9GbyCZHuPgZsrbyIbyKhSzOpg6s= @@ -469,7 +473,6 @@ github.com/ipfs/go-block-format v0.0.2/go.mod h1:AWR46JfpcObNfg3ok2JHDUfdiHRgWhJ github.com/ipfs/go-blockservice v0.0.3/go.mod h1:/NNihwTi6V2Yr6g8wBI+BSwPuURpBRMtYNGrlxZ8KuI= github.com/ipfs/go-blockservice v0.0.7/go.mod h1:EOfb9k/Y878ZTRY/CH0x5+ATtaipfbRhbvNSdgc/7So= github.com/ipfs/go-blockservice v0.1.0/go.mod h1:hzmMScl1kXHg3M2BjTymbVPjv627N7sYcvYaKbop39M= -github.com/ipfs/go-blockservice v0.1.3 h1:9XgsPMwwWJSC9uVr2pMDsW2qFTBSkxpGMhmna8mIjPM= github.com/ipfs/go-blockservice v0.1.3/go.mod h1:OTZhFpkgY48kNzbgyvcexW9cHrpjBYIjSR0KoDOFOLU= github.com/ipfs/go-blockservice v0.1.4-0.20200624145336-a978cec6e834 h1:hFJoI1D2a3MqiNkSb4nKwrdkhCngUxUTFNwVwovZX2s= github.com/ipfs/go-blockservice v0.1.4-0.20200624145336-a978cec6e834/go.mod h1:OTZhFpkgY48kNzbgyvcexW9cHrpjBYIjSR0KoDOFOLU= @@ -479,7 +482,6 @@ github.com/ipfs/go-cid v0.0.3/go.mod h1:GHWU/WuQdMPmIosc4Yn1bcCT7dSeX4lBafM7iqUP github.com/ipfs/go-cid v0.0.4-0.20191112011718-79e75dffeb10/go.mod h1:/BYOuUoxkE+0f6tGzlzMvycuN+5l35VOR4Bpg2sCmds= github.com/ipfs/go-cid v0.0.4/go.mod h1:4LLaPOQwmk5z9LBgQnpkivrx8BJjUyGwTXCd5Xfj6+M= github.com/ipfs/go-cid v0.0.5/go.mod h1:plgt+Y5MnOey4vO4UlUazGqdbEXuFYitED67FexhXog= -github.com/ipfs/go-cid v0.0.6-0.20200501230655-7c82f3b81c00 h1:QN88Q0kT2QiDaLxpR/SDsqOBtNIEF/F3n96gSDUimkA= github.com/ipfs/go-cid v0.0.6-0.20200501230655-7c82f3b81c00/go.mod h1:plgt+Y5MnOey4vO4UlUazGqdbEXuFYitED67FexhXog= github.com/ipfs/go-cid v0.0.6 h1:go0y+GcDOGeJIV01FeBsta4FHngoA4Wz7KMeLkXAhMs= github.com/ipfs/go-cid v0.0.6/go.mod h1:6Ux9z5e+HpkQdckYoX1PG/6xqKspzlEIR5SDmgqgC/I= @@ -503,7 +505,6 @@ github.com/ipfs/go-ds-badger v0.0.7/go.mod h1:qt0/fWzZDoPW6jpQeqUjR5kBfhDNB65jd9 github.com/ipfs/go-ds-badger v0.2.1/go.mod h1:Tx7l3aTph3FMFrRS838dcSJh+jjA7cX9DrGVwx/NOwE= github.com/ipfs/go-ds-badger v0.2.3 h1:J27YvAcpuA5IvZUbeBxOcQgqnYHUPxoygc6QxxkodZ4= github.com/ipfs/go-ds-badger v0.2.3/go.mod h1:pEYw0rgg3FIrywKKnL+Snr+w/LjJZVMTBRn4FS6UHUk= -github.com/ipfs/go-ds-badger2 v0.1.0 h1:784py6lXkwlVF+K6XSuqmdMgy5l8GI6k60ngBokb9Fg= github.com/ipfs/go-ds-badger2 v0.1.0/go.mod h1:pbR1p817OZbdId9EvLOhKBgUVTM3BMCSTan78lDDVaw= github.com/ipfs/go-ds-badger2 v0.1.1-0.20200708190120-187fc06f714e h1:Xi1nil8K2lBOorBS6Ys7+hmUCzH8fr3U9ipdL/IrcEI= github.com/ipfs/go-ds-badger2 v0.1.1-0.20200708190120-187fc06f714e/go.mod h1:lJnws7amT9Ehqzta0gwMrRsURU04caT0iRPr1W8AsOU= @@ -518,11 +519,10 @@ github.com/ipfs/go-filestore v1.0.0 h1:QR7ekKH+q2AGiWDc7W2Q0qHuYSRZGUJqUn0GsegEP github.com/ipfs/go-filestore v1.0.0/go.mod h1:/XOCuNtIe2f1YPbiXdYvD0BKLA0JR1MgPiFOdcuu9SM= github.com/ipfs/go-fs-lock v0.0.1 h1:XHX8uW4jQBYWHj59XXcjg7BHlHxV9ZOYs6Y43yb7/l0= github.com/ipfs/go-fs-lock v0.0.1/go.mod h1:DNBekbboPKcxs1aukPSaOtFA3QfSdi5C855v0i9XJ8Y= -github.com/ipfs/go-graphsync v0.0.6-0.20200708073926-caa872f68b2c h1:fCW8JzwvBMfODvdliK+s3ziYZPD/5FAzluahZYXVg3k= -github.com/ipfs/go-graphsync v0.0.6-0.20200708073926-caa872f68b2c/go.mod h1:jMXfqIEDFukLPZHqDPp8tJMbHO9Rmeb9CEGevngQbmE= +github.com/ipfs/go-graphsync v0.0.6-0.20200715142715-e2f27c4754e6 h1:+dQnaRkLV4za46Gfw6b1KNVOCcGDrdnEGZrjz3kF80k= +github.com/ipfs/go-graphsync v0.0.6-0.20200715142715-e2f27c4754e6/go.mod h1:jMXfqIEDFukLPZHqDPp8tJMbHO9Rmeb9CEGevngQbmE= github.com/ipfs/go-hamt-ipld v0.0.15-0.20200131012125-dd88a59d3f2e/go.mod h1:9aQJu/i/TaRDW6jqB5U217dLIDopn50wxLdHXM2CTfE= github.com/ipfs/go-hamt-ipld v0.0.15-0.20200204200533-99b8553ef242/go.mod h1:kq3Pi+UP3oHhAdKexE+kHHYRKMoFNuGero0R7q3hWGg= -github.com/ipfs/go-hamt-ipld v0.1.1-0.20200501020327-d53d20a7063e h1:Klv6s+kbuhh0JVpGFmFK2t6AtZxJfAnVneQHh1DlFOo= github.com/ipfs/go-hamt-ipld v0.1.1-0.20200501020327-d53d20a7063e/go.mod h1:giiPqWYCnRBYpNTsJ/EX1ojldX5kTXrXYckSJQ7ko9M= github.com/ipfs/go-hamt-ipld v0.1.1-0.20200605182717-0310ad2b0b1f h1:mchhWiYYUSoCuE3wDfRCo8cho5kqSoxkgnOtGcnNMZw= github.com/ipfs/go-hamt-ipld v0.1.1-0.20200605182717-0310ad2b0b1f/go.mod h1:phOFBB7W73N9dg1glcb1fQ9HtQFDUpeyJgatW8ns0bw= @@ -568,7 +568,6 @@ github.com/ipfs/go-ipfs-pq v0.0.2/go.mod h1:LWIqQpqfRG3fNc5XsnIhz/wQ2XXGyugQwls7 github.com/ipfs/go-ipfs-routing v0.0.1/go.mod h1:k76lf20iKFxQTjcJokbPM9iBXVXVZhcOwc360N4nuKs= github.com/ipfs/go-ipfs-routing v0.1.0 h1:gAJTT1cEeeLj6/DlLX6t+NxD9fQe2ymTO6qWRDI/HQQ= github.com/ipfs/go-ipfs-routing v0.1.0/go.mod h1:hYoUkJLyAUKhF58tysKpids8RNDPO42BVMgK5dNsoqY= -github.com/ipfs/go-ipfs-util v0.0.1 h1:Wz9bL2wB2YBJqggkA4dD7oSmqB4cAnpNbGrlHJulv50= github.com/ipfs/go-ipfs-util v0.0.1/go.mod h1:spsl5z8KUnrve+73pOhSVZND1SIxPW5RyBCNzQxlJBc= github.com/ipfs/go-ipfs-util v0.0.2 h1:59Sswnk1MFaiq+VcaknX7aYEyGyGDAA73ilhEK2POp8= github.com/ipfs/go-ipfs-util v0.0.2/go.mod h1:CbPtkWJzjLdEcezDns2XYaehFVNXG9zrdrtMecczcsQ= @@ -658,6 +657,7 @@ github.com/jessevdk/go-flags v0.0.0-20141203071132-1679536dcc89/go.mod h1:4FA24M github.com/jessevdk/go-flags v1.4.0 h1:4IU2WS7AumrZ/40jfhf4QVDMsQwqA7VEHozFRrGARJA= github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= +github.com/jmespath/go-jmespath v0.3.0/go.mod h1:9QtRXoHjLGCJ5IBSaohpXITPlowMeeYCZ7fLUTSywik= github.com/joeshaw/multierror v0.0.0-20140124173710-69b34d4ec901 h1:rp+c0RAYOWj8l6qbCUTSiRLG/iKnW3K3/QfPPuSsBt4= github.com/joeshaw/multierror v0.0.0-20140124173710-69b34d4ec901/go.mod h1:Z86h9688Y0wesXCyonoVr47MasHilkuLMqGhRZ4Hpak= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= @@ -688,7 +688,6 @@ github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvW github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6CZQHDETBtE9HaSEkGmuNXF86RwHhHUvq4= -github.com/konsorten/go-windows-terminal-sequences v1.0.1 h1:mweAR1A6xJ3oS2pRaGiHgQ4OO8tzTaLawm8vnODuwDk= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.3 h1:CE8S1cTafDpPvMhIxNJKvHsGVBgn1xWYf1NbHQhywc8= github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= @@ -735,6 +734,7 @@ github.com/libp2p/go-libp2p v0.6.0/go.mod h1:mfKWI7Soz3ABX+XEBR61lGbg+ewyMtJHVt0 github.com/libp2p/go-libp2p v0.6.1/go.mod h1:CTFnWXogryAHjXAKEbOf1OWY+VeAP3lDMZkfEI5sT54= github.com/libp2p/go-libp2p v0.7.0/go.mod h1:hZJf8txWeCduQRDC/WSqBGMxaTHCOYHt2xSU1ivxn0k= github.com/libp2p/go-libp2p v0.7.4/go.mod h1:oXsBlTLF1q7pxr+9w6lqzS1ILpyHsaBPniVO7zIHGMw= +github.com/libp2p/go-libp2p v0.8.1/go.mod h1:QRNH9pwdbEBpx5DTJYg+qxcVaDMAz3Ee/qDKwXujH5o= github.com/libp2p/go-libp2p v0.8.2/go.mod h1:NQDA/F/qArMHGe0J7sDScaKjW8Jh4y/ozQqBbYJ+BnA= github.com/libp2p/go-libp2p v0.8.3/go.mod h1:EsH1A+8yoWK+L4iKcbPYu6MPluZ+CHWI9El8cTaefiM= github.com/libp2p/go-libp2p v0.9.2/go.mod h1:cunHNLDVus66Ct9iXXcjKRLdmHdFdHVe1TAnbubJQqQ= @@ -763,7 +763,6 @@ github.com/libp2p/go-libp2p-circuit v0.1.1/go.mod h1:Ahq4cY3V9VJcHcn1SBXjr78AbFk github.com/libp2p/go-libp2p-circuit v0.1.3/go.mod h1:Xqh2TjSy8DD5iV2cCOMzdynd6h8OTBGoV1AWbWor3qM= github.com/libp2p/go-libp2p-circuit v0.1.4/go.mod h1:CY67BrEjKNDhdTk8UgBX1Y/H5c3xkAcs3gnksxY7osU= github.com/libp2p/go-libp2p-circuit v0.2.1/go.mod h1:BXPwYDN5A8z4OEY9sOfr2DUQMLQvKt/6oku45YUmjIo= -github.com/libp2p/go-libp2p-circuit v0.2.2 h1:87RLabJ9lrhoiSDDZyCJ80ZlI5TLJMwfyoGAaWXzWqA= github.com/libp2p/go-libp2p-circuit v0.2.2/go.mod h1:nkG3iE01tR3FoQ2nMm06IUrCpCyJp1Eo4A1xYdpjfs4= github.com/libp2p/go-libp2p-circuit v0.2.3 h1:3Uw1fPHWrp1tgIhBz0vSOxRUmnKL8L/NGUyEd5WfSGM= github.com/libp2p/go-libp2p-circuit v0.2.3/go.mod h1:nkG3iE01tR3FoQ2nMm06IUrCpCyJp1Eo4A1xYdpjfs4= @@ -791,7 +790,6 @@ github.com/libp2p/go-libp2p-core v0.5.3/go.mod h1:uN7L2D4EvPCvzSH5SrhR72UWbnSGpt github.com/libp2p/go-libp2p-core v0.5.4/go.mod h1:uN7L2D4EvPCvzSH5SrhR72UWbnSGpt5/a35Sm4upn4Y= github.com/libp2p/go-libp2p-core v0.5.5/go.mod h1:vj3awlOr9+GMZJFH9s4mpt9RHHgGqeHCopzbYKZdRjM= github.com/libp2p/go-libp2p-core v0.5.6/go.mod h1:txwbVEhHEXikXn9gfC7/UDDw7rkxuX0bJvM49Ykaswo= -github.com/libp2p/go-libp2p-core v0.5.7 h1:QK3xRwFxqd0Xd9bSZL+8yZ8ncZZbl6Zngd/+Y+A6sgQ= github.com/libp2p/go-libp2p-core v0.5.7/go.mod h1:txwbVEhHEXikXn9gfC7/UDDw7rkxuX0bJvM49Ykaswo= github.com/libp2p/go-libp2p-core v0.6.0 h1:u03qofNYTBN+yVg08PuAKylZogVf0xcTEeM8skGf+ak= github.com/libp2p/go-libp2p-core v0.6.0/go.mod h1:txwbVEhHEXikXn9gfC7/UDDw7rkxuX0bJvM49Ykaswo= @@ -839,6 +837,8 @@ github.com/libp2p/go-libp2p-net v0.0.2/go.mod h1:Yt3zgmlsHOgUWSXmt5V/Jpz9upuJBE8 github.com/libp2p/go-libp2p-netutil v0.0.1/go.mod h1:GdusFvujWZI9Vt0X5BKqwWWmZFxecf9Gt03cKxm2f/Q= github.com/libp2p/go-libp2p-netutil v0.1.0 h1:zscYDNVEcGxyUpMd0JReUZTrpMfia8PmLKcKF72EAMQ= github.com/libp2p/go-libp2p-netutil v0.1.0/go.mod h1:3Qv/aDqtMLTUyQeundkKsA+YCThNdbQD54k3TqjpbFU= +github.com/libp2p/go-libp2p-noise v0.1.1 h1:vqYQWvnIcHpIoWJKC7Al4D6Hgj0H012TuXRhPwSMGpQ= +github.com/libp2p/go-libp2p-noise v0.1.1/go.mod h1:QDFLdKX7nluB7DEnlVPbz7xlLHdwHFA9HiohJRr3vwM= github.com/libp2p/go-libp2p-peer v0.0.1/go.mod h1:nXQvOBbwVqoP+T5Y5nCjeH4sP9IX/J0AMzcDUVruVoo= github.com/libp2p/go-libp2p-peer v0.1.1/go.mod h1:jkF12jGB4Gk/IOo+yomm+7oLWxF278F7UnrYUQ1Q8es= github.com/libp2p/go-libp2p-peer v0.2.0 h1:EQ8kMjaCUwt/Y5uLgjT8iY2qg0mGUT0N1zUjer50DsY= @@ -852,7 +852,6 @@ github.com/libp2p/go-libp2p-peerstore v0.2.0/go.mod h1:N2l3eVIeAitSg3Pi2ipSrJYnq github.com/libp2p/go-libp2p-peerstore v0.2.1/go.mod h1:NQxhNjWxf1d4w6PihR8btWIRjwRLBr4TYKfNgrUkOPA= github.com/libp2p/go-libp2p-peerstore v0.2.2/go.mod h1:NQxhNjWxf1d4w6PihR8btWIRjwRLBr4TYKfNgrUkOPA= github.com/libp2p/go-libp2p-peerstore v0.2.3/go.mod h1:K8ljLdFn590GMttg/luh4caB/3g0vKuY01psze0upRw= -github.com/libp2p/go-libp2p-peerstore v0.2.4 h1:jU9S4jYN30kdzTpDAR7SlHUD+meDUjTODh4waLWF1ws= github.com/libp2p/go-libp2p-peerstore v0.2.4/go.mod h1:ss/TWTgHZTMpsU/oKVVPQCGuDHItOpf2W8RxAi50P2s= github.com/libp2p/go-libp2p-peerstore v0.2.6 h1:2ACefBX23iMdJU9Ke+dcXt3w86MIryes9v7In4+Qq3U= github.com/libp2p/go-libp2p-peerstore v0.2.6/go.mod h1:ss/TWTgHZTMpsU/oKVVPQCGuDHItOpf2W8RxAi50P2s= @@ -1089,7 +1088,6 @@ github.com/multiformats/go-multiaddr-net v0.1.4/go.mod h1:ilNnaM9HbmVFqsb/qcNysj github.com/multiformats/go-multiaddr-net v0.1.5 h1:QoRKvu0xHN1FCFJcMQLbG/yQE2z441L5urvG3+qyz7g= github.com/multiformats/go-multiaddr-net v0.1.5/go.mod h1:ilNnaM9HbmVFqsb/qcNysjCu4PVONlrBZpHIrw/qQuA= github.com/multiformats/go-multibase v0.0.1/go.mod h1:bja2MqRZ3ggyXtZSEDKpl0uO/gviWFaSteVbWT51qgs= -github.com/multiformats/go-multibase v0.0.2 h1:2pAgScmS1g9XjH7EtAfNhTuyrWYEWcxy0G5Wo85hWDA= github.com/multiformats/go-multibase v0.0.2/go.mod h1:bja2MqRZ3ggyXtZSEDKpl0uO/gviWFaSteVbWT51qgs= github.com/multiformats/go-multibase v0.0.3 h1:l/B6bJDQjvQ5G52jw4QGSYeOTZoAwIO77RblWplfIqk= github.com/multiformats/go-multibase v0.0.3/go.mod h1:5+1R4eQrT3PkYZ24C3W2Ue2tPwIdYQD509ZjSb5y9Oc= @@ -1099,8 +1097,9 @@ github.com/multiformats/go-multihash v0.0.7/go.mod h1:XuKXPp8VHcTygube3OWZC+aZrA github.com/multiformats/go-multihash v0.0.8/go.mod h1:YSLudS+Pi8NHE7o6tb3D8vrpKa63epEDmG8nTduyAew= github.com/multiformats/go-multihash v0.0.9/go.mod h1:YSLudS+Pi8NHE7o6tb3D8vrpKa63epEDmG8nTduyAew= github.com/multiformats/go-multihash v0.0.10/go.mod h1:YSLudS+Pi8NHE7o6tb3D8vrpKa63epEDmG8nTduyAew= -github.com/multiformats/go-multihash v0.0.13 h1:06x+mk/zj1FoMsgNejLpy6QTvJqlSt/BhLEy87zidlc= github.com/multiformats/go-multihash v0.0.13/go.mod h1:VdAWLKTwram9oKAatUcLxBNUjdtcVwxObEQBtRfuyjc= +github.com/multiformats/go-multihash v0.0.14 h1:QoBceQYQQtNUuf6s7wHxnE2c8bhbMqhfGzNI032se/I= +github.com/multiformats/go-multihash v0.0.14/go.mod h1:VdAWLKTwram9oKAatUcLxBNUjdtcVwxObEQBtRfuyjc= github.com/multiformats/go-multistream v0.0.1/go.mod h1:fJTiDfXJVmItycydCnNx4+wSzZ5NwG2FEVAI30fiovg= github.com/multiformats/go-multistream v0.0.4/go.mod h1:fJTiDfXJVmItycydCnNx4+wSzZ5NwG2FEVAI30fiovg= github.com/multiformats/go-multistream v0.1.0/go.mod h1:fJTiDfXJVmItycydCnNx4+wSzZ5NwG2FEVAI30fiovg= @@ -1143,12 +1142,10 @@ github.com/onsi/gomega v1.8.1/go.mod h1:Ho0h+IUsWyvy1OpqCwxlQ/21gkhVunqlU8fDGcoT github.com/onsi/gomega v1.9.0 h1:R1uwffexN6Pr340GtYRIdZmAiN4J+iw6WG4wog1DUXg= github.com/onsi/gomega v1.9.0/go.mod h1:Ho0h+IUsWyvy1OpqCwxlQ/21gkhVunqlU8fDGcoTdcA= github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= -github.com/opentracing-contrib/go-grpc v0.0.0-20180928155321-4b5a12d3ff02 h1:0R5mDLI66Qw13qN80TRz85zthQ2nf2+uDyiV23w6c3Q= github.com/opentracing-contrib/go-grpc v0.0.0-20180928155321-4b5a12d3ff02/go.mod h1:JNdpVEzCpXBgIiv4ds+TzhN1hrtxq6ClLrTlT9OQRSc= github.com/opentracing-contrib/go-grpc v0.0.0-20191001143057-db30781987df h1:vdYtBU6zvL7v+Tr+0xFM/qhahw/EvY8DMMunZHKH6eE= github.com/opentracing-contrib/go-grpc v0.0.0-20191001143057-db30781987df/go.mod h1:DYR5Eij8rJl8h7gblRrOZ8g0kW1umSpKqYIBTgeDtLo= github.com/opentracing-contrib/go-observer v0.0.0-20170622124052-a52f23424492/go.mod h1:Ngi6UdF0k5OKD5t5wlmGhe/EDKPoUM3BXZSSfIuJbis= -github.com/opentracing-contrib/go-stdlib v0.0.0-20190519235532-cf7a6c988dc9 h1:QsgXACQhd9QJhEmRumbsMQQvBtmdS0mafoVEBplWXEg= github.com/opentracing-contrib/go-stdlib v0.0.0-20190519235532-cf7a6c988dc9/go.mod h1:PLldrQSroqzH70Xl+1DQcGnefIbqsKR7UDaiux3zV+w= github.com/opentracing-contrib/go-stdlib v1.0.0 h1:TBS7YuVotp8myLon4Pv7BtCBzOTo1DeZCld0Z63mW2w= github.com/opentracing-contrib/go-stdlib v1.0.0/go.mod h1:qtI1ogk+2JhVPIXVc6q+NHziSmy2W5GbdQZFUHADCBU= @@ -1204,7 +1201,6 @@ github.com/prometheus/common v0.2.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y8 github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.6.0/go.mod h1:eBmuwkDJBwy6iBfxCBob6t6dR6ENT/y+J+Zk0j9GMYc= github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt26CguLLsqA= -github.com/prometheus/common v0.9.1 h1:KOMtN28tlbam3/7ZKEYKHhKoJZYYj3gMH4uc62x7X7U= github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= github.com/prometheus/common v0.10.0 h1:RyRA7RzGXQZiW+tGMr7sxa85G1z0yOpM1qq5c8lNawc= github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= @@ -1217,10 +1213,11 @@ github.com/prometheus/procfs v0.0.0-20190425082905-87a4384529e0/go.mod h1:TjEm7z github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= github.com/prometheus/procfs v0.0.3/go.mod h1:4A/X28fw3Fc593LaREMrKMqOKvUAntwMDaekg4FpcdQ= github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= -github.com/prometheus/procfs v0.0.11 h1:DhHlBtkHWPYi8O2y31JkK0TF+DGM+51OopZjH/Ia5qI= github.com/prometheus/procfs v0.0.11/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= github.com/prometheus/procfs v0.1.0 h1:jhMy6QXfi3y2HEzFoyuCj40z4OZIIHHPtFyCMftmvKA= github.com/prometheus/procfs v0.1.0/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= +github.com/raulk/clock v1.1.0 h1:dpb29+UKMbLqiU/jqIJptgLR1nn23HLgMY0sTCDza5Y= +github.com/raulk/clock v1.1.0/go.mod h1:3MpVxdZ/ODBQDxbN+kzshf5OSZwPjtMDx6BBXBmOeY0= github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= @@ -1266,7 +1263,6 @@ github.com/shurcooL/users v0.0.0-20180125191416-49c67e49c537/go.mod h1:QJTqeLYED github.com/shurcooL/webdavfs v0.0.0-20170829043945-18c3829fa133/go.mod h1:hKmq5kWdCj2z2KEozexVbfEZIWiTjhE0+UjmZgPqehw= github.com/siebenmann/go-kstat v0.0.0-20160321171754-d34789b79745/go.mod h1:G81aIFAMS9ECrwBYR9YxhlPjWgrItd+Kje78O6+uqm8= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= -github.com/sirupsen/logrus v1.4.2 h1:SPIRibHv4MatM3XXNO2BJeFLZwZ2LvZgfQ5+UNI2im4= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.6.0 h1:UBcNElsrwanuuMsnGSlYmtmgbb23qDR5dG+6X6Oo89I= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= @@ -1310,7 +1306,6 @@ github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoH github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= -github.com/stretchr/testify v1.5.1 h1:nOGnQDM7FYENwehXlg/kFVnos3rEvtKTjRvOWSzb6H4= github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.6.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.6.1 h1:hDPOHmpOpP40lSULcqw7IrRb/u7w6RpDC9399XyoNd0= @@ -1473,7 +1468,6 @@ golang.org/x/crypto v0.0.0-20200221231518-2aa609cf4a9d/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200317142112-1b76d66859c6/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200423211502-4bdfaf469ed5/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200427165652-729f1e841bcc/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37 h1:cg5LA/zNPRzIXIWSCxQW10Rvpy94aQh3LT/ShoCpkHw= golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200604202706-70a84ac30bf9 h1:vEg9joUBmeBcK9iSJftGNf3coIG4HqZElCPehJsfAYM= golang.org/x/crypto v0.0.0-20200604202706-70a84ac30bf9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= @@ -1549,7 +1543,6 @@ golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20200222125558-5a598a2470a0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200519113804-d87ec0cfa476 h1:E7ct1C6/33eOdrGZKMoyntcEvs2dwZnDe30crG5vpYU= golang.org/x/net v0.0.0-20200519113804-d87ec0cfa476/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200602114024-627f9648deb9 h1:pNX+40auqi2JqRfOP1akLGtYcn15TUbkhwuCO3foqqM= golang.org/x/net v0.0.0-20200602114024-627f9648deb9/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= @@ -1566,7 +1559,6 @@ golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e h1:vcxGaoTs7kV8m5Np9uUNQin4BrLOthgV7252N8V+FwY= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a h1:WXEvlFVvvGxCJLG6REjsT03iWnKLEWinaScsxF2Vm2o= golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -1634,7 +1626,6 @@ golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200420163511-1957bb5e6d1f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200427175716-29b57079015a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200509044756-6aff5f38e54f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200519105757-fe76b779f299 h1:DYfZAGf2WMFjMxbgTjaC+2HC7NkNAQs+6Q8b9WEB/F4= golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200602225109-6fdc65e7d980 h1:OjiUf46hAmXblsZdnoSXsEUSKU8r1UEzcL5RVZ4gO9Y= golang.org/x/sys v0.0.0-20200602225109-6fdc65e7d980/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1691,7 +1682,6 @@ golang.org/x/tools v0.0.0-20200207183749-b753a1ba74fa/go.mod h1:TB2adYChydJhpapK golang.org/x/tools v0.0.0-20200212150539-ea181f53ac56/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200216192241-b320d3a0f5a2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200224181240-023911ca70b2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200318150045-ba25ddc85566 h1:OXjomkWHhzUx4+HldlJ2TsMxJdWgEo5CTtspD1wdhdk= golang.org/x/tools v0.0.0-20200318150045-ba25ddc85566/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8= golang.org/x/tools v0.0.0-20200331025713-a30bf2db82d4 h1:kDtqNkeBrZb8B+atrj50B5XLHpzXXqcCdZPP/ApQ5NY= golang.org/x/tools v0.0.0-20200331025713-a30bf2db82d4/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8= @@ -1703,7 +1693,6 @@ google.golang.org/api v0.0.0-20180910000450-7ca32eb868bf/go.mod h1:4mhQ8q/RsB7i+ google.golang.org/api v0.0.0-20181030000543-1d582fd0359e/go.mod h1:4mhQ8q/RsB7i+udVvVy5NUi08OU8ZlA0gRVgrF7VFY0= google.golang.org/api v0.1.0/go.mod h1:UGEZY7KEX120AnNLIHFMKIo4obdJhkp2tPbaPlQx13Y= google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk= -google.golang.org/api v0.3.2 h1:iTp+3yyl/KOtxa/d1/JUE0GGSoR6FuW5udver22iwpw= google.golang.org/api v0.3.2/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= @@ -1768,17 +1757,16 @@ google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQ google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= -google.golang.org/grpc v1.28.0 h1:bO/TA4OxCOummhSf10siHuG7vJOiwh7SpRpFZDkOgl4= google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60= google.golang.org/grpc v1.29.1 h1:EC2SB8S04d2r73uptxphDSUG+kTKVgjRPF+N3xpxRB4= google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3IjizoKk= +google.golang.org/grpc/cmd/protoc-gen-go-grpc v0.0.0-20200617041141-9a465503579e/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.23.0 h1:4MY060fB1DLGMB/7MBTLnwQUY6+F09GEiz6SsrNqyzM= google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= google.golang.org/protobuf v1.24.0 h1:UhZDfRO8JRQru4/+LlLE0BRKGF8L+PICnvYZmx/fEGA= diff --git a/journal/journal.go b/journal/journal.go index b664e8fa7..8d509d51c 100644 --- a/journal/journal.go +++ b/journal/journal.go @@ -10,6 +10,8 @@ import ( logging "github.com/ipfs/go-log" "golang.org/x/xerrors" + + "github.com/filecoin-project/lotus/build" ) func InitializeSystemJournal(dir string) error { @@ -103,7 +105,7 @@ func (fsj *fsJournal) rollJournalFile() error { fsj.fi.Close() } - nfi, err := os.Create(filepath.Join(fsj.journalDir, fmt.Sprintf("lotus-journal-%s.ndjson", time.Now().Format(time.RFC3339)))) + nfi, err := os.Create(filepath.Join(fsj.journalDir, fmt.Sprintf("lotus-journal-%s.ndjson", build.Clock.Now().Format(time.RFC3339)))) if err != nil { return xerrors.Errorf("failed to open journal file: %w", err) } @@ -130,7 +132,7 @@ func (fsj *fsJournal) runLoop() { func (fsj *fsJournal) AddEntry(system string, obj interface{}) { je := &JournalEntry{ System: system, - Timestamp: time.Now(), + Timestamp: build.Clock.Now(), Val: obj, } select { diff --git a/lib/cachebs/cachebs.go b/lib/cachebs/cachebs.go new file mode 100644 index 000000000..5d997137d --- /dev/null +++ b/lib/cachebs/cachebs.go @@ -0,0 +1,86 @@ +package cachebs + +import ( + "context" + + lru "github.com/hashicorp/golang-lru" + block "github.com/ipfs/go-block-format" + "github.com/ipfs/go-cid" + blockstore "github.com/ipfs/go-ipfs-blockstore" + bstore "github.com/ipfs/go-ipfs-blockstore" + logging "github.com/ipfs/go-log/v2" +) + +var log = logging.Logger("cachebs") + +type CacheBS struct { + cache *lru.ARCCache + bs bstore.Blockstore +} + +func NewBufferedBstore(base blockstore.Blockstore, size int) *CacheBS { + c, err := lru.NewARC(size) + if err != nil { + panic(err) + } + return &CacheBS{ + cache: c, + bs: base, + } +} + +var _ (bstore.Blockstore) = &CacheBS{} + +func (bs *CacheBS) AllKeysChan(ctx context.Context) (<-chan cid.Cid, error) { + return bs.bs.AllKeysChan(ctx) +} + +func (bs *CacheBS) DeleteBlock(c cid.Cid) error { + bs.cache.Remove(c) + + return bs.bs.DeleteBlock(c) +} + +func (bs *CacheBS) Get(c cid.Cid) (block.Block, error) { + v, ok := bs.cache.Get(c) + if ok { + return v.(block.Block), nil + } + + out, err := bs.bs.Get(c) + if err != nil { + return nil, err + } + + bs.cache.Add(c, out) + return out, nil +} + +func (bs *CacheBS) GetSize(c cid.Cid) (int, error) { + return bs.bs.GetSize(c) +} + +func (bs *CacheBS) Put(blk block.Block) error { + bs.cache.Add(blk.Cid(), blk) + + return bs.bs.Put(blk) +} + +func (bs *CacheBS) Has(c cid.Cid) (bool, error) { + if bs.cache.Contains(c) { + return true, nil + } + + return bs.bs.Has(c) +} + +func (bs *CacheBS) HashOnRead(hor bool) { + bs.bs.HashOnRead(hor) +} + +func (bs *CacheBS) PutMany(blks []block.Block) error { + for _, blk := range blks { + bs.cache.Add(blk.Cid(), blk) + } + return bs.bs.PutMany(blks) +} diff --git a/lib/increadtimeout/incrt.go b/lib/increadtimeout/incrt.go index 0b9c65d4d..dd5a05ff8 100644 --- a/lib/increadtimeout/incrt.go +++ b/lib/increadtimeout/incrt.go @@ -5,12 +5,12 @@ import ( "time" logging "github.com/ipfs/go-log/v2" + + "github.com/filecoin-project/lotus/build" ) var log = logging.Logger("incrt") -var now = time.Now - type ReaderDeadline interface { Read([]byte) (int, error) SetReadDeadline(time.Time) error @@ -45,7 +45,7 @@ func (err errNoWait) Timeout() bool { } func (crt *incrt) Read(buf []byte) (int, error) { - start := now() + start := build.Clock.Now() if crt.wait == 0 { return 0, errNoWait{} } @@ -59,7 +59,7 @@ func (crt *incrt) Read(buf []byte) (int, error) { _ = crt.rd.SetReadDeadline(time.Time{}) if err == nil { - dur := now().Sub(start) + dur := build.Clock.Now().Sub(start) crt.wait -= dur crt.wait += time.Duration(n) * crt.waitPerByte if crt.wait < 0 { diff --git a/lib/peermgr/peermgr.go b/lib/peermgr/peermgr.go index 490f2b229..d275be3d5 100644 --- a/lib/peermgr/peermgr.go +++ b/lib/peermgr/peermgr.go @@ -5,6 +5,7 @@ import ( "sync" "time" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/metrics" "github.com/filecoin-project/lotus/node/modules/dtypes" "go.opencensus.io/stats" @@ -107,7 +108,7 @@ func (pmgr *PeerMgr) Disconnect(p peer.ID) { } func (pmgr *PeerMgr) Run(ctx context.Context) { - tick := time.NewTicker(time.Second * 5) + tick := build.Clock.Ticker(time.Second * 5) for { select { case <-tick.C: diff --git a/lotuspond/front/package-lock.json b/lotuspond/front/package-lock.json index 8df204f2e..e688211d2 100644 --- a/lotuspond/front/package-lock.json +++ b/lotuspond/front/package-lock.json @@ -1663,7 +1663,7 @@ "@xtuc/ieee754": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz", - "integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==" + "integrity": "sha1-7vAUoxRa5Hehy8AM0eVSM23Ot5A=" }, "@xtuc/long": { "version": "4.2.2", @@ -1767,7 +1767,7 @@ "ansi-styles": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "integrity": "sha1-QfuyAkPlCxK+DwS43tvwdSDOhB0=", "requires": { "color-convert": "^1.9.0" } @@ -1775,7 +1775,7 @@ "anymatch": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-2.0.0.tgz", - "integrity": "sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw==", + "integrity": "sha1-vLJLTzeTTZqnrBe0ra+J58du8us=", "requires": { "micromatch": "^3.1.4", "normalize-path": "^2.1.1" @@ -1784,12 +1784,12 @@ "aproba": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", - "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==" + "integrity": "sha1-aALmJk79GMeQobDVF/DyYnvyyUo=" }, "argparse": { "version": "1.0.10", "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "integrity": "sha1-vNZ5HqWuCXJeF+WtmIE0zUCz2RE=", "requires": { "sprintf-js": "~1.0.2" } @@ -1811,7 +1811,7 @@ "arr-flatten": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/arr-flatten/-/arr-flatten-1.1.0.tgz", - "integrity": "sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg==" + "integrity": "sha1-NgSLv/TntH4TZkQxbJlmnqWukfE=" }, "arr-union": { "version": "3.1.0", @@ -1883,7 +1883,7 @@ "asn1": { "version": "0.2.4", "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz", - "integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==", + "integrity": "sha1-jSR136tVO7M+d7VOWeiAu4ziMTY=", "requires": { "safer-buffer": "~2.1.0" } @@ -1891,7 +1891,7 @@ "asn1.js": { "version": "4.10.1", "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-4.10.1.tgz", - "integrity": "sha512-p32cOF5q0Zqs9uBiONKYLm6BClCoBCM5O9JfeUSlnQLBTxYdTK+pW+nXflm8UkKd2UYlEbYz5qEi0JuZR9ckSw==", + "integrity": "sha1-ucK/WAXx5kqt7tbfOiv6+1pz9aA=", "requires": { "bn.js": "^4.0.0", "inherits": "^2.0.1", @@ -1993,7 +1993,7 @@ "atob": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz", - "integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==" + "integrity": "sha1-bZUX654DDSQ2ZmZR6GvZ9vE1M8k=" }, "autoprefixer": { "version": "9.6.1", @@ -2024,7 +2024,7 @@ "aws4": { "version": "1.8.0", "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.8.0.tgz", - "integrity": "sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ==" + "integrity": "sha1-8OAD2cqef1nHpQiUXXsu+aBKVC8=" }, "axobject-query": { "version": "2.0.2", @@ -2113,7 +2113,7 @@ "babel-extract-comments": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/babel-extract-comments/-/babel-extract-comments-1.0.0.tgz", - "integrity": "sha512-qWWzi4TlddohA91bFwgt6zO/J0X+io7Qp184Fw0m2JYRSTZnJbFR8+07KmzudHCZgOiKRCrjhylwv9Xd8gfhVQ==", + "integrity": "sha1-Cirt+BQX7TkbheGLRhTmk6A1GiE=", "requires": { "babylon": "^6.18.0" } @@ -2366,14 +2366,14 @@ "regenerator-runtime": { "version": "0.11.1", "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz", - "integrity": "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==" + "integrity": "sha1-vgWtf5v30i4Fb5cmzuUBf78Z4uk=" } } }, "babylon": { "version": "6.18.0", "resolved": "https://registry.npmjs.org/babylon/-/babylon-6.18.0.tgz", - "integrity": "sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ==" + "integrity": "sha1-ry87iPpvXB5MY00aD46sT1WzleM=" }, "balanced-match": { "version": "1.0.0", @@ -2383,7 +2383,7 @@ "base": { "version": "0.11.2", "resolved": "https://registry.npmjs.org/base/-/base-0.11.2.tgz", - "integrity": "sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg==", + "integrity": "sha1-e95c7RRbbVUakNuH+DxVi060io8=", "requires": { "cache-base": "^1.0.1", "class-utils": "^0.3.5", @@ -2405,7 +2405,7 @@ "is-accessor-descriptor": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", - "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "integrity": "sha1-FpwvbT3x+ZJhgHI2XJsOofaHhlY=", "requires": { "kind-of": "^6.0.0" } @@ -2413,7 +2413,7 @@ "is-data-descriptor": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "integrity": "sha1-2Eh2Mh0Oet0DmQQGq7u9NrqSaMc=", "requires": { "kind-of": "^6.0.0" } @@ -2421,7 +2421,7 @@ "is-descriptor": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", - "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "integrity": "sha1-OxWXRqZmBLBPjIFSS6NlxfFNhuw=", "requires": { "is-accessor-descriptor": "^1.0.0", "is-data-descriptor": "^1.0.0", @@ -2431,14 +2431,14 @@ "kind-of": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "integrity": "sha1-ARRrNqYhjmTljzqNZt5df8b20FE=" } } }, "base-x": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/base-x/-/base-x-3.0.4.tgz", - "integrity": "sha512-UYOadoSIkEI/VrRGSG6qp93rp2WdokiAiNYDfGW5qURAY8GiAQkvMbwNNSDYiVJopqv4gCna7xqf4rrNGp+5AA==", + "integrity": "sha1-lMF4hzbaBl7bHWiAiGnjV8l3+nc=", "requires": { "safe-buffer": "^5.0.1" } @@ -2489,7 +2489,7 @@ "bn.js": { "version": "4.11.8", "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.11.8.tgz", - "integrity": "sha512-ItfYfPLkWHUjckQCk8xC+LwxgK8NYcXywGigJgSwOP8Y2iyWT4f2vsZnoOXTTbo+o5yXmIUJ4gn5538SO5S3gA==" + "integrity": "sha1-LN4J617jQfSEdGuwMJsyU7GxRC8=" }, "body-parser": { "version": "1.19.0", @@ -2566,7 +2566,7 @@ "brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "integrity": "sha1-PH/L9SnYcibz0vUrlm/1Jx60Qd0=", "requires": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -2575,7 +2575,7 @@ "braces": { "version": "2.3.2", "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", - "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", + "integrity": "sha1-WXn9PxTNUxVl5fot8av/8d+u5yk=", "requires": { "arr-flatten": "^1.1.0", "array-unique": "^0.3.2", @@ -2612,7 +2612,7 @@ "browser-resolve": { "version": "1.11.3", "resolved": "https://registry.npmjs.org/browser-resolve/-/browser-resolve-1.11.3.tgz", - "integrity": "sha512-exDi1BYWB/6raKHmDTCicQfTkqwN5fioMFV4j8BsfMU4R2DK/QfZfK7kOVkmWCNANf0snkBzqGqAJBao9gZMdQ==", + "integrity": "sha1-m3y7PQ9RDky4a9vXlhJNKLWJCvY=", "requires": { "resolve": "1.1.7" }, @@ -2640,7 +2640,7 @@ "browserify-cipher": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/browserify-cipher/-/browserify-cipher-1.0.1.tgz", - "integrity": "sha512-sPhkz0ARKbf4rRQt2hTpAHqn47X3llLkUGn+xEJzLjwY8LRs2p0v7ljvI5EyoRO/mexrNunNECisZs+gw2zz1w==", + "integrity": "sha1-jWR0wbhwv9q807z8wZNKEOlPFfA=", "requires": { "browserify-aes": "^1.0.4", "browserify-des": "^1.0.0", @@ -2650,7 +2650,7 @@ "browserify-des": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/browserify-des/-/browserify-des-1.0.2.tgz", - "integrity": "sha512-BioO1xf3hFwz4kc6iBhI3ieDFompMhrMlnDFC4/0/vd5MokpuAc3R+LYbwTA9A5Yc9pq9UYPqffKpW2ObuwX5A==", + "integrity": "sha1-OvTx9Zg5QDVy8cZiBDdfen9wPpw=", "requires": { "cipher-base": "^1.0.1", "des.js": "^1.0.0", @@ -2684,7 +2684,7 @@ "browserify-zlib": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/browserify-zlib/-/browserify-zlib-0.2.0.tgz", - "integrity": "sha512-Z942RysHXmJrhqk88FmKBVq/v5tqmSkDz7p54G/MGyjMnCFFnC79XWNbg+Vta8W6Wb2qtSZTSxIGkJrRpCFEiA==", + "integrity": "sha1-KGlFnZqjviRf6P4sofRuLn9U1z8=", "requires": { "pako": "~1.0.5" } @@ -2728,12 +2728,12 @@ "buffer-from": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", - "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==" + "integrity": "sha1-MnE7wCj3XAL9txDXx7zsHyxgcO8=" }, "buffer-indexof": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/buffer-indexof/-/buffer-indexof-1.1.1.tgz", - "integrity": "sha512-4/rOEg86jivtPTeOUUT61jJO1Ya1TrR/OkqCSZDyq84WJh3LuuiphBYJN+fm5xufIk4XAFcEwte/8WzC8If/1g==" + "integrity": "sha1-Uvq8xqYG0aADAoAmSO9o9jnaJow=" }, "buffer-xor": { "version": "1.0.3", @@ -2774,7 +2774,7 @@ "cache-base": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/cache-base/-/cache-base-1.0.1.tgz", - "integrity": "sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ==", + "integrity": "sha1-Cn9GQWgxyLZi7jb+TnxZ129marI=", "requires": { "collection-visit": "^1.0.0", "component-emitter": "^1.2.1", @@ -2835,7 +2835,7 @@ "caniuse-api": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/caniuse-api/-/caniuse-api-3.0.0.tgz", - "integrity": "sha512-bsTwuIg/BZZK/vreVTYYbSWoe2F+71P7K5QGEX+pT250DZbfU1MQ5prOKpPR+LL6uWKK3KMwMCAS74QB3Um1uw==", + "integrity": "sha1-Xk2Q4idJYdRikZl99Znj7QCO5MA=", "requires": { "browserslist": "^4.0.0", "caniuse-lite": "^1.0.0", @@ -2879,7 +2879,7 @@ "chardet": { "version": "0.7.0", "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz", - "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==" + "integrity": "sha1-kAlISfCTfy7twkJdDSip5fDLrZ4=" }, "chokidar": { "version": "2.1.6", @@ -3420,7 +3420,7 @@ "cipher-base": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/cipher-base/-/cipher-base-1.0.4.tgz", - "integrity": "sha512-Kkht5ye6ZGmwv40uUDZztayT2ThLQGfnj/T71N/XzeZeo3nf8foyW7zGTsPYkEya3m5f3cAypH+qe7YOrM1U2Q==", + "integrity": "sha1-h2Dk7MJy9MNjUy+SbYdKriwTl94=", "requires": { "inherits": "^2.0.1", "safe-buffer": "^5.0.1" @@ -3439,7 +3439,7 @@ "class-utils": { "version": "0.3.6", "resolved": "https://registry.npmjs.org/class-utils/-/class-utils-0.3.6.tgz", - "integrity": "sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg==", + "integrity": "sha1-+TNprouafOAv1B+q0MqDAzGQxGM=", "requires": { "arr-union": "^3.1.0", "define-property": "^0.2.5", @@ -3465,7 +3465,7 @@ "clean-css": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/clean-css/-/clean-css-4.2.1.tgz", - "integrity": "sha512-4ZxI6dy4lrY6FHzfiy1aEOXgu4LIsW2MhwG0VBKdcoGoH/XLFgaHSdLTGr4O8Be6A8r3MOphEiI8Gc1n0ecf3g==", + "integrity": "sha1-LUEe92uFabbQyEBo2r6FsKpeXBc=", "requires": { "source-map": "~0.6.0" }, @@ -3473,7 +3473,7 @@ "source-map": { "version": "0.6.1", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" + "integrity": "sha1-dHIq8y6WFOnCh6jQu95IteLxomM=" } } }, @@ -3558,7 +3558,7 @@ "color-convert": { "version": "1.9.3", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "integrity": "sha1-u3GFBpDh8TZWfeYp0tVHHe2kweg=", "requires": { "color-name": "1.1.3" } @@ -3571,7 +3571,7 @@ "color-string": { "version": "1.5.3", "resolved": "https://registry.npmjs.org/color-string/-/color-string-1.5.3.tgz", - "integrity": "sha512-dC2C5qeWoYkxki5UAXapdjqO672AM4vZuPGRQfO8b5HKuKGBbKWpITyDYN7TOFKvRW7kOgAn3746clDBMDJyQw==", + "integrity": "sha1-ybvF8BtYtUkvPWhXRZy2WQziBMw=", "requires": { "color-name": "^1.0.0", "simple-swizzle": "^0.2.2" @@ -3593,7 +3593,7 @@ "common-tags": { "version": "1.8.0", "resolved": "https://registry.npmjs.org/common-tags/-/common-tags-1.8.0.tgz", - "integrity": "sha512-6P6g0uetGpW/sdyUy/iQQCbFF0kWVMSIVSyYz7Zgjcgh8mgw8PQzDNZeyZ5DQ2gM7LBoZPHmnjz8rUthkBG5tw==" + "integrity": "sha1-jjFT5ULUo56bEFVENK+q+YlWqTc=" }, "commondir": { "version": "1.0.1", @@ -3655,7 +3655,7 @@ "concat-stream": { "version": "1.6.2", "resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-1.6.2.tgz", - "integrity": "sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==", + "integrity": "sha1-kEvfGUzTEi/Gdcd/xKw9T/D9GjQ=", "requires": { "buffer-from": "^1.0.0", "inherits": "^2.0.3", @@ -3702,12 +3702,12 @@ "content-type": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz", - "integrity": "sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA==" + "integrity": "sha1-4TjMdeBAxyexlm/l5fjJruJW/js=" }, "convert-source-map": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.6.0.tgz", - "integrity": "sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A==", + "integrity": "sha1-UbU3qMQ+DwTewZk7/83VBOdYrCA=", "requires": { "safe-buffer": "~5.1.1" } @@ -3725,7 +3725,7 @@ "copy-concurrently": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/copy-concurrently/-/copy-concurrently-1.0.5.tgz", - "integrity": "sha512-f2domd9fsVDFtaFcbaRZuYXwtdmnzqbADSwhSWYxYB/Q8zsdUUFMXVRwXGDMWmbEzAn1kdRrtI1T/KTFOL4X2A==", + "integrity": "sha1-kilzmMrjSTf8r9bsgTnBgFHwteA=", "requires": { "aproba": "^1.1.1", "fs-write-stream-atomic": "^1.0.8", @@ -3786,7 +3786,7 @@ "create-ecdh": { "version": "4.0.3", "resolved": "https://registry.npmjs.org/create-ecdh/-/create-ecdh-4.0.3.tgz", - "integrity": "sha512-GbEHQPMOswGpKXM9kCWVrremUcBmjteUaQ01T9rkKCPDXfUHX0IoP9LpHYo2NPFampa4e+/pFDc3jQdxrxQLaw==", + "integrity": "sha1-yREbbzMEXEaX8UR4f5JUzcd8Rf8=", "requires": { "bn.js": "^4.1.0", "elliptic": "^6.0.0" @@ -3820,7 +3820,7 @@ "cross-spawn": { "version": "6.0.5", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", - "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", + "integrity": "sha1-Sl7Hxk364iw6FBJNus3uhG2Ay8Q=", "requires": { "nice-try": "^1.0.4", "path-key": "^2.0.1", @@ -3839,7 +3839,7 @@ "crypto-browserify": { "version": "3.12.0", "resolved": "https://registry.npmjs.org/crypto-browserify/-/crypto-browserify-3.12.0.tgz", - "integrity": "sha512-fz4spIh+znjO2VjL+IdhEpRJ3YN6sMzITSBijk6FK2UvTqruSQW+/cCZTSNsMiZNvUeq0CqurF+dAbyiGOY6Wg==", + "integrity": "sha1-OWz58xN/A+S45TLFj2mCVOAPgOw=", "requires": { "browserify-cipher": "^1.0.0", "browserify-sign": "^4.0.0", @@ -3875,7 +3875,7 @@ "css-declaration-sorter": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/css-declaration-sorter/-/css-declaration-sorter-4.0.1.tgz", - "integrity": "sha512-BcxQSKTSEEQUftYpBVnsH4SF05NTuBokb19/sBt6asXGKZ/6VP7PLG1CBCkFDYOnhXhPh0jMhO6xZ71oYHXHBA==", + "integrity": "sha1-wZiUD2OnbX42wecQGLABchBUyyI=", "requires": { "postcss": "^7.0.1", "timsort": "^0.3.0" @@ -3943,7 +3943,7 @@ "css-select": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/css-select/-/css-select-2.0.2.tgz", - "integrity": "sha512-dSpYaDVoWaELjvZ3mS6IKZM/y2PMPa/XYoEfYNZePL4U/XgyxZNroHEHReDx/d+VgXh9VbCTtFqLkFbmeqeaRQ==", + "integrity": "sha1-q0OGzsnh9miFVWSxfDcztDsqXt4=", "requires": { "boolbase": "^1.0.0", "css-what": "^2.1.2", @@ -3954,7 +3954,7 @@ "css-select-base-adapter": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/css-select-base-adapter/-/css-select-base-adapter-0.1.1.tgz", - "integrity": "sha512-jQVeeRG70QI08vSTwf1jHxp74JoZsr2XSgETae8/xC8ovSnL2WF87GTLO86Sbwdt2lK4Umg4HnnwMO4YF3Ce7w==" + "integrity": "sha1-Oy/0lyzDYquIVhUHqVQIoUMhNdc=" }, "css-to-react-native": { "version": "2.3.1", @@ -4056,7 +4056,7 @@ "cssnano-util-raw-cache": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/cssnano-util-raw-cache/-/cssnano-util-raw-cache-4.0.1.tgz", - "integrity": "sha512-qLuYtWK2b2Dy55I8ZX3ky1Z16WYsx544Q0UWViebptpwn/xDBmog2TLg4f+DBMg1rJ6JDWtn96WHbOKDWt1WQA==", + "integrity": "sha1-sm1f1fcqEd/np4RvtMZyYPlr8oI=", "requires": { "postcss": "^7.0.0" } @@ -4064,12 +4064,12 @@ "cssnano-util-same-parent": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/cssnano-util-same-parent/-/cssnano-util-same-parent-4.0.1.tgz", - "integrity": "sha512-WcKx5OY+KoSIAxBW6UBBRay1U6vkYheCdjyVNDm85zt5K9mHoGOfsOsqIszfAqrQQFIIKgjh2+FDgIj/zsl21Q==" + "integrity": "sha1-V0CC+yhZ0ttDOFWDXZqEVuoYu/M=" }, "csso": { "version": "3.5.1", "resolved": "https://registry.npmjs.org/csso/-/csso-3.5.1.tgz", - "integrity": "sha512-vrqULLffYU1Q2tLdJvaCYbONStnfkfimRxXNaGjxMldI0C7JPBC4rB1RyjhfdZ4m1frm8pM9uRPKH3d2knZ8gg==", + "integrity": "sha1-e564vmFiiXPBsmHhadLwJACOdYs=", "requires": { "css-tree": "1.0.0-alpha.29" }, @@ -4077,7 +4077,7 @@ "css-tree": { "version": "1.0.0-alpha.29", "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-1.0.0-alpha.29.tgz", - "integrity": "sha512-sRNb1XydwkW9IOci6iB2xmy8IGCj6r/fr+JWitvJ2JxQRPzN3T4AGGVWCMlVmVwM1gtgALJRmGIlWv5ppnGGkg==", + "integrity": "sha1-P6nU7zFCy9HDAedmTB81K9gvWjk=", "requires": { "mdn-data": "~1.1.0", "source-map": "^0.5.3" @@ -4086,7 +4086,7 @@ "mdn-data": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-1.1.4.tgz", - "integrity": "sha512-FSYbp3lyKjyj3E7fMl6rYvUdX0FBXaluGqlFoYESWQlyUTq8R+wp0rkFxoYFqZlHCvsUXGjyJmLQSnXToYhOSA==" + "integrity": "sha1-ULXU/8RXUnZXPE7tuHgIEqhBnwE=" } } }, @@ -4196,7 +4196,7 @@ "define-properties": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", - "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "integrity": "sha1-z4jabL7ib+bbcJT2HYcMvYTO6fE=", "requires": { "object-keys": "^1.0.12" } @@ -4204,7 +4204,7 @@ "define-property": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/define-property/-/define-property-2.0.2.tgz", - "integrity": "sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ==", + "integrity": "sha1-1Flono1lS6d+AqgX+HENcCyxbp0=", "requires": { "is-descriptor": "^1.0.2", "isobject": "^3.0.1" @@ -4213,7 +4213,7 @@ "is-accessor-descriptor": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", - "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "integrity": "sha1-FpwvbT3x+ZJhgHI2XJsOofaHhlY=", "requires": { "kind-of": "^6.0.0" } @@ -4221,7 +4221,7 @@ "is-data-descriptor": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "integrity": "sha1-2Eh2Mh0Oet0DmQQGq7u9NrqSaMc=", "requires": { "kind-of": "^6.0.0" } @@ -4229,7 +4229,7 @@ "is-descriptor": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", - "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "integrity": "sha1-OxWXRqZmBLBPjIFSS6NlxfFNhuw=", "requires": { "is-accessor-descriptor": "^1.0.0", "is-data-descriptor": "^1.0.0", @@ -4239,7 +4239,7 @@ "kind-of": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "integrity": "sha1-ARRrNqYhjmTljzqNZt5df8b20FE=" } } }, @@ -4314,7 +4314,7 @@ "detect-node": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/detect-node/-/detect-node-2.0.4.tgz", - "integrity": "sha512-ZIzRpLJrOj7jjP2miAtgqIfmzbxa4ZOr5jJc601zklsfEx9oTzmmj2nVpIPRpNlRTIh8lc1kyViIY7BWSGNmKw==" + "integrity": "sha1-AU7o+PZpxcWAI9pkuBecCDooxGw=" }, "detect-port-alt": { "version": "1.1.6", @@ -4358,7 +4358,7 @@ "dir-glob": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-2.0.0.tgz", - "integrity": "sha512-37qirFDz8cA5fimp9feo43fSuRo2gHwaIn6dXL8Ber1dGwUosDrGZeCCXq57WnIqE4aQ+u3eQZzsk1yOzhdwag==", + "integrity": "sha1-CyBdK2rvmCOMooZZioIE0p0KADQ=", "requires": { "arrify": "^1.0.1", "path-type": "^3.0.0" @@ -4372,7 +4372,7 @@ "dns-packet": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/dns-packet/-/dns-packet-1.3.1.tgz", - "integrity": "sha512-0UxfQkMhYAUaZI+xrNZOz/as5KgDU0M/fQ9b6SpkyLbk3GEswDi6PADJVaYJradtRVsRIlF1zLyOodbcTCDzUg==", + "integrity": "sha1-EqpCaYEHW+UAuRDu3NC0fdfe2lo=", "requires": { "ip": "^1.1.0", "safe-buffer": "^5.0.1" @@ -4397,7 +4397,7 @@ "dom-converter": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/dom-converter/-/dom-converter-0.2.0.tgz", - "integrity": "sha512-gd3ypIPfOMr9h5jIKq8E3sHOTCjeirnl0WK5ZdS1AW0Odt0b1PaWaHdJ4Qk4klv+YB9aJBS7mESXjFoDQPu6DA==", + "integrity": "sha1-ZyGp2u4uKTaClVtq/kFncWJ7t2g=", "requires": { "utila": "~0.4" } @@ -4414,7 +4414,7 @@ "domain-browser": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/domain-browser/-/domain-browser-1.2.0.tgz", - "integrity": "sha512-jnjyiM6eRyZl2H+W8Q/zLMA481hzi0eszAaBUzIVnmYVDBbnLxVNnfu1HgEBvCbL+71FrxMl3E6lpKH7Ge3OXA==" + "integrity": "sha1-PTH1AZGmdJ3RN1p/Ui6CPULlTto=" }, "domelementtype": { "version": "1.3.1", @@ -4440,7 +4440,7 @@ "domutils": { "version": "1.7.0", "resolved": "https://registry.npmjs.org/domutils/-/domutils-1.7.0.tgz", - "integrity": "sha512-Lgd2XcJ/NjEw+7tFvfKxOzCYKZsdct5lczQ2ZaQY8Djz7pfAD3Gbp8ySJWtreII/vDlMVmxwa6pHmdxIYgttDg==", + "integrity": "sha1-Vuo0HoNOBuZ0ivehyyXaZ+qfjCo=", "requires": { "dom-serializer": "0", "domelementtype": "1" @@ -4449,7 +4449,7 @@ "dot-prop": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/dot-prop/-/dot-prop-4.2.0.tgz", - "integrity": "sha512-tUMXrxlExSW6U2EXiiKGSBVdYgtV8qlHL+C10TsW4PURY/ic+eaysnSkwB4kA/mBlCyy/IKDJ+Lc3wbWeaXtuQ==", + "integrity": "sha1-HxngwuGqDjJ5fEl5nyg3rGr2nFc=", "requires": { "is-obj": "^1.0.0" } @@ -4567,7 +4567,7 @@ "errno": { "version": "0.1.7", "resolved": "https://registry.npmjs.org/errno/-/errno-0.1.7.tgz", - "integrity": "sha512-MfrRBDWzIWifgq6tJj60gkAwtLNb6sQPlcFrSOflcP1aFmmruKQ2wRnze/8V6kgyz7H3FF8Npzv78mZ7XLLflg==", + "integrity": "sha1-RoTXF3mtOa8Xfj8AeZb3xnyFJhg=", "requires": { "prr": "~1.0.1" } @@ -4575,7 +4575,7 @@ "error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", - "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", + "integrity": "sha1-tKxAZIEH/c3PriQvQovqihTU8b8=", "requires": { "is-arrayish": "^0.2.1" } @@ -4596,7 +4596,7 @@ "es-to-primitive": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.0.tgz", - "integrity": "sha512-qZryBOJjV//LaxLTV6UC//WewneB3LcXOL9NP++ozKVXsIIIpm/2c13UDiD9Jp2eThsecw9m3jPqDwTyobcdbg==", + "integrity": "sha1-7fckeAM0VujdqO8J4ArZZQcH83c=", "requires": { "is-callable": "^1.1.4", "is-date-object": "^1.0.1", @@ -4713,7 +4713,7 @@ "eslint-import-resolver-node": { "version": "0.3.2", "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.2.tgz", - "integrity": "sha512-sfmTqJfPSizWu4aymbPr4Iidp5yKm8yDkHp+Ir3YiTHiiDfxh69mOUsmiqW6RZ9zRXFaF64GtYmN7e+8GHBv6Q==", + "integrity": "sha1-WPFfuDm40FdsqYBBNHaqskcttmo=", "requires": { "debug": "^2.6.9", "resolve": "^1.5.0" @@ -4722,7 +4722,7 @@ "debug": { "version": "2.6.9", "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "integrity": "sha1-XRKFFd8TT/Mn6QpMk/Tgd6U2NB8=", "requires": { "ms": "2.0.0" } @@ -5033,12 +5033,12 @@ "esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==" + "integrity": "sha1-E7BM2z5sXRnfkatph6hpVhmwqnE=" }, "esquery": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.0.1.tgz", - "integrity": "sha512-SmiyZ5zIWH9VM+SRUReLS5Q8a7GxtRdxEBVZpm98rJM7Sb+A9DVCndXfkeFUd3byderg+EbDkfnevfCwynWaNA==", + "integrity": "sha1-QGxRZYsfWZGl+bYrHcJbAOPlxwg=", "requires": { "estraverse": "^4.0.0" } @@ -5046,7 +5046,7 @@ "esrecurse": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.2.1.tgz", - "integrity": "sha512-64RBB++fIOAXPw3P9cy89qfMlvZEXZkqqJkjqqXIvzP5ezRZjW+lPWjw35UX/3EhUPFYbg5ER4JYgDw4007/DQ==", + "integrity": "sha1-AHo7n9vCs7uH5IeeoZyS/b05Qs8=", "requires": { "estraverse": "^4.1.0" } @@ -5087,7 +5087,7 @@ "evp_bytestokey": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/evp_bytestokey/-/evp_bytestokey-1.0.3.tgz", - "integrity": "sha512-/f2Go4TognH/KvCISP7OUsHn85hT9nUkxxA9BEWxFn+Oj9o8ZNLm/40hdlgSLyuOimsrTKLUMEorQexp/aPQeA==", + "integrity": "sha1-f8vbGY3HGVlDLv4ThCaE4FJaywI=", "requires": { "md5.js": "^1.3.4", "safe-buffer": "^5.1.1" @@ -5134,7 +5134,7 @@ "debug": { "version": "2.6.9", "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "integrity": "sha1-XRKFFd8TT/Mn6QpMk/Tgd6U2NB8=", "requires": { "ms": "2.0.0" } @@ -5240,7 +5240,7 @@ "extend": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", - "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==" + "integrity": "sha1-+LETa0Bx+9jrFAr/hYsQGewpFfo=" }, "extend-shallow": { "version": "3.0.2", @@ -5254,7 +5254,7 @@ "is-extendable": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-1.0.1.tgz", - "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", + "integrity": "sha1-p0cPnkJnM9gb2B4RVSZOOjUHyrQ=", "requires": { "is-plain-object": "^2.0.4" } @@ -5274,7 +5274,7 @@ "extglob": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", - "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", + "integrity": "sha1-rQD+TcYSqSMuhxhxHcXLWrAoVUM=", "requires": { "array-unique": "^0.3.2", "define-property": "^1.0.0", @@ -5305,7 +5305,7 @@ "is-accessor-descriptor": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", - "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "integrity": "sha1-FpwvbT3x+ZJhgHI2XJsOofaHhlY=", "requires": { "kind-of": "^6.0.0" } @@ -5313,7 +5313,7 @@ "is-data-descriptor": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "integrity": "sha1-2Eh2Mh0Oet0DmQQGq7u9NrqSaMc=", "requires": { "kind-of": "^6.0.0" } @@ -5321,7 +5321,7 @@ "is-descriptor": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", - "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "integrity": "sha1-OxWXRqZmBLBPjIFSS6NlxfFNhuw=", "requires": { "is-accessor-descriptor": "^1.0.0", "is-data-descriptor": "^1.0.0", @@ -5331,7 +5331,7 @@ "kind-of": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "integrity": "sha1-ARRrNqYhjmTljzqNZt5df8b20FE=" } } }, @@ -5416,7 +5416,7 @@ "figgy-pudding": { "version": "3.5.1", "resolved": "https://registry.npmjs.org/figgy-pudding/-/figgy-pudding-3.5.1.tgz", - "integrity": "sha512-vNKxJHTEKNThjfrdJwHc7brvM6eVevuO5nTj6ez8ZQ1qbXTvGthucRF7S4vf2cr71QVnT70V34v0S1DyQsti0w==" + "integrity": "sha1-hiRwESkBxyeg5JWoB0S9W6odZ5A=" }, "figures": { "version": "2.0.0", @@ -5446,7 +5446,7 @@ "filesize": { "version": "3.6.1", "resolved": "https://registry.npmjs.org/filesize/-/filesize-3.6.1.tgz", - "integrity": "sha512-7KjR1vv6qnicaPMi1iiTcI85CyYwRO/PSFCu6SvqL8jN2Wjt/NIYQTFtFs7fSDCYOstUkEWIQGFUg5YZQfjlcg==" + "integrity": "sha1-CQuz7gG2+AGoqL6Z0xcQs0Irsxc=" }, "fill-range": { "version": "4.0.0", @@ -5511,7 +5511,7 @@ "find-up": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "integrity": "sha1-SRafHXmTQwZG2mHsxa41XCHJe3M=", "requires": { "locate-path": "^3.0.0" } @@ -5606,7 +5606,7 @@ "form-data": { "version": "2.3.3", "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", - "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", + "integrity": "sha1-3M5SwF9kTymManq5Nr1yTO/786Y=", "requires": { "asynckit": "^0.4.0", "combined-stream": "^1.0.6", @@ -5675,7 +5675,7 @@ "function-bind": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", - "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + "integrity": "sha1-pWiZ0+o8m6uHS7l3O3xe3pL0iV0=" }, "functional-red-black-tree": { "version": "1.0.1", @@ -5880,7 +5880,7 @@ "has": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", - "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "integrity": "sha1-ci18v8H2qoJB8W3YFOAR4fQeh5Y=", "requires": { "function-bind": "^1.1.1" } @@ -5960,12 +5960,12 @@ "he": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", - "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==" + "integrity": "sha1-hK5l+n6vsWX922FWauFLrwVmTw8=" }, "hex-color-regex": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/hex-color-regex/-/hex-color-regex-1.1.0.tgz", - "integrity": "sha512-l9sfDFsuqtOqKDsQdqrMRk0U85RZc0RtOR9yPI7mRVOa4FsR/BVnZ0shmQRM96Ji99kYZP/7hn1cedc1+ApsTQ==" + "integrity": "sha1-TAb8y0YC/iYCs8k9+C1+fb8aio4=" }, "history": { "version": "4.10.1", @@ -6024,7 +6024,7 @@ "html-comment-regex": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/html-comment-regex/-/html-comment-regex-1.1.2.tgz", - "integrity": "sha512-P+M65QY2JQ5Y0G9KKdlDpo0zK+/OHptU5AaBwUfAIDJZk1MYf32Frm84EcOytfJE0t5JvkAnKlmjsXDnWzCJmQ==" + "integrity": "sha1-l9RoiutcgYhqNk+qDK0d2hTUM6c=" }, "html-encoding-sniffer": { "version": "1.0.2", @@ -6042,7 +6042,7 @@ "html-minifier": { "version": "3.5.21", "resolved": "https://registry.npmjs.org/html-minifier/-/html-minifier-3.5.21.tgz", - "integrity": "sha512-LKUKwuJDhxNa3uf/LPR/KVjm/l3rBqtYeCOAekvG8F1vItxMUpueGd94i/asDDr8/1u7InxzFA5EeGjhhG5mMA==", + "integrity": "sha1-0AQOBUcw41TbAIRjWTGUAVIS0gw=", "requires": { "camel-case": "3.0.x", "clean-css": "4.2.x", @@ -6056,7 +6056,7 @@ "commander": { "version": "2.17.1", "resolved": "https://registry.npmjs.org/commander/-/commander-2.17.1.tgz", - "integrity": "sha512-wPMUt6FnH2yzG95SA6mzjQOEKUU3aLaDEmzs1ti+1E9h+CsrZghRlqEM/EJ4KscsQVG8uNN4uVreUeT8+drlgg==" + "integrity": "sha1-vXerfebelCBc6sxy8XFtKfIKd78=" } } }, @@ -6166,7 +6166,7 @@ "iconv-lite": { "version": "0.4.24", "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", - "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", + "integrity": "sha1-ICK0sl+93CHS9SSXSkdKr+czkIs=", "requires": { "safer-buffer": ">= 2.1.2 < 3" } @@ -6240,7 +6240,7 @@ "import-local": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/import-local/-/import-local-2.0.0.tgz", - "integrity": "sha512-b6s04m3O+s3CGSbqDIyP4R6aAwAeYlVq9+WUWep6iHa8ETRf9yei1U48C5MmfJmV9AiLYYBKPMq/W+/WRpQmCQ==", + "integrity": "sha1-VQcL44pZk88Y72236WH1vuXFoJ0=", "requires": { "pkg-dir": "^3.0.0", "resolve-cwd": "^2.0.0" @@ -6273,7 +6273,7 @@ "ini": { "version": "1.3.5", "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz", - "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==" + "integrity": "sha1-7uJfVtscnsYIXgwid4CD9Zar+Sc=" }, "inquirer": { "version": "6.5.0", @@ -6327,7 +6327,7 @@ "invariant": { "version": "2.2.4", "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", - "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", + "integrity": "sha1-YQ88ksk1nOHbYW5TgAjSP/NRWOY=", "requires": { "loose-envify": "^1.0.0" } @@ -6335,7 +6335,7 @@ "invert-kv": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz", - "integrity": "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==" + "integrity": "sha1-c5P1r6Weyf9fZ6J2INEcIm4+7AI=" }, "ip": { "version": "1.1.5", @@ -6393,12 +6393,12 @@ "is-buffer": { "version": "1.1.6", "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", - "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" + "integrity": "sha1-76ouqdqg16suoTqXsritUf776L4=" }, "is-callable": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.1.4.tgz", - "integrity": "sha512-r5p9sxJjYnArLjObpjA4xu5EKI3CuKHkJXMhT7kwbpUyIFD1n5PMAsoPvWnvtZiNz7LjkYDRZhd7FlI0eMijEA==" + "integrity": "sha1-HhrfIZ4e62hNaR+dagX/DTCiTXU=" }, "is-capitalized": { "version": "1.0.0", @@ -6452,7 +6452,7 @@ "is-descriptor": { "version": "0.1.6", "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", - "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "integrity": "sha1-Nm2CQN3kh8pRgjsaufB6EKeCUco=", "requires": { "is-accessor-descriptor": "^0.1.6", "is-data-descriptor": "^0.1.4", @@ -6462,7 +6462,7 @@ "kind-of": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", - "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + "integrity": "sha1-cpyR4thXt6QZofmqZWhcTDP1hF0=" } } }, @@ -6520,7 +6520,7 @@ "is-path-in-cwd": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/is-path-in-cwd/-/is-path-in-cwd-1.0.1.tgz", - "integrity": "sha512-FjV1RTW48E7CWM7eE/J2NJvAEEVektecDBVBE5Hh3nM1Jd0kvhHtX68Pr3xsDf857xt3Y4AkwVULK1Vku62aaQ==", + "integrity": "sha1-WsSLNF72dTOb1sekipEhELJBz1I=", "requires": { "is-path-inside": "^1.0.0" } @@ -6536,7 +6536,7 @@ "is-plain-object": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", - "integrity": "sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==", + "integrity": "sha1-LBY7P6+xtgbZ0Xko8FwqHDjgdnc=", "requires": { "isobject": "^3.0.1" } @@ -6562,7 +6562,7 @@ "is-resolvable": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/is-resolvable/-/is-resolvable-1.1.0.tgz", - "integrity": "sha512-qgDYXFSR5WvEfuS5dMj6oTMEbrrSaM0CrFk2Yiq/gXnBvD9pMa2jGXxyhGLfvhZpuMZe18CJpFxAt3CRs42NMg==" + "integrity": "sha1-+xj4fOH+uSUWnJpAfBkxijIG7Yg=" }, "is-root": { "version": "2.0.0", @@ -6577,7 +6577,7 @@ "is-svg": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/is-svg/-/is-svg-3.0.0.tgz", - "integrity": "sha512-gi4iHK53LR2ujhLVVj+37Ykh9GLqYHX6JOVXbLAucaG/Cqw9xwdFOjDM2qeifLs1sF1npXXFvDu0r5HNgCMrzQ==", + "integrity": "sha1-kyHb0pwhLlypnE+peUxxS8r6L3U=", "requires": { "html-comment-regex": "^1.1.0" } @@ -6585,7 +6585,7 @@ "is-symbol": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.2.tgz", - "integrity": "sha512-HS8bZ9ox60yCJLH9snBpIwv9pYUAkcuLhSA1oero1UB5y9aiQpRA8y2ex945AOtCZL1lJDeIk3G5LthswI46Lw==", + "integrity": "sha1-oFX2rlcZLK7jKeeoYBGLSXqVDzg=", "requires": { "has-symbols": "^1.0.0" } @@ -6598,7 +6598,7 @@ "is-windows": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", - "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==" + "integrity": "sha1-0YUOuXkezRjmGCzhKjDzlmNLsZ0=" }, "is-wsl": { "version": "1.1.0", @@ -7831,7 +7831,7 @@ "json-parse-better-errors": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", - "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==" + "integrity": "sha1-u4Z8+zRQ5pEHwTHRxRS6s9yLyqk=" }, "json-rpc-peer": { "version": "0.15.5", @@ -7874,7 +7874,7 @@ "json-schema-traverse": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==" + "integrity": "sha1-afaofZUTq4u4/mO9sJecRI5oRmA=" }, "json-stable-stringify": { "version": "1.0.1", @@ -7973,7 +7973,7 @@ "killable": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/killable/-/killable-1.0.1.tgz", - "integrity": "sha512-LzqtLKlUwirEUyl/nicirVmNiPvYs7l5n8wOPP7fyJVpUPkvCnW/vuiXGpylGUlnPDnB7311rARzAt3Mhswpjg==" + "integrity": "sha1-TIzkQRh6Bhx0dPuHygjipjgZSJI=" }, "kind-of": { "version": "3.2.2", @@ -7991,7 +7991,7 @@ "last-call-webpack-plugin": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/last-call-webpack-plugin/-/last-call-webpack-plugin-3.0.0.tgz", - "integrity": "sha512-7KI2l2GIZa9p2spzPIVZBYyNKkN+e/SQPpnjlTiPhdbDW3F86tdKKELxKpzJ5sgU19wQWsACULZmpTPYHeWO5w==", + "integrity": "sha1-l0LfDhDjz0blwDgcLekNOnotdVU=", "requires": { "lodash": "^4.17.5", "webpack-sources": "^1.1.0" @@ -8005,7 +8005,7 @@ "lcid": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz", - "integrity": "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==", + "integrity": "sha1-bvXS32DlL4LrIopMNz6NHzlyU88=", "requires": { "invert-kv": "^2.0.0" } @@ -8114,7 +8114,7 @@ "locate-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "integrity": "sha1-2+w7OrdZdYBxtY/ln8QYca8hQA4=", "requires": { "p-locate": "^3.0.0", "path-exists": "^3.0.0" @@ -8180,7 +8180,7 @@ "loose-envify": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", - "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", + "integrity": "sha1-ce5R+nvkyuwaY4OffmgtgTLTDK8=", "requires": { "js-tokens": "^3.0.0 || ^4.0.0" } @@ -8235,7 +8235,7 @@ "mamacro": { "version": "0.0.3", "resolved": "https://registry.npmjs.org/mamacro/-/mamacro-0.0.3.tgz", - "integrity": "sha512-qMEwh+UujcQ+kbz3T6V+wAmO2U8veoq2w+3wY8MquqwVA3jChfwY+Tk52GZKDfACEPjuZ7r2oJLejwpt8jtwTA==" + "integrity": "sha1-rSyVdhl8nxq/MI0Hh4Zb2XWj8+Q=" }, "map-age-cleaner": { "version": "0.1.3", @@ -8261,7 +8261,7 @@ "md5.js": { "version": "1.3.5", "resolved": "https://registry.npmjs.org/md5.js/-/md5.js-1.3.5.tgz", - "integrity": "sha512-xitP+WxNPcTTOgnTJcrhM0xvdPepipPSf3I8EIpGKeFLjt3PlJLIDG3u8EX53ZIubkb+5U2+3rELYpEhHhzdkg==", + "integrity": "sha1-tdB7jjIW4+J81yjXL3DR5qNCAF8=", "requires": { "hash-base": "^3.0.0", "inherits": "^2.0.1", @@ -8345,7 +8345,7 @@ "micromatch": { "version": "3.1.10", "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", - "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", + "integrity": "sha1-cIWbyVyYQJUvNZoGij/En57PrCM=", "requires": { "arr-diff": "^4.0.0", "array-unique": "^0.3.2", @@ -8365,14 +8365,14 @@ "kind-of": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "integrity": "sha1-ARRrNqYhjmTljzqNZt5df8b20FE=" } } }, "miller-rabin": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/miller-rabin/-/miller-rabin-4.0.1.tgz", - "integrity": "sha512-115fLhvZVqWwHPbClyntxEVfVDfl9DLLTuJvq3g2O/Oxi8AiNouAHvDSzHS0viUJc+V5vm3eq91Xwqn9dp4jRA==", + "integrity": "sha1-8IA1HIZbDcViqEYpZtqlNUPHik0=", "requires": { "bn.js": "^4.0.0", "brorand": "^1.0.1" @@ -8399,7 +8399,7 @@ "mimic-fn": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-1.2.0.tgz", - "integrity": "sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ==" + "integrity": "sha1-ggyGo5M0ZA6ZUWkovQP8qIBX0CI=" }, "mini-create-react-context": { "version": "0.3.2", @@ -8424,7 +8424,7 @@ "minimalistic-assert": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", - "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" + "integrity": "sha1-LhlN4ERibUoQ5/f7wAznPoPk1cc=" }, "minimalistic-crypto-utils": { "version": "1.0.1", @@ -8434,7 +8434,7 @@ "minimatch": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "integrity": "sha1-UWbihkV/AzBgZL5Ul+jbsMPTIIM=", "requires": { "brace-expansion": "^1.1.7" } @@ -8447,7 +8447,7 @@ "mississippi": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/mississippi/-/mississippi-3.0.0.tgz", - "integrity": "sha512-x471SsVjUtBRtcvd4BzKE9kFC+/2TeWgKCgw0bZcw1b9l2X3QX5vCWgF+KaZaYm87Ss//rHnWryupDrgLvmSkA==", + "integrity": "sha1-6goykfl+C16HdrNj1fChLZTGcCI=", "requires": { "concat-stream": "^1.5.0", "duplexify": "^3.4.2", @@ -8540,7 +8540,7 @@ "multicast-dns": { "version": "6.2.3", "resolved": "https://registry.npmjs.org/multicast-dns/-/multicast-dns-6.2.3.tgz", - "integrity": "sha512-ji6J5enbMyGRHIAkAOu3WdV8nggqviKCEKtXcOqfphZZtQrmHKycfynJ2V7eVPUA4NhJ6V7Wf4TmGbTwKE9B6g==", + "integrity": "sha1-oOx72QVcQoL3kMPIL04o2zsxsik=", "requires": { "dns-packet": "^1.3.1", "thunky": "^1.0.2" @@ -8611,7 +8611,7 @@ "nanomatch": { "version": "1.2.13", "resolved": "https://registry.npmjs.org/nanomatch/-/nanomatch-1.2.13.tgz", - "integrity": "sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA==", + "integrity": "sha1-uHqKpPwN6P5r6IiVs4mD/yZb0Rk=", "requires": { "arr-diff": "^4.0.0", "array-unique": "^0.3.2", @@ -8629,7 +8629,7 @@ "kind-of": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "integrity": "sha1-ARRrNqYhjmTljzqNZt5df8b20FE=" } } }, @@ -8651,12 +8651,12 @@ "nice-try": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", - "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==" + "integrity": "sha1-ozeKdpbOfSI+iPybdkvX7xCJ42Y=" }, "no-case": { "version": "2.3.2", "resolved": "https://registry.npmjs.org/no-case/-/no-case-2.3.2.tgz", - "integrity": "sha512-rmTZ9kz+f3rCvK2TD1Ue/oZlns7OGoIWP4fc3llxxRXlOkHKoWPPWJOfFYpITabSow43QJbRIoHQXtt10VldyQ==", + "integrity": "sha1-YLgTOWvjmz8SiKTB7V0efSi0ZKw=", "requires": { "lower-case": "^1.1.1" } @@ -8664,7 +8664,7 @@ "node-fetch": { "version": "1.7.3", "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-1.7.3.tgz", - "integrity": "sha512-NhZ4CsKx7cYm2vSrBAr2PvFOe6sWDf0UYLRqA6svUYg7+/TSfVAu49jYC4BvQ4Sms9SZgdqGBgroqfDhJdTyKQ==", + "integrity": "sha1-mA9vcthSEaU0fGsrwYxbhMPrR+8=", "requires": { "encoding": "^0.1.11", "is-stream": "^1.0.1" @@ -8790,7 +8790,7 @@ "normalize-url": { "version": "3.3.0", "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-3.3.0.tgz", - "integrity": "sha512-U+JJi7duF1o+u2pynbp2zXDW2/PADgC30f0GsHZtRh+HOcXHnw137TrNlyxxRvWW5fjKd3bcLHPxofWuCjaeZg==" + "integrity": "sha1-suHE3E98bVd0PfczpPWXjRhlBVk=" }, "npm-run-path": { "version": "2.0.2", @@ -8803,7 +8803,7 @@ "nth-check": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-1.0.2.tgz", - "integrity": "sha512-WeBOdju8SnzPN5vTUJYxYUxLeXpCaVP5i5e0LF8fg7WORF2Wd7wFX/pk0tYZk7s8T+J7VLy0Da6J1+wCT0AtHg==", + "integrity": "sha1-sr0pXDfj3VijvwcAN2Zjuk2c8Fw=", "requires": { "boolbase": "~1.0.0" } @@ -8826,7 +8826,7 @@ "oauth-sign": { "version": "0.9.0", "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz", - "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==" + "integrity": "sha1-R6ewFrqmi1+g7PPe4IqFxnmsZFU=" }, "object-assign": { "version": "4.1.1", @@ -8874,7 +8874,7 @@ "object.assign": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", - "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", + "integrity": "sha1-lovxEA15Vrs8oIbwBvhGs7xACNo=", "requires": { "define-properties": "^1.1.2", "function-bind": "^1.1.1", @@ -8924,7 +8924,7 @@ "obuf": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/obuf/-/obuf-1.1.2.tgz", - "integrity": "sha512-PX1wu0AmAdPqOL1mWhqmlOd8kOIZQwGZw6rh7uby9fTc5lhaOWFLX3I6R1hrF9k3zUY40e6igsLGkDXK92LJNg==" + "integrity": "sha1-Cb6jND1BhZ69RGKS0RydTbYZCE4=" }, "on-finished": { "version": "2.3.0", @@ -8987,7 +8987,7 @@ "optimize-css-assets-webpack-plugin": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/optimize-css-assets-webpack-plugin/-/optimize-css-assets-webpack-plugin-5.0.1.tgz", - "integrity": "sha512-Rqm6sSjWtx9FchdP0uzTQDc7GXDKnwVEGoSxjezPkzMewx7gEWE9IMUYKmigTRC4U3RaNSwYVnUDLuIdtTpm0A==", + "integrity": "sha1-nrUAcR01FltF5/1gui30DLPrkVk=", "requires": { "cssnano": "^4.1.0", "last-call-webpack-plugin": "^3.0.0" @@ -9009,7 +9009,7 @@ "original": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/original/-/original-1.0.2.tgz", - "integrity": "sha512-hyBVl6iqqUOJ8FqRe+l/gS8H+kKYjrEndd5Pm1MfBtsEKA038HkkdbAl/72EAXGyonD/PFsvmVG+EvcIpliMBg==", + "integrity": "sha1-5EKmHP/hxf0gpl8yYcJmY7MD8l8=", "requires": { "url-parse": "^1.4.3" } @@ -9068,7 +9068,7 @@ "p-locate": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "integrity": "sha1-Mi1poFwCZLJZl9n0DNiokasAZKQ=", "requires": { "p-limit": "^2.0.0" } @@ -9076,7 +9076,7 @@ "p-map": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/p-map/-/p-map-1.2.0.tgz", - "integrity": "sha512-r6zKACMNhjPJMTl8KcFH4li//gkrXWfbD6feV8l6doRHlzljFWGJ2AP6iKaCJXyZmAUMOPtvbW7EXkbWO/pLEA==" + "integrity": "sha1-5OlPMR6rvIYzoeeZCBZfyiYkG2s=" }, "p-reduce": { "version": "1.0.0", @@ -9166,7 +9166,7 @@ "path-browserify": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/path-browserify/-/path-browserify-0.0.1.tgz", - "integrity": "sha512-BapA40NHICOS+USX9SN4tyhq+A2RrN/Ws5F0Z5aMHDp98Fl86lX8Oti8B7uN93L4Ifv4fHOEA+pQw87gmMO/lQ==" + "integrity": "sha1-5sTd1+06onxoogzE5Q4aTug7vEo=" }, "path-dirname": { "version": "1.0.2", @@ -9196,7 +9196,7 @@ "path-parse": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", - "integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==" + "integrity": "sha1-1i27VnlAXXLEc37FhgDp3c8G0kw=" }, "path-to-regexp": { "version": "0.1.7", @@ -9206,7 +9206,7 @@ "path-type": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/path-type/-/path-type-3.0.0.tgz", - "integrity": "sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg==", + "integrity": "sha1-zvMdyOCho7sNEFwM2Xzzv0f0428=", "requires": { "pify": "^3.0.0" } @@ -9214,7 +9214,7 @@ "pbkdf2": { "version": "3.0.17", "resolved": "https://registry.npmjs.org/pbkdf2/-/pbkdf2-3.0.17.tgz", - "integrity": "sha512-U/il5MsrZp7mGg3mSQfn742na2T+1/vHDCG5/iTI3X9MKUuYUZVLQhyRsg06mCgDBTd57TxzgZt7P+fYfjRLtA==", + "integrity": "sha1-l2wgZTBhexTrsyEUI597CTNuk6Y=", "requires": { "create-hash": "^1.1.2", "create-hmac": "^1.1.4", @@ -9257,7 +9257,7 @@ "pkg-dir": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-3.0.0.tgz", - "integrity": "sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw==", + "integrity": "sha1-J0kCDyOe2ZCIGx9xIQ1R62UjvqM=", "requires": { "find-up": "^3.0.0" } @@ -9415,7 +9415,7 @@ "postcss-calc": { "version": "7.0.1", "resolved": "https://registry.npmjs.org/postcss-calc/-/postcss-calc-7.0.1.tgz", - "integrity": "sha512-oXqx0m6tb4N3JGdmeMSc/i91KppbYsFZKdH0xMOqK8V1rJlzrKlTdokz8ozUXLVejydRN6u2IddxpcijRj2FqQ==", + "integrity": "sha1-Ntd7qwI7Dsu5eJ2E3LI8SUEUVDY=", "requires": { "css-unit-converter": "^1.1.1", "postcss": "^7.0.5", @@ -9426,7 +9426,7 @@ "cssesc": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-2.0.0.tgz", - "integrity": "sha512-MsCAG1z9lPdoO/IUMLSBWBSVxVtJ1395VGIQ+Fc2gNdkQ1hNDnQdw3YhA71WJCBW1vdwA0cAnk/DnW6bqoEUYg==" + "integrity": "sha1-OxO9G7HLNuG8taTc0n9UxdyzVwM=" }, "postcss-selector-parser": { "version": "5.0.0", @@ -9502,7 +9502,7 @@ "postcss-convert-values": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/postcss-convert-values/-/postcss-convert-values-4.0.1.tgz", - "integrity": "sha512-Kisdo1y77KUC0Jmn0OXU/COOJbzM8cImvw1ZFsBgBgMgb1iL23Zs/LXRe3r+EZqM3vGYKdQ2YJVQ5VkJI+zEJQ==", + "integrity": "sha1-yjgT7U2g+BL51DcDWE5Enr4Ymn8=", "requires": { "postcss": "^7.0.0", "postcss-value-parser": "^3.0.0" @@ -9588,7 +9588,7 @@ "postcss-discard-duplicates": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/postcss-discard-duplicates/-/postcss-discard-duplicates-4.0.2.tgz", - "integrity": "sha512-ZNQfR1gPNAiXZhgENFfEglF93pciw0WxMkJeVmw8eF+JZBbMD7jp6C67GqJAXVZP2BWbOztKfbsdmMp/k8c6oQ==", + "integrity": "sha1-P+EzzTyCKC5VD8myORdqkge3hOs=", "requires": { "postcss": "^7.0.0" } @@ -9596,7 +9596,7 @@ "postcss-discard-empty": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/postcss-discard-empty/-/postcss-discard-empty-4.0.1.tgz", - "integrity": "sha512-B9miTzbznhDjTfjvipfHoqbWKwd0Mj+/fL5s1QOz06wufguil+Xheo4XpOnc4NqKYBCNqqEzgPv2aPBIJLox0w==", + "integrity": "sha1-yMlR6fc+2UKAGUWERKAq2Qu592U=", "requires": { "postcss": "^7.0.0" } @@ -9604,7 +9604,7 @@ "postcss-discard-overridden": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/postcss-discard-overridden/-/postcss-discard-overridden-4.0.1.tgz", - "integrity": "sha512-IYY2bEDD7g1XM1IDEsUT4//iEYCxAmP5oDSFMVU/JVvT7gh+l4fmjciLqGgwjdWpQIdb0Che2VX00QObS5+cTg==", + "integrity": "sha1-ZSrvipZybwKfXj4AFG7npOdV/1c=", "requires": { "postcss": "^7.0.0" } @@ -9707,7 +9707,7 @@ "postcss-loader": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/postcss-loader/-/postcss-loader-3.0.0.tgz", - "integrity": "sha512-cLWoDEY5OwHcAjDnkyRQzAXfs2jrKjXpO/HQFcc5b5u/r7aa471wdmChmwfnv7x2u840iat/wi0lQ5nbRgSkUA==", + "integrity": "sha1-a5eUPkfHLYRfqeA/Jzdz1OjdbC0=", "requires": { "loader-utils": "^1.1.0", "postcss": "^7.0.0", @@ -9770,7 +9770,7 @@ "postcss-minify-font-values": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/postcss-minify-font-values/-/postcss-minify-font-values-4.0.2.tgz", - "integrity": "sha512-j85oO6OnRU9zPf04+PZv1LYIYOprWm6IA6zkXkrJXyRveDEuQggG6tvoy8ir8ZwjLxLuGfNkCZEQG7zan+Hbtg==", + "integrity": "sha1-zUw0TM5HQ0P6xdgiBqssvLiv1aY=", "requires": { "postcss": "^7.0.0", "postcss-value-parser": "^3.0.0" @@ -9881,7 +9881,7 @@ "postcss-normalize-charset": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/postcss-normalize-charset/-/postcss-normalize-charset-4.0.1.tgz", - "integrity": "sha512-gMXCrrlWh6G27U0hF3vNvR3w8I1s2wOBILvA87iNXaPvSNo5uZAMYsZG7XjCUf1eVxuPfyL4TJ7++SGZLc9A3g==", + "integrity": "sha1-izWt067oOhNrBHHg1ZvlilAoXdQ=", "requires": { "postcss": "^7.0.0" } @@ -9941,7 +9941,7 @@ "postcss-normalize-unicode": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/postcss-normalize-unicode/-/postcss-normalize-unicode-4.0.1.tgz", - "integrity": "sha512-od18Uq2wCYn+vZ/qCOeutvHjB5jm57ToxRaMeNuf0nWVHaP9Hua56QyMF6fs/4FSUnVIw0CBPsU0K4LnBPwYwg==", + "integrity": "sha1-hBvUj9zzAZrUuqdJOj02O1KuHPs=", "requires": { "browserslist": "^4.0.0", "postcss": "^7.0.0", @@ -9951,7 +9951,7 @@ "postcss-normalize-url": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/postcss-normalize-url/-/postcss-normalize-url-4.0.1.tgz", - "integrity": "sha512-p5oVaF4+IHwu7VpMan/SSpmpYxcJMtkGppYf0VbdH5B6hN8YNmVyJLuY9FmLQTzY3fag5ESUUHDqM+heid0UVA==", + "integrity": "sha1-EOQ3+GvHx+WPe5ZS7YeNqqlfquE=", "requires": { "is-absolute-url": "^2.0.0", "normalize-url": "^3.0.0", @@ -10106,7 +10106,7 @@ "postcss-safe-parser": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/postcss-safe-parser/-/postcss-safe-parser-4.0.1.tgz", - "integrity": "sha512-xZsFA3uX8MO3yAda03QrG3/Eg1LN3EPfjjf07vke/46HERLZyHrTsQ9E1r1w1W//fWEhtYNndo2hQplN2cVpCQ==", + "integrity": "sha1-h1bZ5MNv3OLHKwkbvIyhdqsfzeo=", "requires": { "postcss": "^7.0.0" } @@ -10153,7 +10153,7 @@ "postcss-unique-selectors": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/postcss-unique-selectors/-/postcss-unique-selectors-4.0.1.tgz", - "integrity": "sha512-+JanVaryLo9QwZjKrmJgkI4Fn8SBgRO6WXQBJi7KiAVPlmxikB5Jzc4EvXMT2H0/m0RjrVVm9rGNhZddm/8Spg==", + "integrity": "sha1-lEaRHzKJv9ZMbWgPBzwDsfnuS6w=", "requires": { "alphanum-sort": "^1.0.0", "postcss": "^7.0.0", @@ -10163,7 +10163,7 @@ "postcss-value-parser": { "version": "3.3.1", "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-3.3.1.tgz", - "integrity": "sha512-pISE66AbVkp4fDQ7VHBwRNXzAAKJjw4Vw7nWI/+Q3vuly7SNfgYXvm6i5IgFylHGK5sP/xHAbB7N49OS4gWNyQ==" + "integrity": "sha1-n/giVH4okyE88cMO+lGsX9G6goE=" }, "postcss-values-parser": { "version": "2.0.1", @@ -10215,7 +10215,7 @@ "private": { "version": "0.1.8", "resolved": "https://registry.npmjs.org/private/-/private-0.1.8.tgz", - "integrity": "sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg==" + "integrity": "sha1-I4Hts2ifelPWUxkAYPz4ItLzaP8=" }, "process": { "version": "0.11.10", @@ -10294,7 +10294,7 @@ "public-encrypt": { "version": "4.0.3", "resolved": "https://registry.npmjs.org/public-encrypt/-/public-encrypt-4.0.3.tgz", - "integrity": "sha512-zVpa8oKZSz5bTMTFClc1fQOnyyEzpl5ozpi1B5YcvBrdohMjH2rfsBtyXcuNuwjsDIXmBYlF2N5FlJYhR29t8Q==", + "integrity": "sha1-T8ydd6B+SLp1J+fL4N4z0HATMeA=", "requires": { "bn.js": "^4.1.0", "browserify-rsa": "^4.0.0", @@ -10307,7 +10307,7 @@ "pump": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", - "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "integrity": "sha1-tKIRaBW94vTh6mAjVOjHVWUQemQ=", "requires": { "end-of-stream": "^1.1.0", "once": "^1.3.1" @@ -10316,7 +10316,7 @@ "pumpify": { "version": "1.5.1", "resolved": "https://registry.npmjs.org/pumpify/-/pumpify-1.5.1.tgz", - "integrity": "sha512-oClZI37HvuUJJxSKKrC17bZ9Cu0ZYhEAGPsPUy9KlMUmv9dKX2o77RUmq7f3XjIxbwyGwYzbzQ1L2Ks8sIradQ==", + "integrity": "sha1-NlE74karJ1cLGjdKXOJ4v9dDcM4=", "requires": { "duplexify": "^3.6.0", "inherits": "^2.0.3", @@ -10326,7 +10326,7 @@ "pump": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/pump/-/pump-2.0.1.tgz", - "integrity": "sha512-ruPMNRkN3MHP1cWJc9OWr+T/xDP0jhXYCLfJcBuX54hhfIBnaQmAUMfDcG4DM5UMWByBbJY69QSphm3jtDKIkA==", + "integrity": "sha1-Ejma3W5M91Jtlzy8i1zi4pCLOQk=", "requires": { "end-of-stream": "^1.1.0", "once": "^1.3.1" @@ -10337,7 +10337,7 @@ "punycode": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", - "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==" + "integrity": "sha1-tYsBCsQMIsVldhbI0sLALHv0eew=" }, "q": { "version": "1.5.1", @@ -10347,7 +10347,7 @@ "qs": { "version": "6.5.2", "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", - "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==" + "integrity": "sha1-yzroBuh0BERYTvFUzo7pjUA/PjY=" }, "querystring": { "version": "0.2.0", @@ -10383,7 +10383,7 @@ "randomfill": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/randomfill/-/randomfill-1.0.4.tgz", - "integrity": "sha512-87lcbR8+MhcWcUiQ+9e+Rwx8MyR2P7qnt15ynUlbm3TU/fjbgz4GsvfSUDTemtCCtVCqb4ZcEFlyPNTh9bBTLw==", + "integrity": "sha1-ySGW/IarQr6YPxvzF3giSTHWFFg=", "requires": { "randombytes": "^2.0.5", "safe-buffer": "^5.1.0" @@ -10713,7 +10713,7 @@ "readdirp": { "version": "2.2.1", "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-2.2.1.tgz", - "integrity": "sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ==", + "integrity": "sha1-DodiKjMlqjPokihcr4tOhGUppSU=", "requires": { "graceful-fs": "^4.1.11", "micromatch": "^3.1.10", @@ -10739,7 +10739,7 @@ "regenerate": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.0.tgz", - "integrity": "sha512-1G6jJVDWrt0rK99kBjvEtziZNCICAuvIPkSiUFIQxVP06RCVpq3dmDo2oi6ABpYaDYaTRr67BEhL8r1wgEZZKg==" + "integrity": "sha1-SoVuxLVuQHfFV1icroXnpMiGmhE=" }, "regenerate-unicode-properties": { "version": "8.1.0", @@ -10765,7 +10765,7 @@ "regex-not": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/regex-not/-/regex-not-1.0.2.tgz", - "integrity": "sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A==", + "integrity": "sha1-H07OJ+ALC2XgJHpoEOaoXYOldSw=", "requires": { "extend-shallow": "^3.0.2", "safe-regex": "^1.1.0" @@ -10874,7 +10874,7 @@ "repeat-element": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/repeat-element/-/repeat-element-1.1.3.tgz", - "integrity": "sha512-ahGq0ZnV5m5XtZLMb+vP76kcAM5nkLqk0lpqAuojSKGgQtn4eRi4ZZGm2olo2zKFH+sMsWaqOCW1dqAnOru72g==" + "integrity": "sha1-eC4NglwMWjuzlzH4Tv7mt0Lmsc4=" }, "repeat-string": { "version": "1.6.1", @@ -10884,7 +10884,7 @@ "request": { "version": "2.88.0", "resolved": "https://registry.npmjs.org/request/-/request-2.88.0.tgz", - "integrity": "sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg==", + "integrity": "sha1-nC/KT301tZLv5Xx/ClXoEFIST+8=", "requires": { "aws-sign2": "~0.7.0", "aws4": "^1.8.0", @@ -10916,7 +10916,7 @@ "tough-cookie": { "version": "2.4.3", "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.4.3.tgz", - "integrity": "sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ==", + "integrity": "sha1-U/Nto/R3g7CSWvoG/587FlKA94E=", "requires": { "psl": "^1.1.24", "punycode": "^1.4.1" @@ -11005,7 +11005,7 @@ "ret": { "version": "0.1.15", "resolved": "https://registry.npmjs.org/ret/-/ret-0.1.15.tgz", - "integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg==" + "integrity": "sha1-uKSCXVvbH8P29Twrwz+BOIaBx7w=" }, "rgb-regex": { "version": "1.0.1", @@ -11028,7 +11028,7 @@ "ripemd160": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/ripemd160/-/ripemd160-2.0.2.tgz", - "integrity": "sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA==", + "integrity": "sha1-ocGm9iR1FXe6XQeRTLyShQWFiQw=", "requires": { "hash-base": "^3.0.0", "inherits": "^2.0.1" @@ -11111,7 +11111,7 @@ "safer-buffer": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + "integrity": "sha1-RPoWGwGHuVSd2Eu5GAL5vYOFzWo=" }, "sane": { "version": "4.1.0", @@ -11132,7 +11132,7 @@ "sass-loader": { "version": "7.1.0", "resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-7.1.0.tgz", - "integrity": "sha512-+G+BKGglmZM2GUSfT9TLuEp6tzehHPjAMoRRItOojWIqIGPloVCMhNIQuG639eJ+y033PaGTSjLaTHts8Kw79w==", + "integrity": "sha1-Fv1ROMuLQkv4p1lSihly1yqtBp0=", "requires": { "clone-deep": "^2.0.1", "loader-utils": "^1.0.1", @@ -11145,7 +11145,7 @@ "clone-deep": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/clone-deep/-/clone-deep-2.0.2.tgz", - "integrity": "sha512-SZegPTKjCgpQH63E+eN6mVEEPdQBOUzjyJm5Pora4lrwWRFS8I0QAxV/KD6vV/i0WuijHZWQC1fMsPEdxfdVCQ==", + "integrity": "sha1-ANs6Hhc2VnMNEYjD1qztbX6pdxM=", "requires": { "for-own": "^1.0.0", "is-plain-object": "^2.0.4", @@ -11164,7 +11164,7 @@ "kind-of": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "integrity": "sha1-ARRrNqYhjmTljzqNZt5df8b20FE=" }, "semver": { "version": "5.7.0", @@ -11174,7 +11174,7 @@ "shallow-clone": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/shallow-clone/-/shallow-clone-1.0.0.tgz", - "integrity": "sha512-oeXreoKR/SyNJtRJMAKPDSvd28OqEwG4eR/xc856cRGBII7gX9lvAqDxusPm0846z/w/hWYjI1NpKwJ00NHzRA==", + "integrity": "sha1-RIDNBuiC72iyrYij6lSDLixItXE=", "requires": { "is-extendable": "^0.1.1", "kind-of": "^5.0.0", @@ -11184,7 +11184,7 @@ "kind-of": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", - "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + "integrity": "sha1-cpyR4thXt6QZofmqZWhcTDP1hF0=" } } } @@ -11193,7 +11193,7 @@ "sax": { "version": "1.2.4", "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz", - "integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==" + "integrity": "sha1-KBYjTiN4vdxOU1T6tcqold9xANk=" }, "saxes": { "version": "3.1.11", @@ -11215,7 +11215,7 @@ "schema-utils": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-1.0.0.tgz", - "integrity": "sha512-i27Mic4KovM/lnGsy8whRCHhc7VicJajAjTrYg11K9zfZXnYIt4k5F+kZkwjnrhKzLic/HLU4j11mjsz2G/75g==", + "integrity": "sha1-C3mpMgTXtgDUsoUNH2bCo0lRx3A=", "requires": { "ajv": "^6.1.0", "ajv-errors": "^1.0.0", @@ -11309,7 +11309,7 @@ "debug": { "version": "2.6.9", "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "integrity": "sha1-XRKFFd8TT/Mn6QpMk/Tgd6U2NB8=", "requires": { "ms": "2.0.0" } @@ -11338,7 +11338,7 @@ "setprototypeof": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.0.tgz", - "integrity": "sha512-BvE/TwpZX4FXExxOxZyRGQQv651MSwmWKZGqvmPcRIjDqWub67kTKuIMx43cZZrS/cBBzwBcNDWoFxt2XEFIpQ==" + "integrity": "sha1-0L2FU2iHtv58DYGMuWLZ2RxU5lY=" } } }, @@ -11469,7 +11469,7 @@ "is-arrayish": { "version": "0.3.2", "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.3.2.tgz", - "integrity": "sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==" + "integrity": "sha1-RXSirlb3qyBolvtDHq7tBm/fjwM=" } } }, @@ -11496,7 +11496,7 @@ "snapdragon": { "version": "0.8.2", "resolved": "https://registry.npmjs.org/snapdragon/-/snapdragon-0.8.2.tgz", - "integrity": "sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg==", + "integrity": "sha1-ZJIufFZbDhQgS6GqfWlkJ40lGC0=", "requires": { "base": "^0.11.1", "debug": "^2.2.0", @@ -11511,7 +11511,7 @@ "debug": { "version": "2.6.9", "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "integrity": "sha1-XRKFFd8TT/Mn6QpMk/Tgd6U2NB8=", "requires": { "ms": "2.0.0" } @@ -11542,7 +11542,7 @@ "snapdragon-node": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/snapdragon-node/-/snapdragon-node-2.1.1.tgz", - "integrity": "sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw==", + "integrity": "sha1-bBdfhv8UvbByRWPo88GwIaKGhTs=", "requires": { "define-property": "^1.0.0", "isobject": "^3.0.0", @@ -11560,7 +11560,7 @@ "is-accessor-descriptor": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", - "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "integrity": "sha1-FpwvbT3x+ZJhgHI2XJsOofaHhlY=", "requires": { "kind-of": "^6.0.0" } @@ -11568,7 +11568,7 @@ "is-data-descriptor": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "integrity": "sha1-2Eh2Mh0Oet0DmQQGq7u9NrqSaMc=", "requires": { "kind-of": "^6.0.0" } @@ -11576,7 +11576,7 @@ "is-descriptor": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", - "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "integrity": "sha1-OxWXRqZmBLBPjIFSS6NlxfFNhuw=", "requires": { "is-accessor-descriptor": "^1.0.0", "is-data-descriptor": "^1.0.0", @@ -11586,14 +11586,14 @@ "kind-of": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "integrity": "sha1-ARRrNqYhjmTljzqNZt5df8b20FE=" } } }, "snapdragon-util": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/snapdragon-util/-/snapdragon-util-3.0.1.tgz", - "integrity": "sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ==", + "integrity": "sha1-+VZHlIbyrNeXAGk/b3uAXkWrVuI=", "requires": { "kind-of": "^3.2.0" } @@ -11601,7 +11601,7 @@ "sockjs": { "version": "0.3.19", "resolved": "https://registry.npmjs.org/sockjs/-/sockjs-0.3.19.tgz", - "integrity": "sha512-V48klKZl8T6MzatbLlzzRNhMepEys9Y4oGFpypBFFn1gLI/QQ9HtLLyWJNbPlwGLelOVOEijUbTTJeLLI59jLw==", + "integrity": "sha1-2Xa76ACve9IK4IWY1YI5NQiZPA0=", "requires": { "faye-websocket": "^0.10.0", "uuid": "^3.0.1" @@ -11643,7 +11643,7 @@ "source-list-map": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/source-list-map/-/source-list-map-2.0.1.tgz", - "integrity": "sha512-qnQ7gVMxGNxsiL4lEuJwe/To8UnK7fAnmbGEEH8RpLouuKbeEm0lhbQVFIrNSuB+G7tVrAlVsZgETT5nljf+Iw==" + "integrity": "sha1-OZO9hzv8SEecyp6jpUeDXHwVSzQ=" }, "source-map": { "version": "0.5.7", @@ -11653,7 +11653,7 @@ "source-map-resolve": { "version": "0.5.2", "resolved": "https://registry.npmjs.org/source-map-resolve/-/source-map-resolve-0.5.2.tgz", - "integrity": "sha512-MjqsvNwyz1s0k81Goz/9vRBe9SZdB09Bdw+/zYyO+3CuPk6fouTaxscHkgtE8jKvf01kVfl8riHzERQ/kefaSA==", + "integrity": "sha1-cuLMNAlVQ+Q7LGKyxMENSpBU8lk=", "requires": { "atob": "^2.1.1", "decode-uri-component": "^0.2.0", @@ -11695,12 +11695,12 @@ "spdx-exceptions": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz", - "integrity": "sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA==" + "integrity": "sha1-LqRQrudPKom/uUUZwH/Nb0EyKXc=" }, "spdx-expression-parse": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz", - "integrity": "sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg==", + "integrity": "sha1-meEZt6XaAOBUkcn6M4t5BII7QdA=", "requires": { "spdx-exceptions": "^2.1.0", "spdx-license-ids": "^3.0.0" @@ -11751,7 +11751,7 @@ "split-string": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/split-string/-/split-string-3.1.0.tgz", - "integrity": "sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==", + "integrity": "sha1-fLCd2jqGWFcFxks5pkZgOGguj+I=", "requires": { "extend-shallow": "^3.0.0" } @@ -11780,7 +11780,7 @@ "ssri": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/ssri/-/ssri-6.0.1.tgz", - "integrity": "sha512-3Wge10hNcT1Kur4PDFwEieXSCMCJs/7WvSACcrMYrNp+b8kDL1/0wJch5Ni2WrtwEa2IO8OsVfeKIciKCDx/QA==", + "integrity": "sha1-KjxBso3UW2K2Nnbst0ABJlrp7dg=", "requires": { "figgy-pudding": "^3.5.1" } @@ -11788,7 +11788,7 @@ "stable": { "version": "0.1.8", "resolved": "https://registry.npmjs.org/stable/-/stable-0.1.8.tgz", - "integrity": "sha512-ji9qxRnOVfcuLDySj9qzhGSEFVobyt1kIOSkj1qZzYLzq7Tos/oUUWvotUPQLlrsidqsK6tBH89Bc9kL5zHA6w==" + "integrity": "sha1-g26zyDgv4pNv6vVEYxAXzn1Ho88=" }, "stack-utils": { "version": "1.0.2", @@ -11836,7 +11836,7 @@ "stream-each": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/stream-each/-/stream-each-1.2.3.tgz", - "integrity": "sha512-vlMC2f8I2u/bZGqkdfLQW/13Zihpej/7PmSiMQsbYddxuTsJp8vRe2x2FvVExZg7FaOds43ROAuFJwPR4MTZLw==", + "integrity": "sha1-6+J6DDibBPvMIzZClS4Qcxr6m64=", "requires": { "end-of-stream": "^1.1.0", "stream-shift": "^1.0.0" @@ -11845,7 +11845,7 @@ "stream-http": { "version": "2.8.3", "resolved": "https://registry.npmjs.org/stream-http/-/stream-http-2.8.3.tgz", - "integrity": "sha512-+TSkfINHDo4J+ZobQLWiMouQYB+UVYFttRA94FpEzzJ7ZdqcL4uUUQ7WkdkI4DSozGmgBUE/a47L+38PenXhUw==", + "integrity": "sha1-stJCRpKIpaJ+xP6JM6z2I95lFPw=", "requires": { "builtin-status-codes": "^3.0.0", "inherits": "^2.0.1", @@ -11871,7 +11871,7 @@ "string-width": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "integrity": "sha1-q5Pyeo3BPSjKyBXEYhQ6bZASrp4=", "requires": { "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^4.0.0" @@ -11888,7 +11888,7 @@ "stringify-object": { "version": "3.3.0", "resolved": "https://registry.npmjs.org/stringify-object/-/stringify-object-3.3.0.tgz", - "integrity": "sha512-rHqiFh1elqCQ9WPLIC8I0Q/g/wj5J1eMkyoiD6eoQApWHP0FtlK7rqnhmabL5VUY9JQCcqwwvlOaSuutekgyrw==", + "integrity": "sha1-cDBlrvyhkwDTzoivT1s5VtdVZik=", "requires": { "get-own-enumerable-property-symbols": "^3.0.0", "is-obj": "^1.0.1", @@ -11911,7 +11911,7 @@ "strip-comments": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/strip-comments/-/strip-comments-1.0.2.tgz", - "integrity": "sha512-kL97alc47hoyIQSV165tTt9rG5dn4w1dNnBhOQ3bOU1Nc1hel09jnXANaHJ7vzHLd4Ju8kseDGzlev96pghLFw==", + "integrity": "sha1-grnEXn8FhzvuU/NxaK+TCqNoZ50=", "requires": { "babel-extract-comments": "^1.0.0", "babel-plugin-transform-object-rest-spread": "^6.26.0" @@ -12011,7 +12011,7 @@ "supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "integrity": "sha1-4uaaRKyHcveKHsCzW2id9lMO/I8=", "requires": { "has-flag": "^3.0.0" } @@ -12197,7 +12197,7 @@ "tmp": { "version": "0.0.33", "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", - "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", + "integrity": "sha1-bTQzWIl2jSGyvNoKonfO07G/rfk=", "requires": { "os-tmpdir": "~1.0.2" } @@ -12228,7 +12228,7 @@ "to-regex": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/to-regex/-/to-regex-3.0.2.tgz", - "integrity": "sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw==", + "integrity": "sha1-E8/dmzNlUvMLUfM6iuG0Knp1mc4=", "requires": { "define-property": "^2.0.2", "extend-shallow": "^3.0.2", @@ -12364,12 +12364,12 @@ "unicode-canonical-property-names-ecmascript": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz", - "integrity": "sha512-jDrNnXWHd4oHiTZnx/ZG7gtUTVp+gCcTTKr8L0HjlwphROEW3+Him+IpvC+xcJEFegapiMZyZe02CyuOnRmbnQ==" + "integrity": "sha1-JhmADEyCWADv3YNDr33Zkzy+KBg=" }, "unicode-match-property-ecmascript": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-1.0.4.tgz", - "integrity": "sha512-L4Qoh15vTfntsn4P1zqnHulG0LdXgjSO035fEpdtp6YxXhMT51Q6vgM5lYdG/5X3MjS+k/Y9Xw4SFCY9IkR0rg==", + "integrity": "sha1-jtKjJWmWG86SJ9Cc0/+7j+1fAgw=", "requires": { "unicode-canonical-property-names-ecmascript": "^1.0.4", "unicode-property-aliases-ecmascript": "^1.0.4" @@ -12409,7 +12409,7 @@ "unique-filename": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/unique-filename/-/unique-filename-1.1.1.tgz", - "integrity": "sha512-Vmp0jIp2ln35UTXuryvjzkjGdRyf9b2lTXuSYUiPmzRcl3FDtYqAwOnTJkAngD9SWhnoJzDbTKwaOrZ+STtxNQ==", + "integrity": "sha1-HWl2k2mtoFgxA6HmrodoG1ZXMjA=", "requires": { "unique-slug": "^2.0.0" } @@ -12425,7 +12425,7 @@ "universalify": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", - "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==" + "integrity": "sha1-tkb2m+OULavOzJ1mOcgNwQXvqmY=" }, "unpipe": { "version": "1.0.0", @@ -12486,7 +12486,7 @@ "uri-js": { "version": "4.2.2", "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", - "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", + "integrity": "sha1-lMVA4f93KVbiKZUHwBCupsiDjrA=", "requires": { "punycode": "^2.1.0" } @@ -12534,7 +12534,7 @@ "use": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/use/-/use-3.1.1.tgz", - "integrity": "sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ==" + "integrity": "sha1-1QyMrHmhn7wg8pEfVuuXP04QBw8=" }, "util": { "version": "0.11.1", @@ -12559,7 +12559,7 @@ "util.promisify": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/util.promisify/-/util.promisify-1.0.0.tgz", - "integrity": "sha512-i+6qA2MPhvoKLuxnJNpXAGhg7HphQOSUq2LKMZD0m15EiskXUkMvKdF4Uui0WYeCUGea+o2cw/ZuwehtfsrNkA==", + "integrity": "sha1-RA9xZaRZyaFtwUXrjnLzVocJcDA=", "requires": { "define-properties": "^1.1.2", "object.getownpropertydescriptors": "^2.0.3" @@ -12583,7 +12583,7 @@ "validate-npm-package-license": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz", - "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", + "integrity": "sha1-/JH2uce6FchX9MssXe/uw51PQQo=", "requires": { "spdx-correct": "^3.0.0", "spdx-expression-parse": "^3.0.0" @@ -12653,7 +12653,7 @@ "watchpack": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-1.6.0.tgz", - "integrity": "sha512-i6dHe3EyLjMmDlU1/bGQpEw25XSjkJULPuAVKCbNRefQVq48yXKUpwg538F7AZTf9kyr57zj++pQFltUa5H7yA==", + "integrity": "sha1-S8EsLr6KonenHx0/FNaFx7RGzQA=", "requires": { "chokidar": "^2.0.2", "graceful-fs": "^4.1.2", @@ -12663,7 +12663,7 @@ "wbuf": { "version": "1.7.3", "resolved": "https://registry.npmjs.org/wbuf/-/wbuf-1.7.3.tgz", - "integrity": "sha512-O84QOnr0icsbFGLS0O3bI5FswxzRr8/gHwWkDlQFskhSPryQXvrTMxjxGP4+iWYoauLoBvfDpkrOauZ+0iZpDA==", + "integrity": "sha1-wdjRSTFtPqhShIiVy2oL/oh7h98=", "requires": { "minimalistic-assert": "^1.0.0" } @@ -12828,7 +12828,7 @@ "webpack-log": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/webpack-log/-/webpack-log-2.0.0.tgz", - "integrity": "sha512-cX8G2vR/85UYG59FgkoMamwHUIkSSlV3bBMRsbxVXVUk2j6NleCKjQ/WE9eYg9WY4w25O9w8wKP4rzNZFmUcUg==", + "integrity": "sha1-W3ko4GN1k/EZ0y9iJ8HgrDHhtH8=", "requires": { "ansi-colors": "^3.0.0", "uuid": "^3.3.2" @@ -12873,7 +12873,7 @@ "websocket-extensions": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/websocket-extensions/-/websocket-extensions-0.1.3.tgz", - "integrity": "sha512-nqHUnMXmBzT0w570r2JpJxfiSD1IzoI+HGVdd3aZ0yNi3ngvQ4jv1dtHt5VGxfI2yj5yqImPhOK4vmIh2xMbGg==" + "integrity": "sha1-XS/yKXcAPsaHpLhwc9+7rBRszyk=" }, "whatwg-encoding": { "version": "1.0.5", @@ -12886,7 +12886,7 @@ "whatwg-fetch": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/whatwg-fetch/-/whatwg-fetch-3.0.0.tgz", - "integrity": "sha512-9GSJUgz1D4MfyKU7KRqwOjXCXTqWdFNvEr7eUBYchQiVc744mqK/MzXPNR2WsPkmkOa4ywfg8C2n8h+13Bey1Q==" + "integrity": "sha1-/IBORYzEYACbGiuWa8iBfSV4rvs=" }, "whatwg-mimetype": { "version": "2.3.0", @@ -12906,7 +12906,7 @@ "which": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "integrity": "sha1-pFBD1U9YBTFtqNYvn1CRjT2nCwo=", "requires": { "isexe": "^2.0.0" } @@ -13184,7 +13184,7 @@ "xregexp": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/xregexp/-/xregexp-4.0.0.tgz", - "integrity": "sha512-PHyM+sQouu7xspQQwELlGwwd05mXUFqwFYfqPO0cC7x4fxyHnnuetmQr6CjJiafIDoH4MogHb9dOoJzR/Y4rFg==" + "integrity": "sha1-5pgYneSd0qGMxWh7BeF8jkOUMCA=" }, "xtend": { "version": "4.0.2", @@ -13209,7 +13209,7 @@ "y18n": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", - "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==" + "integrity": "sha1-le+U+F7MgdAHwmThkKEg8KPIVms=" }, "yallist": { "version": "3.0.3", diff --git a/lotuspond/front/src/FullNode.js b/lotuspond/front/src/FullNode.js index f9ca779a5..c67faba9f 100644 --- a/lotuspond/front/src/FullNode.js +++ b/lotuspond/front/src/FullNode.js @@ -106,7 +106,7 @@ class FullNode extends React.Component { ) } - let storageMine = + let storageMine = let addresses = this.state.addrs.map((addr) => { let line =
diff --git a/lotuspond/front/src/StorageNode.js b/lotuspond/front/src/StorageNode.js index c4895c2ea..4f2005a67 100644 --- a/lotuspond/front/src/StorageNode.js +++ b/lotuspond/front/src/StorageNode.js @@ -127,7 +127,7 @@ class StorageNode extends React.Component { runtime = (
v{this.state.version.Version}, {this.state.id.substr(-8)}, {this.state.peers} peers
-
Repo: LOTUS_STORAGE_PATH={this.props.node.Repo}
+
Repo: LOTUS_MINER_PATH={this.props.node.Repo}
{pledgeSector} {sealStaged}
@@ -147,7 +147,7 @@ class StorageNode extends React.Component { } return
diff --git a/lotuspond/front/src/StorageNodeInit.js b/lotuspond/front/src/StorageNodeInit.js index bd9d5390a..4ffe7c075 100644 --- a/lotuspond/front/src/StorageNodeInit.js +++ b/lotuspond/front/src/StorageNodeInit.js @@ -11,7 +11,7 @@ class StorageNodeInit extends React.Component { render() { return
diff --git a/lotuspond/main.go b/lotuspond/main.go index fee36d86a..1df35f4ba 100644 --- a/lotuspond/main.go +++ b/lotuspond/main.go @@ -45,9 +45,9 @@ var onCmd = &cli.Command{ "LOTUS_PATH=" + node.Repo, } } else { - cmd = exec.Command("./lotus-storage-miner") + cmd = exec.Command("./lotus-miner") cmd.Env = []string{ - "LOTUS_STORAGE_PATH=" + node.Repo, + "LOTUS_MINER_PATH=" + node.Repo, "LOTUS_PATH=" + node.FullNode, } } @@ -83,7 +83,7 @@ var shCmd = &cli.Command{ } } else { shcmd.Env = []string{ - "LOTUS_STORAGE_PATH=" + node.Repo, + "LOTUS_MINER_PATH=" + node.Repo, "LOTUS_PATH=" + node.FullNode, } } diff --git a/lotuspond/spawn.go b/lotuspond/spawn.go index ef0ebaeab..e28ac8753 100644 --- a/lotuspond/spawn.go +++ b/lotuspond/spawn.go @@ -176,10 +176,10 @@ func (api *api) SpawnStorage(fullNodeRepo string) (nodeInfo, error) { } id := atomic.AddInt32(&api.cmds, 1) - cmd := exec.Command("./lotus-storage-miner", initArgs...) + cmd := exec.Command("./lotus-miner", initArgs...) cmd.Stderr = io.MultiWriter(os.Stderr, errlogfile) cmd.Stdout = io.MultiWriter(os.Stdout, logfile) - cmd.Env = append(os.Environ(), "LOTUS_STORAGE_PATH="+dir, "LOTUS_PATH="+fullNodeRepo) + cmd.Env = append(os.Environ(), "LOTUS_MINER_PATH="+dir, "LOTUS_PATH="+fullNodeRepo) if err := cmd.Run(); err != nil { return nodeInfo{}, err } @@ -188,10 +188,10 @@ func (api *api) SpawnStorage(fullNodeRepo string) (nodeInfo, error) { mux := newWsMux() - cmd = exec.Command("./lotus-storage-miner", "run", "--api", fmt.Sprintf("%d", 2500+id), "--nosync") + cmd = exec.Command("./lotus-miner", "run", "--api", fmt.Sprintf("%d", 2500+id), "--nosync") cmd.Stderr = io.MultiWriter(os.Stderr, errlogfile, mux.errpw) cmd.Stdout = io.MultiWriter(os.Stdout, logfile, mux.outpw) - cmd.Env = append(os.Environ(), "LOTUS_STORAGE_PATH="+dir, "LOTUS_PATH="+fullNodeRepo) + cmd.Env = append(os.Environ(), "LOTUS_MINER_PATH="+dir, "LOTUS_PATH="+fullNodeRepo) if err := cmd.Start(); err != nil { return nodeInfo{}, err } @@ -248,7 +248,7 @@ func (api *api) RestartNode(id int32) (nodeInfo, error) { var cmd *exec.Cmd if nd.meta.Storage { - cmd = exec.Command("./lotus-storage-miner", "run", "--api", fmt.Sprintf("%d", 2500+id), "--nosync") + cmd = exec.Command("./lotus-miner", "run", "--api", fmt.Sprintf("%d", 2500+id), "--nosync") } else { cmd = exec.Command("./lotus", "daemon", "--api", fmt.Sprintf("%d", 2500+id)) } diff --git a/markets/storageadapter/client.go b/markets/storageadapter/client.go index 7ef6d0709..2bb762e28 100644 --- a/markets/storageadapter/client.go +++ b/markets/storageadapter/client.go @@ -138,7 +138,7 @@ func (c *ClientNodeAdapter) AddFunds(ctx context.Context, addr address.Address, From: addr, Value: amount, GasPrice: types.NewInt(0), - GasLimit: 1000000, + GasLimit: 200_000_000, Method: builtin.MethodsMarket.AddBalance, }) if err != nil { diff --git a/markets/storageadapter/provider.go b/markets/storageadapter/provider.go index 0b04757c5..9e1a101cc 100644 --- a/markets/storageadapter/provider.go +++ b/markets/storageadapter/provider.go @@ -78,7 +78,7 @@ func (n *ProviderNodeAdapter) PublishDeals(ctx context.Context, deal storagemark From: mi.Worker, Value: types.NewInt(0), GasPrice: types.NewInt(0), - GasLimit: 1000000, + GasLimit: 600_000_000, Method: builtin.MethodsMarket.PublishStorageDeals, Params: params, }) @@ -175,7 +175,7 @@ func (n *ProviderNodeAdapter) AddFunds(ctx context.Context, addr address.Address From: addr, Value: amount, GasPrice: types.NewInt(0), - GasLimit: 1000000, + GasLimit: 200_000_000, Method: builtin.MethodsMarket.AddBalance, }) if err != nil { diff --git a/miner/miner.go b/miner/miner.go index d81216be2..ba2a69d6e 100644 --- a/miner/miner.go +++ b/miner/miner.go @@ -9,7 +9,7 @@ import ( "sync" "time" - address "github.com/filecoin-project/go-address" + "github.com/filecoin-project/go-address" "github.com/filecoin-project/specs-actors/actors/abi" "github.com/filecoin-project/specs-actors/actors/abi/big" "github.com/filecoin-project/specs-actors/actors/builtin/power" @@ -46,7 +46,7 @@ func NewMiner(api api.FullNode, epp gen.WinningPoStProver, addr address.Address) waitFunc: func(ctx context.Context, baseTime uint64) (func(bool, error), error) { // Wait around for half the block time in case other parents come in deadline := baseTime + build.PropagationDelaySecs - time.Sleep(time.Until(time.Unix(int64(deadline), 0))) + build.Clock.Sleep(build.Clock.Until(time.Unix(int64(deadline), 0))) return func(bool, error) {}, nil }, @@ -107,7 +107,7 @@ func (m *Miner) Stop(ctx context.Context) error { func (m *Miner) niceSleep(d time.Duration) bool { select { - case <-time.After(d): + case <-build.Clock.After(d): return true case <-m.stop: return false @@ -170,14 +170,18 @@ func (m *Miner) mine(ctx context.Context) { if b != nil { btime := time.Unix(int64(b.Header.Timestamp), 0) - if time.Now().Before(btime) { - if !m.niceSleep(time.Until(btime)) { + now := build.Clock.Now() + switch { + case btime == now: + // block timestamp is perfectly aligned with time. + case btime.After(now): + if !m.niceSleep(build.Clock.Until(btime)) { log.Warnf("received interrupt while waiting to broadcast block, will shutdown after block is sent out") - time.Sleep(time.Until(btime)) + build.Clock.Sleep(build.Clock.Until(btime)) } - } else { - log.Warnw("mined block in the past", "block-time", btime, - "time", time.Now(), "duration", time.Since(btime)) + default: + log.Warnw("mined block in the past", + "block-time", btime, "time", build.Clock.Now(), "difference", build.Clock.Since(btime)) } // TODO: should do better 'anti slash' protection here @@ -201,7 +205,7 @@ func (m *Miner) mine(ctx context.Context) { nextRound := time.Unix(int64(base.TipSet.MinTimestamp()+build.BlockDelaySecs*uint64(base.NullRounds))+int64(build.PropagationDelaySecs), 0) select { - case <-time.After(time.Until(nextRound)): + case <-build.Clock.After(build.Clock.Until(nextRound)): case <-m.stop: stopping := m.stopping m.stop = nil @@ -271,7 +275,7 @@ func (m *Miner) hasPower(ctx context.Context, addr address.Address, ts *types.Ti // 1. func (m *Miner) mineOne(ctx context.Context, base *MiningBase) (*types.BlockMsg, error) { log.Debugw("attempting to mine a block", "tipset", types.LogCids(base.TipSet.Cids())) - start := time.Now() + start := build.Clock.Now() round := base.TipSet.Height() + base.NullRounds + 1 @@ -283,11 +287,11 @@ func (m *Miner) mineOne(ctx context.Context, base *MiningBase) (*types.BlockMsg, return nil, nil } - tMBI := time.Now() + tMBI := build.Clock.Now() beaconPrev := mbi.PrevBeaconEntry - tDrand := time.Now() + tDrand := build.Clock.Now() bvals := mbi.BeaconEntries hasPower, err := m.hasPower(ctx, m.address, base.TipSet) @@ -299,9 +303,9 @@ func (m *Miner) mineOne(ctx context.Context, base *MiningBase) (*types.BlockMsg, return nil, nil } - tPowercheck := time.Now() + tPowercheck := build.Clock.Now() - log.Infof("Time delta between now and our mining base: %ds (nulls: %d)", uint64(time.Now().Unix())-base.TipSet.MinTimestamp(), base.NullRounds) + log.Infof("Time delta between now and our mining base: %ds (nulls: %d)", uint64(build.Clock.Now().Unix())-base.TipSet.MinTimestamp(), base.NullRounds) rbase := beaconPrev if len(bvals) > 0 { @@ -322,7 +326,7 @@ func (m *Miner) mineOne(ctx context.Context, base *MiningBase) (*types.BlockMsg, return nil, nil } - tTicket := time.Now() + tTicket := build.Clock.Now() buf := new(bytes.Buffer) if err := m.address.MarshalCBOR(buf); err != nil { @@ -336,7 +340,7 @@ func (m *Miner) mineOne(ctx context.Context, base *MiningBase) (*types.BlockMsg, prand := abi.PoStRandomness(rand) - tSeed := time.Now() + tSeed := build.Clock.Now() postProof, err := m.epp.ComputeProof(ctx, mbi.Sectors, prand) if err != nil { @@ -349,7 +353,7 @@ func (m *Miner) mineOne(ctx context.Context, base *MiningBase) (*types.BlockMsg, return nil, xerrors.Errorf("failed to get pending messages: %w", err) } - tPending := time.Now() + tPending := build.Clock.Now() // TODO: winning post proof b, err := m.createBlock(base, m.address, ticket, winner, bvals, postProof, pending) @@ -357,7 +361,7 @@ func (m *Miner) mineOne(ctx context.Context, base *MiningBase) (*types.BlockMsg, return nil, xerrors.Errorf("failed to create block: %w", err) } - tCreateBlock := time.Now() + tCreateBlock := build.Clock.Now() dur := tCreateBlock.Sub(start) log.Infow("mined new block", "cid", b.Cid(), "height", b.Header.Height, "took", dur) if dur > time.Second*time.Duration(build.BlockDelaySecs) { @@ -502,7 +506,7 @@ func SelectMessages(ctx context.Context, al ActorLookup, ts *types.TipSet, msgs tooLowFundMsgs := 0 tooHighNonceMsgs := 0 - start := time.Now() + start := build.Clock.Now() vmValid := time.Duration(0) getbal := time.Duration(0) @@ -511,7 +515,7 @@ func SelectMessages(ctx context.Context, al ActorLookup, ts *types.TipSet, msgs }) for _, msg := range msgs { - vmstart := time.Now() + vmstart := build.Clock.Now() minGas := vm.PricelistByEpoch(ts.Height()).OnChainMessage(msg.ChainLength()) // TODO: really should be doing just msg.ChainLength() but the sync side of this code doesnt seem to have access to that if err := msg.VMMessage().ValidForBlockInclusion(minGas.Total()); err != nil { @@ -519,7 +523,7 @@ func SelectMessages(ctx context.Context, al ActorLookup, ts *types.TipSet, msgs continue } - vmValid += time.Since(vmstart) + vmValid += build.Clock.Since(vmstart) // TODO: this should be in some more general 'validate message' call if msg.Message.GasLimit > build.BlockGasLimit { @@ -534,7 +538,7 @@ func SelectMessages(ctx context.Context, al ActorLookup, ts *types.TipSet, msgs from := msg.Message.From - getBalStart := time.Now() + getBalStart := build.Clock.Now() if _, ok := inclNonces[from]; !ok { act, err := al(ctx, from, ts.Key()) if err != nil { @@ -545,7 +549,7 @@ func SelectMessages(ctx context.Context, al ActorLookup, ts *types.TipSet, msgs inclNonces[from] = act.Nonce inclBalances[from] = act.Balance } - getbal += time.Since(getBalStart) + getbal += build.Clock.Since(getBalStart) if inclBalances[from].LessThan(msg.Message.RequiredFunds()) { tooLowFundMsgs++ @@ -588,6 +592,14 @@ func SelectMessages(ctx context.Context, al ActorLookup, ts *types.TipSet, msgs gasLimitLeft := int64(build.BlockGasLimit) + orderedSenders := make([]address.Address, 0, len(outBySender)) + for k := range outBySender { + orderedSenders = append(orderedSenders, k) + } + sort.Slice(orderedSenders, func(i, j int) bool { + return bytes.Compare(orderedSenders[i].Bytes(), orderedSenders[j].Bytes()) == -1 + }) + out := make([]*types.SignedMessage, 0, build.BlockMessageLimit) { for { @@ -596,7 +608,11 @@ func SelectMessages(ctx context.Context, al ActorLookup, ts *types.TipSet, msgs var bestGasToReward float64 // TODO: This is O(n^2)-ish, could use something like container/heap to cache this math - for sender, meta := range outBySender { + for _, sender := range orderedSenders { + meta, ok := outBySender[sender] + if !ok { + continue + } for n := range meta.msgs { if meta.gasLimit[n] > gasLimitLeft { break @@ -648,7 +664,7 @@ func SelectMessages(ctx context.Context, al ActorLookup, ts *types.TipSet, msgs log.Warnf("%d messages in mempool had too high nonce", tooHighNonceMsgs) } - sm := time.Now() + sm := build.Clock.Now() if sm.Sub(start) > time.Second { log.Warnw("SelectMessages took a long time", "duration", sm.Sub(start), diff --git a/miner/miner_test.go b/miner/miner_test.go index 15cc41064..b600ff136 100644 --- a/miner/miner_test.go +++ b/miner/miner_test.go @@ -5,7 +5,9 @@ import ( "testing" "github.com/filecoin-project/go-address" + "github.com/filecoin-project/lotus/chain/types" + "github.com/stretchr/testify/assert" ) func mustIDAddr(i uint64) address.Address { @@ -25,11 +27,11 @@ func TestMessageFiltering(t *testing.T) { actors := map[address.Address]*types.Actor{ a1: { Nonce: 3, - Balance: types.NewInt(1200), + Balance: types.FromFil(1200), }, a2: { Nonce: 1, - Balance: types.NewInt(1000), + Balance: types.FromFil(1000), }, } @@ -42,40 +44,40 @@ func TestMessageFiltering(t *testing.T) { From: a1, To: a1, Nonce: 3, - Value: types.NewInt(500), - GasLimit: 50, + Value: types.FromFil(500), + GasLimit: 100_000_000, GasPrice: types.NewInt(1), }, { From: a1, To: a1, Nonce: 4, - Value: types.NewInt(500), - GasLimit: 50, + Value: types.FromFil(500), + GasLimit: 100_000_000, GasPrice: types.NewInt(1), }, { From: a2, To: a1, Nonce: 1, - Value: types.NewInt(800), - GasLimit: 100, + Value: types.FromFil(800), + GasLimit: 100_000_000, GasPrice: types.NewInt(1), }, { From: a2, To: a1, Nonce: 0, - Value: types.NewInt(800), - GasLimit: 100, + Value: types.FromFil(800), + GasLimit: 100_000_000, GasPrice: types.NewInt(1), }, { From: a2, To: a1, Nonce: 2, - Value: types.NewInt(150), - GasLimit: (100), + Value: types.FromFil(150), + GasLimit: 100, GasPrice: types.NewInt(1), }, } @@ -85,12 +87,10 @@ func TestMessageFiltering(t *testing.T) { t.Fatal(err) } - if len(outmsgs) != 3 { - t.Fatal("filtering didnt work as expected") - } + assert.Len(t, outmsgs, 3, "filtering didnt work as expected") - m1 := outmsgs[2].Message - if m1.From != msgs[2].From || m1.Nonce != msgs[2].Nonce { + was, expected := outmsgs[0].Message, msgs[2] + if was.From != expected.From || was.Nonce != expected.Nonce { t.Fatal("filtering bad") } } diff --git a/node/builder.go b/node/builder.go index 713d338fb..780497dba 100644 --- a/node/builder.go +++ b/node/builder.go @@ -108,7 +108,7 @@ const ( RegisterClientValidatorKey - // storage miner + // miner GetParamsKey HandleDealsKey HandleRetrievalKey @@ -274,7 +274,7 @@ func Online() Option { Override(new(*market.FundMgr), market.NewFundMgr), ), - // Storage miner + // miner ApplyIf(func(s *Settings) bool { return s.nodeType == repo.StorageMiner }, Override(new(api.Common), From(new(common.CommonAPI))), Override(new(sectorstorage.StorageAuth), modules.StorageAuth), @@ -326,6 +326,8 @@ func Online() Option { Override(new(dtypes.SetConsiderOfflineRetrievalDealsConfigFunc), modules.NewSetConsiderOfflineRetrievalDealsConfigFunc), Override(new(dtypes.SetSealingDelayFunc), modules.NewSetSealDelayFunc), Override(new(dtypes.GetSealingDelayFunc), modules.NewGetSealDelayFunc), + Override(new(dtypes.SetExpectedSealDurationFunc), modules.NewSetExpectedSealDurationFunc), + Override(new(dtypes.GetExpectedSealDurationFunc), modules.NewGetExpectedSealDurationFunc), ), ) } diff --git a/node/config/def.go b/node/config/def.go index 87286d3d2..a9caf1377 100644 --- a/node/config/def.go +++ b/node/config/def.go @@ -25,7 +25,7 @@ type FullNode struct { // // Common -// StorageMiner is a storage miner config +// StorageMiner is a miner config type StorageMiner struct { Common @@ -40,6 +40,7 @@ type DealmakingConfig struct { ConsiderOnlineRetrievalDeals bool ConsiderOfflineRetrievalDeals bool PieceCidBlocklist []cid.Cid + ExpectedSealDuration Duration } // API contains configs for API endpoint @@ -132,6 +133,8 @@ func DefaultStorageMiner() *StorageMiner { ConsiderOnlineRetrievalDeals: true, ConsiderOfflineRetrievalDeals: true, PieceCidBlocklist: []cid.Cid{}, + // TODO: It'd be nice to set this based on sector size + ExpectedSealDuration: Duration(time.Hour * 12), }, SealingDelay: Duration(time.Hour), diff --git a/node/hello/hello.go b/node/hello/hello.go index a2a5fbd4e..5f35faafc 100644 --- a/node/hello/hello.go +++ b/node/hello/hello.go @@ -15,6 +15,7 @@ import ( protocol "github.com/libp2p/go-libp2p-core/protocol" cborutil "github.com/filecoin-project/go-cbor-util" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain" "github.com/filecoin-project/lotus/chain/store" "github.com/filecoin-project/lotus/chain/types" @@ -67,7 +68,7 @@ func (hs *Service) HandleStream(s inet.Stream) { _ = s.Conn().Close() return } - arrived := time.Now() + arrived := build.Clock.Now() log.Debugw("genesis from hello", "tipset", hmsg.HeaviestTipSet, @@ -82,7 +83,7 @@ func (hs *Service) HandleStream(s inet.Stream) { go func() { defer s.Close() //nolint:errcheck - sent := time.Now() + sent := build.Clock.Now() msg := &LatencyMessage{ TArrial: arrived.UnixNano(), TSent: sent.UnixNano(), @@ -99,7 +100,7 @@ func (hs *Service) HandleStream(s inet.Stream) { if len(protos) == 0 { log.Warn("other peer hasnt completed libp2p identify, waiting a bit") // TODO: this better - time.Sleep(time.Millisecond * 300) + build.Clock.Sleep(time.Millisecond * 300) } ts, err := hs.syncer.FetchTipSet(context.Background(), s.Conn().RemotePeer(), types.NewTipSetKey(hmsg.HeaviestTipSet...)) @@ -146,7 +147,7 @@ func (hs *Service) SayHello(ctx context.Context, pid peer.ID) error { } log.Debug("Sending hello message: ", hts.Cids(), hts.Height(), gen.Cid()) - t0 := time.Now() + t0 := build.Clock.Now() if err := cborutil.WriteCborRPC(s, hmsg); err != nil { return err } @@ -155,13 +156,13 @@ func (hs *Service) SayHello(ctx context.Context, pid peer.ID) error { defer s.Close() //nolint:errcheck lmsg := &LatencyMessage{} - _ = s.SetReadDeadline(time.Now().Add(10 * time.Second)) + _ = s.SetReadDeadline(build.Clock.Now().Add(10 * time.Second)) err := cborutil.ReadCborRPC(s, lmsg) if err != nil { log.Infow("reading latency message", "error", err) } - t3 := time.Now() + t3 := build.Clock.Now() lat := t3.Sub(t0) // add to peer tracker if hs.pmgr != nil { diff --git a/node/impl/client/client.go b/node/impl/client/client.go index e7a0ba800..3eb3736bc 100644 --- a/node/impl/client/client.go +++ b/node/impl/client/client.go @@ -409,26 +409,8 @@ func (a *API) ClientRetrieve(ctx context.Context, order api.RetrievalOrder, ref retrievalResult <- xerrors.Errorf("Retrieval Proposal Rejected: %s", state.Message) case rm.DealStatusDealNotFound, - rm.DealStatusErrored, - rm.DealStatusFailed: + rm.DealStatusErrored: retrievalResult <- xerrors.Errorf("Retrieval Error: %s", state.Message) - case - rm.DealStatusAccepted, - rm.DealStatusAwaitingAcceptance, - rm.DealStatusBlocksComplete, - rm.DealStatusFinalizing, - rm.DealStatusFundsNeeded, - rm.DealStatusFundsNeededLastPayment, - rm.DealStatusNew, - rm.DealStatusOngoing, - rm.DealStatusPaymentChannelAddingFunds, - rm.DealStatusPaymentChannelAllocatingLane, - rm.DealStatusPaymentChannelCreating, - rm.DealStatusPaymentChannelReady, - rm.DealStatusVerified: - return - default: - retrievalResult <- xerrors.Errorf("Unhandled Retrieval Status: %+v", state.Status) } } }) diff --git a/node/impl/full/chain.go b/node/impl/full/chain.go index d5c8f385b..802e2a355 100644 --- a/node/impl/full/chain.go +++ b/node/impl/full/chain.go @@ -11,7 +11,6 @@ import ( "sync" "github.com/filecoin-project/go-amt-ipld/v2" - commcid "github.com/filecoin-project/go-fil-commcid" "github.com/filecoin-project/specs-actors/actors/abi" "github.com/filecoin-project/specs-actors/actors/crypto" "github.com/filecoin-project/specs-actors/actors/util/adt" @@ -206,7 +205,7 @@ func (a *ChainAPI) ChainStatObj(ctx context.Context, obj cid.Cid, base cid.Cid) var collect = true walker := func(ctx context.Context, c cid.Cid) ([]*ipld.Link, error) { - if c.Prefix().MhType == uint64(commcid.FC_SEALED_V1) || c.Prefix().MhType == uint64(commcid.FC_UNSEALED_V1) { + if c.Prefix().Codec == cid.FilCommitmentSealed || c.Prefix().Codec == cid.FilCommitmentUnsealed { return []*ipld.Link{}, nil } diff --git a/node/impl/full/mpool.go b/node/impl/full/mpool.go index 79e6d30be..d5b77b0bb 100644 --- a/node/impl/full/mpool.go +++ b/node/impl/full/mpool.go @@ -90,6 +90,12 @@ func (a *MpoolAPI) MpoolPushMessage(ctx context.Context, msg *types.Message) (*t if msg.Nonce != 0 { return nil, xerrors.Errorf("MpoolPushMessage expects message nonce to be 0, was %d", msg.Nonce) } + if msg.GasLimit == 0 { + msg.GasLimit = 100_000_000 // TODO: gas limit estimation + } + if types.BigCmp(msg.GasPrice, types.NewInt(0)) == 0 { + msg.GasPrice = types.NewInt(1) // TODO: gas price estimation + } return a.Mpool.PushWithNonce(ctx, msg.From, func(from address.Address, nonce uint64) (*types.SignedMessage, error) { msg.Nonce = nonce diff --git a/node/impl/full/multisig.go b/node/impl/full/multisig.go index 7d6d9e86c..7340ae0da 100644 --- a/node/impl/full/multisig.go +++ b/node/impl/full/multisig.go @@ -76,7 +76,7 @@ func (a *MsigAPI) MsigCreate(ctx context.Context, req uint64, addrs []address.Ad Method: builtin.MethodsInit.Exec, Params: enc, GasPrice: gp, - GasLimit: 1000000, + GasLimit: 100_000_000, Value: val, } @@ -123,7 +123,7 @@ func (a *MsigAPI) MsigPropose(ctx context.Context, msig address.Address, to addr Value: types.NewInt(0), Method: builtin.MethodsMultisig.Propose, Params: enc, - GasLimit: 100000, + GasLimit: 100_000_000, GasPrice: types.NewInt(1), } @@ -212,7 +212,7 @@ func (a *MsigAPI) msigApproveOrCancel(ctx context.Context, operation api.MsigPro Value: types.NewInt(0), Method: msigResponseMethod, Params: enc, - GasLimit: 100000, + GasLimit: 100_000_000, GasPrice: types.NewInt(1), } diff --git a/node/impl/full/state.go b/node/impl/full/state.go index c74573b91..f515adbf6 100644 --- a/node/impl/full/state.go +++ b/node/impl/full/state.go @@ -897,7 +897,7 @@ func (a *StateAPI) StateMinerInitialPledgeCollateral(ctx context.Context, maddr From: maddr, To: builtin.StorageMarketActorAddr, Method: builtin.MethodsMarket.VerifyDealsForActivation, - GasLimit: 100000000000, + GasLimit: 100_000_000, GasPrice: types.NewInt(0), Params: params, }, ts) @@ -969,7 +969,7 @@ func (a *StateAPI) StateVerifiedClientStatus(ctx context.Context, addr address.A return nil, err } - vh, err := hamt.LoadNode(ctx, cst, st.VerifiedClients) + vh, err := hamt.LoadNode(ctx, cst, st.VerifiedClients, hamt.UseTreeBitWidth(5)) if err != nil { return nil, err } diff --git a/node/impl/paych/paych.go b/node/impl/paych/paych.go index f0396f501..20778b9f2 100644 --- a/node/impl/paych/paych.go +++ b/node/impl/paych/paych.go @@ -127,7 +127,7 @@ func (a *PaychAPI) PaychClose(ctx context.Context, addr address.Address) (cid.Ci Method: builtin.MethodsPaych.Settle, Nonce: nonce, - GasLimit: 10000, + GasLimit: 100_000_000, GasPrice: types.NewInt(0), } @@ -242,7 +242,7 @@ func (a *PaychAPI) PaychVoucherSubmit(ctx context.Context, ch address.Address, s Nonce: nonce, Method: builtin.MethodsPaych.UpdateChannelState, Params: enc, - GasLimit: 100000, + GasLimit: 100_000_000, GasPrice: types.NewInt(0), } diff --git a/node/impl/storminer.go b/node/impl/storminer.go index 8fcd2d2b0..7289e50c1 100644 --- a/node/impl/storminer.go +++ b/node/impl/storminer.go @@ -56,6 +56,8 @@ type StorageMinerAPI struct { SetConsiderOfflineRetrievalDealsConfigFunc dtypes.SetConsiderOfflineRetrievalDealsConfigFunc SetSealingDelayFunc dtypes.SetSealingDelayFunc GetSealingDelayFunc dtypes.GetSealingDelayFunc + GetExpectedSealDurationFunc dtypes.GetExpectedSealDurationFunc + SetExpectedSealDurationFunc dtypes.SetExpectedSealDurationFunc } func (sm *StorageMinerAPI) ServeRemote(w http.ResponseWriter, r *http.Request) { @@ -192,6 +194,14 @@ func (sm *StorageMinerAPI) SectorGetSealDelay(ctx context.Context) (time.Duratio return sm.GetSealingDelayFunc() } +func (sm *StorageMinerAPI) SectorSetExpectedSealDuration(ctx context.Context, delay time.Duration) error { + return sm.SetExpectedSealDurationFunc(delay) +} + +func (sm *StorageMinerAPI) SectorGetExpectedSealDuration(ctx context.Context) (time.Duration, error) { + return sm.GetExpectedSealDurationFunc() +} + func (sm *StorageMinerAPI) SectorsUpdate(ctx context.Context, id abi.SectorNumber, state api.SectorState) error { return sm.Miner.ForceSectorState(ctx, id, sealing.SectorState(state)) } @@ -282,6 +292,14 @@ func (sm *StorageMinerAPI) DealsSetConsiderOfflineRetrievalDeals(ctx context.Con return sm.SetConsiderOfflineRetrievalDealsConfigFunc(b) } +func (sm *StorageMinerAPI) DealsGetExpectedSealDurationFunc(ctx context.Context) (time.Duration, error) { + return sm.GetExpectedSealDurationFunc() +} + +func (sm *StorageMinerAPI) DealsSetExpectedSealDurationFunc(ctx context.Context, d time.Duration) error { + return sm.SetExpectedSealDurationFunc(d) +} + func (sm *StorageMinerAPI) DealsImportData(ctx context.Context, deal cid.Cid, fname string) error { fi, err := os.Open(fname) if err != nil { diff --git a/node/modules/client.go b/node/modules/client.go index a7437f297..780aa91ee 100644 --- a/node/modules/client.go +++ b/node/modules/client.go @@ -2,9 +2,10 @@ package modules import ( "context" - "github.com/filecoin-project/lotus/lib/bufbstore" "time" + "github.com/filecoin-project/lotus/lib/bufbstore" + blockstore "github.com/ipfs/go-ipfs-blockstore" "github.com/libp2p/go-libp2p-core/host" "go.uber.org/fx" @@ -128,9 +129,9 @@ func StorageClient(lc fx.Lifecycle, h host.Host, ibs dtypes.ClientBlockstore, r } // RetrievalClient creates a new retrieval client attached to the client blockstore -func RetrievalClient(h host.Host, bs dtypes.ClientBlockstore, pmgr *paychmgr.Manager, payapi payapi.PaychAPI, resolver retrievalmarket.PeerResolver, ds dtypes.MetadataDS, chainapi full.ChainAPI) (retrievalmarket.RetrievalClient, error) { +func RetrievalClient(h host.Host, bs dtypes.ClientBlockstore, dt dtypes.ClientDataTransfer, pmgr *paychmgr.Manager, payapi payapi.PaychAPI, resolver retrievalmarket.PeerResolver, ds dtypes.MetadataDS, chainapi full.ChainAPI) (retrievalmarket.RetrievalClient, error) { adapter := retrievaladapter.NewRetrievalClientNode(pmgr, payapi, chainapi) network := rmnet.NewFromLibp2pHost(h) sc := storedcounter.New(ds, datastore.NewKey("/retr")) - return retrievalimpl.NewClient(network, bs, adapter, resolver, namespace.Wrap(ds, datastore.NewKey("/retrievals/client")), sc) + return retrievalimpl.NewClient(network, bs, dt, adapter, resolver, namespace.Wrap(ds, datastore.NewKey("/retrievals/client")), sc) } diff --git a/node/modules/dtypes/miner.go b/node/modules/dtypes/miner.go index d64ff283e..c653ec6eb 100644 --- a/node/modules/dtypes/miner.go +++ b/node/modules/dtypes/miner.go @@ -27,12 +27,12 @@ type ConsiderOnlineRetrievalDealsConfigFunc func() (bool, error) type SetConsiderOnlineRetrievalDealsConfigFunc func(bool) error // StorageDealPieceCidBlocklistConfigFunc is a function which reads from miner -// config to obtain a list of CIDs for which the storage miner will not accept +// config to obtain a list of CIDs for which the miner will not accept // storage proposals. type StorageDealPieceCidBlocklistConfigFunc func() ([]cid.Cid, error) // SetStorageDealPieceCidBlocklistConfigFunc is a function which is used to set a -// list of CIDs for which the storage miner will reject deal proposals. +// list of CIDs for which the miner will reject deal proposals. type SetStorageDealPieceCidBlocklistConfigFunc func([]cid.Cid) error // ConsiderOfflineStorageDealsConfigFunc is a function which reads from miner @@ -56,3 +56,11 @@ type SetSealingDelayFunc func(time.Duration) error // GetSealingDelay returns how long a sector waits for more deals before sealing begins. type GetSealingDelayFunc func() (time.Duration, error) + +// SetExpectedSealDurationFunc is a function which is used to set how long sealing is expected to take. +// Deals that would need to start earlier than this duration will be rejected. +type SetExpectedSealDurationFunc func(time.Duration) error + +// GetExpectedSealDurationFunc is a function which reads from miner +// too determine how long sealing is expected to take +type GetExpectedSealDurationFunc func() (time.Duration, error) diff --git a/node/modules/dtypes/shutdown.go b/node/modules/dtypes/shutdown.go index 6497b0938..d87c2129a 100644 --- a/node/modules/dtypes/shutdown.go +++ b/node/modules/dtypes/shutdown.go @@ -1,5 +1,5 @@ package dtypes // ShutdownChan is a channel to which you send a value if you intend to shut -// down the daemon (or storage miner), including the node and RPC server. +// down the daemon (or miner), including the node and RPC server. type ShutdownChan chan struct{} diff --git a/node/modules/storageminer.go b/node/modules/storageminer.go index 4f1fe6e44..3ae76fbf4 100644 --- a/node/modules/storageminer.go +++ b/node/modules/storageminer.go @@ -335,7 +335,19 @@ func NewStorageAsk(ctx helpers.MetricsCtx, fapi lapi.FullNode, ds dtypes.Metadat return storedAsk, nil } -func StorageProvider(minerAddress dtypes.MinerAddress, ffiConfig *ffiwrapper.Config, storedAsk *storedask.StoredAsk, h host.Host, ds dtypes.MetadataDS, ibs dtypes.StagingBlockstore, r repo.LockedRepo, pieceStore dtypes.ProviderPieceStore, dataTransfer dtypes.ProviderDataTransfer, spn storagemarket.StorageProviderNode, onlineOk dtypes.ConsiderOnlineStorageDealsConfigFunc, offlineOk dtypes.ConsiderOfflineStorageDealsConfigFunc, blocklistFunc dtypes.StorageDealPieceCidBlocklistConfigFunc) (storagemarket.StorageProvider, error) { +func StorageProvider(minerAddress dtypes.MinerAddress, + ffiConfig *ffiwrapper.Config, + storedAsk *storedask.StoredAsk, + h host.Host, ds dtypes.MetadataDS, + ibs dtypes.StagingBlockstore, + r repo.LockedRepo, + pieceStore dtypes.ProviderPieceStore, + dataTransfer dtypes.ProviderDataTransfer, + spn storagemarket.StorageProviderNode, + onlineOk dtypes.ConsiderOnlineStorageDealsConfigFunc, + offlineOk dtypes.ConsiderOfflineStorageDealsConfigFunc, + blocklistFunc dtypes.StorageDealPieceCidBlocklistConfigFunc, + expectedSealTimeFunc dtypes.GetExpectedSealDurationFunc) (storagemarket.StorageProvider, error) { net := smnet.NewFromLibp2pHost(h) store, err := piecefilestore.NewLocalFileStore(piecefilestore.OsPath(r.Path())) if err != nil { @@ -375,6 +387,22 @@ func StorageProvider(minerAddress dtypes.MinerAddress, ffiConfig *ffiwrapper.Con } } + sealDuration, err := expectedSealTimeFunc() + if err != nil { + return false, "miner error", err + } + + sealEpochs := sealDuration / (time.Duration(build.BlockDelaySecs) * time.Second) + _, ht, err := spn.GetChainHead(ctx) + if err != nil { + return false, "failed to get chain head", err + } + earliest := abi.ChainEpoch(sealEpochs) + ht + if deal.Proposal.StartEpoch < earliest { + log.Warnf("proposed deal would start before sealing can be completed; rejecting storage deal proposal from client: %s", deal.Proposal.PieceCID, deal.Client.String()) + return false, fmt.Sprintf("cannot seal a sector before %s", deal.Proposal.StartEpoch), nil + } + return true, "", nil }) @@ -387,7 +415,7 @@ func StorageProvider(minerAddress dtypes.MinerAddress, ffiConfig *ffiwrapper.Con } // RetrievalProvider creates a new retrieval provider attached to the provider blockstore -func RetrievalProvider(h host.Host, miner *storage.Miner, sealer sectorstorage.SectorManager, full lapi.FullNode, ds dtypes.MetadataDS, pieceStore dtypes.ProviderPieceStore, ibs dtypes.StagingBlockstore, onlineOk dtypes.ConsiderOnlineRetrievalDealsConfigFunc, offlineOk dtypes.ConsiderOfflineRetrievalDealsConfigFunc) (retrievalmarket.RetrievalProvider, error) { +func RetrievalProvider(h host.Host, miner *storage.Miner, sealer sectorstorage.SectorManager, full lapi.FullNode, ds dtypes.MetadataDS, pieceStore dtypes.ProviderPieceStore, ibs dtypes.StagingBlockstore, dt dtypes.ProviderDataTransfer, onlineOk dtypes.ConsiderOnlineRetrievalDealsConfigFunc, offlineOk dtypes.ConsiderOfflineRetrievalDealsConfigFunc) (retrievalmarket.RetrievalProvider, error) { adapter := retrievaladapter.NewRetrievalProviderNode(miner, sealer, full) maddr, err := minerAddrFromDS(ds) @@ -420,7 +448,7 @@ func RetrievalProvider(h host.Host, miner *storage.Miner, sealer sectorstorage.S return true, "", nil }) - return retrievalimpl.NewProvider(maddr, adapter, netwk, pieceStore, ibs, namespace.Wrap(ds, datastore.NewKey("/retrievals/provider")), opt) + return retrievalimpl.NewProvider(maddr, adapter, netwk, pieceStore, ibs, dt, namespace.Wrap(ds, datastore.NewKey("/retrievals/provider")), opt) } func SectorStorage(mctx helpers.MetricsCtx, lc fx.Lifecycle, ls stores.LocalStorage, si stores.SectorIndex, cfg *ffiwrapper.Config, sc sectorstorage.SealerConfig, urls sectorstorage.URLs, sa sectorstorage.StorageAuth) (*sectorstorage.Manager, error) { @@ -563,6 +591,24 @@ func NewGetSealDelayFunc(r repo.LockedRepo) (dtypes.GetSealingDelayFunc, error) }, nil } +func NewSetExpectedSealDurationFunc(r repo.LockedRepo) (dtypes.SetExpectedSealDurationFunc, error) { + return func(delay time.Duration) (err error) { + err = mutateCfg(r, func(cfg *config.StorageMiner) { + cfg.Dealmaking.ExpectedSealDuration = config.Duration(delay) + }) + return + }, nil +} + +func NewGetExpectedSealDurationFunc(r repo.LockedRepo) (dtypes.GetExpectedSealDurationFunc, error) { + return func() (out time.Duration, err error) { + err = readCfg(r, func(cfg *config.StorageMiner) { + out = time.Duration(cfg.Dealmaking.ExpectedSealDuration) + }) + return + }, nil +} + func readCfg(r repo.LockedRepo, accessor func(*config.StorageMiner)) error { raw, err := r.Config() if err != nil { @@ -585,7 +631,7 @@ func mutateCfg(r repo.LockedRepo, mutator func(*config.StorageMiner)) error { setConfigErr := r.SetConfig(func(raw interface{}) { cfg, ok := raw.(*config.StorageMiner) if !ok { - typeErr = errors.New("expected storage miner config") + typeErr = errors.New("expected miner config") return } diff --git a/node/modules/testing/genesis.go b/node/modules/testing/genesis.go index 930c11fc8..41587ed72 100644 --- a/node/modules/testing/genesis.go +++ b/node/modules/testing/genesis.go @@ -7,7 +7,6 @@ import ( "io" "io/ioutil" "os" - "time" "github.com/ipfs/go-blockservice" "github.com/ipfs/go-cid" @@ -20,6 +19,7 @@ import ( "github.com/filecoin-project/specs-actors/actors/runtime" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/gen" genesis2 "github.com/filecoin-project/lotus/chain/gen/genesis" "github.com/filecoin-project/lotus/chain/types" @@ -71,7 +71,7 @@ func MakeGenesis(outFile, genesisTemplate string) func(bs dtypes.ChainBlockstore } if template.Timestamp == 0 { - template.Timestamp = uint64(time.Now().Unix()) + template.Timestamp = uint64(build.Clock.Now().Unix()) } b, err := genesis2.MakeGenesisBlock(context.TODO(), bs, syscalls, template) diff --git a/node/node_test.go b/node/node_test.go index 64d59fc50..e03d9ed4f 100644 --- a/node/node_test.go +++ b/node/node_test.go @@ -107,7 +107,7 @@ func testStorageNode(ctx context.Context, t *testing.T, waddr address.Address, a Params: enc, Value: types.NewInt(0), GasPrice: types.NewInt(0), - GasLimit: 1000000, + GasLimit: 100_000_000, } _, err = tnd.MpoolPushMessage(ctx, msg) diff --git a/paychmgr/simple.go b/paychmgr/simple.go index 4d275a1a7..ddc49f864 100644 --- a/paychmgr/simple.go +++ b/paychmgr/simple.go @@ -37,7 +37,7 @@ func (pm *Manager) createPaych(ctx context.Context, from, to address.Address, am Value: amt, Method: builtin.MethodsInit.Exec, Params: enc, - GasLimit: 1000000, + GasLimit: 100_000_000, GasPrice: types.NewInt(0), } @@ -92,7 +92,7 @@ func (pm *Manager) addFunds(ctx context.Context, ch address.Address, from addres From: from, Value: amt, Method: 0, - GasLimit: 1000000, + GasLimit: 100_000_000, GasPrice: types.NewInt(0), } diff --git a/scripts/bash-completion/lotus-storage-miner b/scripts/bash-completion/lotus-miner similarity index 83% rename from scripts/bash-completion/lotus-storage-miner rename to scripts/bash-completion/lotus-miner index 10ee5b77f..df5cc01cc 100644 --- a/scripts/bash-completion/lotus-storage-miner +++ b/scripts/bash-completion/lotus-miner @@ -7,4 +7,4 @@ _cli_bash_autocomplete() { COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) ); return 0; }; -complete -F _cli_bash_autocomplete lotus-storage-miner \ No newline at end of file +complete -F _cli_bash_autocomplete lotus-miner \ No newline at end of file diff --git a/scripts/build-bundle.sh b/scripts/build-bundle.sh index 16cab49d1..8e4d608d0 100755 --- a/scripts/build-bundle.sh +++ b/scripts/build-bundle.sh @@ -20,8 +20,8 @@ pushd bundle BINARIES=( "lotus" - "lotus-storage-miner" - "lotus-seal-worker" + "lotus-miner" + "lotus-worker" ) export IPFS_PATH=`mktemp -d` diff --git a/scripts/deploy-bootstrapper.sh b/scripts/deploy-bootstrapper.sh index 98e2cd798..3ca0d51a2 100755 --- a/scripts/deploy-bootstrapper.sh +++ b/scripts/deploy-bootstrapper.sh @@ -10,15 +10,15 @@ log "> Deploying bootstrap node $host" log "Stopping lotus daemon" ssh "$host" 'systemctl stop lotus-daemon' & -ssh "$host" 'systemctl stop lotus-storage-miner' & +ssh "$host" 'systemctl stop lotus-miner' & wait ssh "$host" 'rm -rf .lotus' & -ssh "$host" 'rm -rf .lotusstorage' & +ssh "$host" 'rm -rf .lotusminer' & scp -C lotus "${host}":/usr/local/bin/lotus & -scp -C lotus-storage-miner "${host}":/usr/local/bin/lotus-storage-miner & +scp -C lotus-miner "${host}":/usr/local/bin/lotus-miner & wait diff --git a/scripts/deploy-miner.sh b/scripts/deploy-miner.sh index b1603aca6..5ce5069e4 100755 --- a/scripts/deploy-miner.sh +++ b/scripts/deploy-miner.sh @@ -2,7 +2,7 @@ HOST=$1 -ssh "$HOST" '[ -e ~/.lotusstorage/token ]' && exit 0 +ssh "$HOST" '[ -e ~/.lotusminer/token ]' && exit 0 ssh "$HOST" 'lotus wallet new bls > addr' ssh "$HOST" 'curl http://147.75.80.29:777/sendcoll?address=$(cat addr)' & @@ -14,5 +14,5 @@ echo "SYNC WAIT" sleep 30 ssh "$HOST" 'lotus sync wait' -ssh "$HOST" 'lotus-storage-miner init --owner=$(cat addr)' -ssh "$HOST" 'systemctl start lotus-storage-miner' & +ssh "$HOST" 'lotus-miner init --owner=$(cat addr)' +ssh "$HOST" 'systemctl start lotus-miner' & diff --git a/scripts/deploy-node.sh b/scripts/deploy-node.sh index 57856f945..fa6efa4d9 100755 --- a/scripts/deploy-node.sh +++ b/scripts/deploy-node.sh @@ -11,7 +11,7 @@ HOST=$1 FILES_TO_SEND=( ./lotus - ./lotus-storage-miner + ./lotus-miner scripts/lotus-daemon.service scripts/louts-miner.service ) @@ -21,14 +21,14 @@ rsync -P "${FILES_TO_SEND[@]}" "$HOST:~/lotus-stage/" ssh "$HOST" 'bash -s' << 'EOF' set -euo pipefail -systemctl stop lotus-storage-miner +systemctl stop lotus-miner systemctl stop lotus-daemon -mkdir -p .lotus .lotusstorage +mkdir -p .lotus .lotusminer cd "$HOME/lotus-stage/" -cp -f lotus lotus-storage-miner /usr/local/bin +cp -f lotus lotus-miner /usr/local/bin cp -f lotus-daemon.service /etc/systemd/system/lotus-daemon.service -cp -f lotus-miner.service /etc/systemd/system/lotus-storage-miner.service +cp -f lotus-miner.service /etc/systemd/system/lotus-miner.service systemctl daemon-reload systemctl start lotus-daemon diff --git a/scripts/dev/drop-local-repos b/scripts/dev/drop-local-repos index 939030bad..a0e7a5512 100755 --- a/scripts/dev/drop-local-repos +++ b/scripts/dev/drop-local-repos @@ -2,4 +2,4 @@ set -o xtrace -rm -rf ~/.lotus ~/.lotusstorage/ ~/.genesis-sectors ~/.lotusworker +rm -rf ~/.lotus ~/.lotusminer/ ~/.genesis-sectors ~/.lotusworker diff --git a/scripts/dev/sminer-init b/scripts/dev/sminer-init index 2f4a3f7af..767921511 100755 --- a/scripts/dev/sminer-init +++ b/scripts/dev/sminer-init @@ -7,4 +7,4 @@ export TRUST_PARAMS=1 tag=${TAG:-debug} go run -tags=$tag ./cmd/lotus wallet import ~/.genesis-sectors/pre-seal-t01000.key -go run -tags=$tag ./cmd/lotus-storage-miner init --actor=t01000 --genesis-miner --pre-sealed-sectors=~/.genesis-sectors --pre-sealed-metadata=~/.genesis-sectors/pre-seal-t01000.json +go run -tags=$tag ./cmd/lotus-miner init --actor=t01000 --genesis-miner --pre-sealed-sectors=~/.genesis-sectors --pre-sealed-metadata=~/.genesis-sectors/pre-seal-t01000.json diff --git a/scripts/devnet.bash b/scripts/devnet.bash index 4fe81eea4..8ffddaea4 100755 --- a/scripts/devnet.bash +++ b/scripts/devnet.bash @@ -42,8 +42,8 @@ SCRIPTDIR="\$( cd "\$( dirname "\${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" pushd \$SCRIPTDIR/../build pwd -env RUSTFLAGS="-C target-cpu=native -g" FFI_BUILD_FROM_SOURCE=1 make clean deps lotus lotus-storage-miner lotus-shed -cp lotus lotus-storage-miner lotus-shed ../bin/ +env RUSTFLAGS="-C target-cpu=native -g" FFI_BUILD_FROM_SOURCE=1 make clean deps lotus lotus-miner lotus-shed +cp lotus lotus-miner lotus-shed ../bin/ popd EOF @@ -51,13 +51,13 @@ EOF cat > "${BASEDIR}/scripts/env.fish" < "${BASEDIR}/scripts/env.bash" < "${BASEDIR}/scripts/create_miner.bash" < "${BASEDIR}/scripts/create_miner.bash" < "${BASEDIR}/scripts/pledge_sectors.bash" < "${BASEDIR}/scripts/pledge_sectors.bash" < ${PLEDGE_COUNT} )); then + if (( \$(lotus-miner sectors list | wc -l) > ${PLEDGE_COUNT} )); then break fi while true; do - state=\$(lotus-storage-miner sectors list | tail -n1 | awk '{print \$2}') + state=\$(lotus-miner sectors list | tail -n1 | awk '{print \$2}') if [ -z "\$state" ]; then break @@ -102,15 +102,15 @@ while true; do PreCommit1 | PreCommit2 | Packing | Unsealed | PreCommitting | Committing | CommitWait | FinalizeSector ) sleep 30 ;; WaitSeed | Proving ) break ;; * ) echo "Unknown Sector State: \$state" - lotus-storage-miner sectors status --log \$current + lotus-miner sectors status --log \$current break ;; esac done - lotus-storage-miner sectors pledge + lotus-miner sectors pledge while [ "\$current" == "\$sector" ]; do - sector=\$(lotus-storage-miner sectors list | tail -n1 | awk '{print \$1}' | tr -d ':') + sector=\$(lotus-miner sectors list | tail -n1 | awk '{print \$1}' | tr -d ':') sleep 5 done @@ -127,13 +127,13 @@ while true; do echo echo - echo Storage Miner Info - lotus-storage-miner info + echo Miner Info + lotus-miner info echo echo echo Sector List - lotus-storage-miner sectors list | tail -n4 + lotus-miner sectors list | tail -n4 sleep 25 @@ -151,7 +151,7 @@ if [ "$BUILD" == "yes" ]; then bash "${BASEDIR}/scripts/build.bash" else cp ./lotus ${BASEDIR}/bin/ - cp ./lotus-storage-miner ${BASEDIR}/bin/ + cp ./lotus-miner ${BASEDIR}/bin/ cp ./lotus-seed ${BASEDIR}/bin/ cp ./lotus-shed ${BASEDIR}/bin/ fi @@ -186,7 +186,7 @@ export LOTUS_PATH="${BASEDIR}/.lotus" ${BASEDIR}/bin/lotus wait-api tmux send-keys -t $session:$wminer "${BASEDIR}/scripts/create_miner.bash" C-m -tmux send-keys -t $session:$wminer "lotus-storage-miner run --api 48020 --nosync 2>&1 | tee -a ${BASEDIR}/miner.log" C-m +tmux send-keys -t $session:$wminer "lotus-miner run --api 48020 --nosync 2>&1 | tee -a ${BASEDIR}/miner.log" C-m tmux send-keys -t $session:$wcli "${BASEDIR}/scripts/monitor.bash" C-m tmux send-keys -t $session:$wpleding "${BASEDIR}/scripts/pledge_sectors.bash" C-m diff --git a/scripts/filebeat.yml b/scripts/filebeat.yml index 38c9adbc7..e33ca0e87 100644 --- a/scripts/filebeat.yml +++ b/scripts/filebeat.yml @@ -4,7 +4,7 @@ filebeat.inputs: - type: log paths: - - /root/.lotusstorage/logs + - /root/.lotusminer/logs fields: logzio_codec: json token: diff --git a/scripts/init-network.sh b/scripts/init-network.sh index 3ca243c15..10693bb0e 100755 --- a/scripts/init-network.sh +++ b/scripts/init-network.sh @@ -86,12 +86,12 @@ mdt0111=$(mktemp -d) mdt0222=$(mktemp -d) mdt0333=$(mktemp -d) -env LOTUS_PATH="${ldt0111}" LOTUS_STORAGE_PATH="${mdt0111}" ./lotus-storage-miner init --genesis-miner --actor=t0111 --pre-sealed-sectors="${sdt0111}" --pre-sealed-metadata="${sdt0111}/pre-seal-t0111.json" --nosync=true --sector-size="${SECTOR_SIZE}" || true -env LOTUS_PATH="${ldt0111}" LOTUS_STORAGE_PATH="${mdt0111}" ./lotus-storage-miner run --nosync & +env LOTUS_PATH="${ldt0111}" LOTUS_MINER_PATH="${mdt0111}" ./lotus-miner init --genesis-miner --actor=t0111 --pre-sealed-sectors="${sdt0111}" --pre-sealed-metadata="${sdt0111}/pre-seal-t0111.json" --nosync=true --sector-size="${SECTOR_SIZE}" || true +env LOTUS_PATH="${ldt0111}" LOTUS_MINER_PATH="${mdt0111}" ./lotus-miner run --nosync & mpid=$! -env LOTUS_PATH="${ldt0222}" LOTUS_STORAGE_PATH="${mdt0222}" ./lotus-storage-miner init --actor=t0222 --pre-sealed-sectors="${sdt0222}" --pre-sealed-metadata="${sdt0222}/pre-seal-t0222.json" --nosync=true --sector-size="${SECTOR_SIZE}" || true -env LOTUS_PATH="${ldt0333}" LOTUS_STORAGE_PATH="${mdt0333}" ./lotus-storage-miner init --actor=t0333 --pre-sealed-sectors="${sdt0333}" --pre-sealed-metadata="${sdt0333}/pre-seal-t0333.json" --nosync=true --sector-size="${SECTOR_SIZE}" || true +env LOTUS_PATH="${ldt0222}" LOTUS_MINER_PATH="${mdt0222}" ./lotus-miner init --actor=t0222 --pre-sealed-sectors="${sdt0222}" --pre-sealed-metadata="${sdt0222}/pre-seal-t0222.json" --nosync=true --sector-size="${SECTOR_SIZE}" || true +env LOTUS_PATH="${ldt0333}" LOTUS_MINER_PATH="${mdt0333}" ./lotus-miner init --actor=t0333 --pre-sealed-sectors="${sdt0333}" --pre-sealed-metadata="${sdt0333}/pre-seal-t0333.json" --nosync=true --sector-size="${SECTOR_SIZE}" || true kill $mpid wait $mpid diff --git a/scripts/chainwatch.service b/scripts/lotus-chainwatch.service similarity index 87% rename from scripts/chainwatch.service rename to scripts/lotus-chainwatch.service index 74afee0e9..e121cb1d1 100644 --- a/scripts/chainwatch.service +++ b/scripts/lotus-chainwatch.service @@ -9,7 +9,7 @@ Environment=GOLOG_LOG_FMT="json" Environment=LOTUS_DB="" Environment=LOTUS_PATH="%h/.lotus" EnvironmentFile=-/etc/lotus/chainwatch.env -ExecStart=/usr/local/bin/chainwatch run +ExecStart=/usr/local/bin/lotus-chainwatch run [Install] WantedBy=multi-user.target diff --git a/scripts/lotus-miner.service b/scripts/lotus-miner.service index 3a460450f..5490ec077 100644 --- a/scripts/lotus-miner.service +++ b/scripts/lotus-miner.service @@ -1,11 +1,11 @@ [Unit] -Description=Lotus Storage Miner +Description=Lotus Miner After=network.target After=lotus-daemon.service Requires=lotus-daemon.service [Service] -ExecStart=/usr/local/bin/lotus-storage-miner run +ExecStart=/usr/local/bin/lotus-miner run Environment=GOLOG_FILE="/var/log/lotus/miner.log" Environment=GOLOG_LOG_FMT="json" diff --git a/scripts/miner-mon.sh b/scripts/miner-mon.sh index cf78660a7..8b6cc75c1 100755 --- a/scripts/miner-mon.sh +++ b/scripts/miner-mon.sh @@ -4,20 +4,20 @@ SESSION=$(cat /proc/sys/kernel/random/uuid) tmux -2 new-session -d -s $SESSION -tmux new-window -t $SESSION:1 -n 'Storage Miner' +tmux new-window -t $SESSION:1 -n 'Miner' tmux split-window -h tmux select-pane -t 0 -tmux send-keys "watch -n1 './lotus-storage-miner info'" C-m +tmux send-keys "watch -n1 './lotus-miner info'" C-m tmux split-window -v tmux select-pane -t 1 -tmux send-keys "watch -n1 './lotus-storage-miner workers list'" C-m +tmux send-keys "watch -n1 './lotus-miner workers list'" C-m tmux select-pane -t 2 -tmux send-keys "watch -n1 './lotus-storage-miner storage list'" C-m +tmux send-keys "watch -n1 './lotus-miner storage list'" C-m tmux -2 attach-session -t $SESSION diff --git a/scripts/quick-network-join.bash b/scripts/quick-network-join.bash index 33e0069b2..c1ab1aa28 100755 --- a/scripts/quick-network-join.bash +++ b/scripts/quick-network-join.bash @@ -25,8 +25,8 @@ SCRIPTDIR="\$( cd "\$( dirname "\${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" pushd \$SCRIPTDIR/../build pwd -env RUSTFLAGS="-C target-cpu=native -g" FFI_BUILD_FROM_SOURCE=1 make clean deps lotus lotus-storage-miner lotus-shed -cp lotus lotus-storage-miner lotus-shed ../bin/ +env RUSTFLAGS="-C target-cpu=native -g" FFI_BUILD_FROM_SOURCE=1 make clean deps lotus lotus-miner lotus-shed +cp lotus lotus-miner lotus-shed ../bin/ popd EOF @@ -34,13 +34,13 @@ EOF cat > "${BASEDIR}/scripts/env.fish" < "${BASEDIR}/scripts/env.bash" < "${BASEDIR}/scripts/create_miner.bash" < "${BASEDIR}/scripts/pledge_sectors.bash" < "${BASEDIR}/scripts/pledge_sectors.bash" < ${PLEDGE_COUNT} )); then + if (( \$(lotus-miner sectors list | wc -l) > ${PLEDGE_COUNT} )); then break fi while true; do - state=\$(lotus-storage-miner sectors list | tail -n1 | awk '{print \$2}') + state=\$(lotus-miner sectors list | tail -n1 | awk '{print \$2}') if [ -z "\$state" ]; then break @@ -97,15 +97,15 @@ while true; do PreCommit1 | PreCommit2 | Packing | Unsealed | PreCommitting | Committing | CommitWait | FinalizeSector ) sleep 30 ;; WaitSeed | Proving ) break ;; * ) echo "Unknown Sector State: \$state" - lotus-storage-miner sectors status --log \$current + lotus-miner sectors status --log \$current break ;; esac done - lotus-storage-miner sectors pledge + lotus-miner sectors pledge while [ "\$current" == "\$sector" ]; do - sector=\$(lotus-storage-miner sectors list | tail -n1 | awk '{print \$1}' | tr -d ':') + sector=\$(lotus-miner sectors list | tail -n1 | awk '{print \$1}' | tr -d ':') sleep 5 done @@ -122,13 +122,13 @@ while true; do echo echo - echo Storage Miner Info - lotus-storage-miner info + echo Miner Info + lotus-miner info echo echo echo Sector List - lotus-storage-miner sectors list | tail -n4 + lotus-miner sectors list | tail -n4 sleep 25 @@ -170,7 +170,7 @@ tmux send-keys -t $session:$wdaemon "lotus daemon --api 48010 daemon 2>&1 | tee sleep 30 tmux send-keys -t $session:$wminer "${BASEDIR}/scripts/create_miner.bash" C-m -tmux send-keys -t $session:$wminer "lotus-storage-miner run --api 48020 2>&1 | tee -a ${BASEDIR}/miner.log" C-m +tmux send-keys -t $session:$wminer "lotus-miner run --api 48020 2>&1 | tee -a ${BASEDIR}/miner.log" C-m tmux send-keys -t $session:$wcli "${BASEDIR}/scripts/monitor.bash" C-m tmux send-keys -t $session:$wpleding "${BASEDIR}/scripts/pledge_sectors.bash" C-m diff --git a/scripts/setup-host.sh b/scripts/setup-host.sh index bda0a2c98..fe36be8fa 100755 --- a/scripts/setup-host.sh +++ b/scripts/setup-host.sh @@ -3,4 +3,4 @@ HOST=$1 scp scripts/lotus-daemon.service "${HOST}:/etc/systemd/system/lotus-daemon.service" -scp scripts/lotus-miner.service "${HOST}:/etc/systemd/system/lotus-storage-miner.service" +scp scripts/lotus-miner.service "${HOST}:/etc/systemd/system/lotus-miner.service" diff --git a/scripts/zsh-completion/lotus-storage-miner b/scripts/zsh-completion/lotus-miner similarity index 86% rename from scripts/zsh-completion/lotus-storage-miner rename to scripts/zsh-completion/lotus-miner index 1ff14be3a..3e23749e6 100644 --- a/scripts/zsh-completion/lotus-storage-miner +++ b/scripts/zsh-completion/lotus-miner @@ -9,4 +9,4 @@ _cli_bash_autocomplete() { COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) ); return 0; }; -complete -F _cli_bash_autocomplete lotus-storage-miner \ No newline at end of file +complete -F _cli_bash_autocomplete lotus-miner \ No newline at end of file diff --git a/storage/adapter_storage_miner.go b/storage/adapter_storage_miner.go index 4b059381e..aa8a93274 100644 --- a/storage/adapter_storage_miner.go +++ b/storage/adapter_storage_miner.go @@ -117,7 +117,7 @@ func (s SealingAPIAdapter) StateComputeDataCommitment(ctx context.Context, maddr From: maddr, Value: types.NewInt(0), GasPrice: types.NewInt(0), - GasLimit: 9999999999, + GasLimit: 100_000_000, Method: builtin.MethodsMarket.ComputeDataCommitment, Params: ccparams, } diff --git a/storage/miner.go b/storage/miner.go index a863002ee..c4a3cccc3 100644 --- a/storage/miner.go +++ b/storage/miner.go @@ -169,7 +169,7 @@ func NewWinningPoStProver(api api.FullNode, prover storage.Prover, verifier ffiw var _ gen.WinningPoStProver = (*StorageWpp)(nil) func (wpp *StorageWpp) GenerateCandidates(ctx context.Context, randomness abi.PoStRandomness, eligibleSectorCount uint64) ([]uint64, error) { - start := time.Now() + start := build.Clock.Now() cds, err := wpp.verifier.GenerateWinningPoStSectorChallenge(ctx, wpp.winnRpt, wpp.miner, randomness, eligibleSectorCount) if err != nil { @@ -181,13 +181,13 @@ func (wpp *StorageWpp) GenerateCandidates(ctx context.Context, randomness abi.Po func (wpp *StorageWpp) ComputeProof(ctx context.Context, ssi []abi.SectorInfo, rand abi.PoStRandomness) ([]abi.PoStProof, error) { if build.InsecurePoStValidation { - log.Warn("Generating fake EPost proof! You should only see this while running tests!") + log.Warn("[INSECURE-POST-VALIDATION] Generating fake PoSt proof! You should only see this while running tests!") return []abi.PoStProof{{ProofBytes: []byte("valid proof")}}, nil } log.Infof("Computing WinningPoSt ;%+v; %v", ssi, rand) - start := time.Now() + start := build.Clock.Now() proof, err := wpp.prover.GenerateWinningPoSt(ctx, wpp.miner, ssi, rand) if err != nil { return nil, err diff --git a/storage/mockstorage/preseal.go b/storage/mockstorage/preseal.go index ec5f0e1ca..9599545c0 100644 --- a/storage/mockstorage/preseal.go +++ b/storage/mockstorage/preseal.go @@ -45,7 +45,7 @@ func PreSeal(ssize abi.SectorSize, maddr address.Address, sectors int) (*genesis preseal.CommD = zerocomm.ZeroPieceCommitment(abi.PaddedPieceSize(ssize).Unpadded()) d, _ := commcid.CIDToPieceCommitmentV1(preseal.CommD) r := mock.CommDR(d) - preseal.CommR = commcid.ReplicaCommitmentV1ToCID(r[:]) + preseal.CommR, _ = commcid.ReplicaCommitmentV1ToCID(r[:]) preseal.SectorID = abi.SectorNumber(i + 1) preseal.Deal = market.DealProposal{ PieceCID: preseal.CommD, diff --git a/storage/wdpost_run.go b/storage/wdpost_run.go index 20c51575d..e5398f21b 100644 --- a/storage/wdpost_run.go +++ b/storage/wdpost_run.go @@ -176,7 +176,7 @@ func (s *WindowPoStScheduler) checkNextRecoveries(ctx context.Context, dlIdx uin Method: builtin.MethodsMiner.DeclareFaultsRecovered, Params: enc, Value: types.NewInt(0), - GasLimit: 10000000, // i dont know help + GasLimit: 100_000_000, // i dont know help GasPrice: types.NewInt(2), } @@ -260,7 +260,7 @@ func (s *WindowPoStScheduler) checkNextFaults(ctx context.Context, dlIdx uint64, Method: builtin.MethodsMiner.DeclareFaults, Params: enc, Value: types.NewInt(0), // TODO: Is there a fee? - GasLimit: 10000000, // i dont know help + GasLimit: 100_000_000, // i dont know help GasPrice: types.NewInt(2), } @@ -395,7 +395,7 @@ func (s *WindowPoStScheduler) runPost(ctx context.Context, di miner.DeadlineInfo "height", ts.Height(), "skipped", skipCount) - tsStart := time.Now() + tsStart := build.Clock.Now() log.Infow("generating windowPost", "sectors", len(sinfos)) diff --git a/storage/wdpost_sched.go b/storage/wdpost_sched.go index 077209a4e..8e3221ef9 100644 --- a/storage/wdpost_sched.go +++ b/storage/wdpost_sched.go @@ -14,6 +14,7 @@ import ( "github.com/filecoin-project/specs-storage/storage" "github.com/filecoin-project/lotus/api" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/store" "github.com/filecoin-project/lotus/chain/types" ) @@ -85,7 +86,7 @@ func (s *WindowPoStScheduler) Run(ctx context.Context) { if err != nil { log.Errorf("ChainNotify error: %+v") - time.Sleep(10 * time.Second) + build.Clock.Sleep(10 * time.Second) continue } diff --git a/tools/dockers/docker-examples/README.md b/tools/dockers/docker-examples/README.md index 24a6c3d2f..28553653c 100644 --- a/tools/dockers/docker-examples/README.md +++ b/tools/dockers/docker-examples/README.md @@ -5,8 +5,8 @@ In this `docker-examples/` directory are community-contributed Docker and Docker #### Example Use Cases - **For a miner** - - basic storage miner (`miner-basic-`) - - distributed storage miner + - basic miner (`miner-basic-`) + - distributed miner - **For API endpoints for building apps** - local node for a developer (`api-local-`) - hosted endpoint for apps / multiple developers (`api-hosted-`) diff --git a/tools/dockers/docker-examples/basic-miner-busybox/README.md b/tools/dockers/docker-examples/basic-miner-busybox/README.md index 067f87d10..e5a66b306 100644 --- a/tools/dockers/docker-examples/basic-miner-busybox/README.md +++ b/tools/dockers/docker-examples/basic-miner-busybox/README.md @@ -1,4 +1,4 @@ ## Description - **For a miner** - - basic storage miner + - basic miner diff --git a/tools/stats/metrics.go b/tools/stats/metrics.go index d0778ba1a..a6a3db3ad 100644 --- a/tools/stats/metrics.go +++ b/tools/stats/metrics.go @@ -66,7 +66,7 @@ func NewInfluxWriteQueue(ctx context.Context, influx client.Client) *InfluxWrite for i := 0; i < maxRetries; i++ { if err := influx.Write(batch); err != nil { log.Warnw("Failed to write batch", "error", err) - time.Sleep(time.Second * 15) + build.Clock.Sleep(15 * time.Second) continue } @@ -104,7 +104,7 @@ func InfluxNewBatch() (client.BatchPoints, error) { } func NewPoint(name string, value interface{}) models.Point { - pt, _ := models.NewPoint(name, models.Tags{}, map[string]interface{}{"value": value}, time.Now()) + pt, _ := models.NewPoint(name, models.Tags{}, map[string]interface{}{"value": value}, build.Clock.Now()) return pt } diff --git a/tools/stats/rpc.go b/tools/stats/rpc.go index d053ff561..6b6cef283 100644 --- a/tools/stats/rpc.go +++ b/tools/stats/rpc.go @@ -52,7 +52,7 @@ sync_complete: select { case <-ctx.Done(): return ctx.Err() - case <-time.After(5 * time.Second): + case <-build.Clock.After(5 * time.Second): state, err := napi.SyncState(ctx) if err != nil { return err @@ -97,13 +97,13 @@ sync_complete: select { case <-ctx.Done(): return ctx.Err() - case <-time.After(5 * time.Second): + case <-build.Clock.After(5 * time.Second): head, err := napi.ChainHead(ctx) if err != nil { return err } - timestampDelta := time.Now().Unix() - int64(head.MinTimestamp()) + timestampDelta := build.Clock.Now().Unix() - int64(head.MinTimestamp()) log.Infow( "Waiting for reasonable head height",