Handle missing on-chain precommit in WaitSeed

This commit is contained in:
Łukasz Magiera 2020-06-22 10:31:28 +02:00
parent 4380106d3e
commit b6e250303e

View File

@ -208,6 +208,9 @@ func (m *Sealing) handleWaitSeed(ctx statemachine.Context, sector SectorInfo) er
if err != nil {
return xerrors.Errorf("getting precommit info: %w", err)
}
if pci == nil {
return ctx.Send(SectorChainPreCommitFailed{error: xerrors.Errorf("precommit info not found on chain")})
}
randHeight := pci.PreCommitEpoch + miner.PreCommitChallengeDelay