From e2cbad6ff4e248a44056aadf7a9813dfb298cbe5 Mon Sep 17 00:00:00 2001 From: "eben.xie" Date: Wed, 23 Feb 2022 10:49:53 +0800 Subject: [PATCH] [Describe]: when excute cmd "lotus-bench sealing" without "benchmark-existing-sectorbuilder", panic will occur [BugFix]: [FeatureAdd]: [CodeReview]: [ModifyDesc]: [Author]: [BugID]: --- cmd/lotus-bench/main.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cmd/lotus-bench/main.go b/cmd/lotus-bench/main.go index b0e71b90e..c6fdd5e32 100644 --- a/cmd/lotus-bench/main.go +++ b/cmd/lotus-bench/main.go @@ -276,6 +276,13 @@ var sealBenchCmd = &cli.Command{ if err != nil { return xerrors.Errorf("failed to run seals: %w", err) } + for _, s := range extendedSealedSectors { + sealedSectors = append(sealedSectors, proof.SectorInfo{ + SealedCID: s.SealedCID, + SectorNumber: s.SectorNumber, + SealProof: s.SealProof, + }) + } } else { // TODO: implement sbfs.List() and use that for all cases (preexisting sectorbuilder or not)