diff --git a/chain/gen/gen.go b/chain/gen/gen.go index 1547a9c10..f00de2924 100644 --- a/chain/gen/gen.go +++ b/chain/gen/gen.go @@ -535,7 +535,7 @@ func IsRoundWinner(ctx context.Context, ts *types.TipSet, round int64, miner add for _, s := range pset { cr, err := commcid.CIDToReplicaCommitmentV1(s.Info.Info.SealedCID) if err != nil { - return nil, err + return nil, xerrors.Errorf("get sealed cid: %w", err) } var commRa [32]byte copy(commRa[:], cr) diff --git a/chain/stmgr/stmgr.go b/chain/stmgr/stmgr.go index 6bd9de3e7..bef5f00b5 100644 --- a/chain/stmgr/stmgr.go +++ b/chain/stmgr/stmgr.go @@ -352,6 +352,10 @@ func (sm *StateManager) LoadActorState(ctx context.Context, a address.Address, o cst := cbor.NewCborStore(sm.cs.Blockstore()) if err := cst.Get(ctx, act.Head, out); err != nil { + var r cbg.Deferred + cst.Get(ctx, act.Head, &r) + fmt.Printf("badhead %x\n", r.Raw) + return nil, err } diff --git a/chain/stmgr/utils.go b/chain/stmgr/utils.go index fef31a844..fb815f77a 100644 --- a/chain/stmgr/utils.go +++ b/chain/stmgr/utils.go @@ -272,14 +272,7 @@ func LoadSectorsFromSet(ctx context.Context, bs blockstore.Blockstore, ssc cid.C return err } sset = append(sset, &api.ChainSectorInfo{ - Info: miner.SectorOnChainInfo{ - Info: miner.SectorPreCommitInfo{}, - ActivationEpoch: 0, - DealWeight: abi.DealWeight{}, - PledgeRequirement: abi.TokenAmount{}, - DeclaredFaultEpoch: 0, - DeclaredFaultDuration: 0, - }, + Info: oci, ID: abi.SectorNumber(i), }) return nil