Skip to content

Commit

Permalink
reasonable max value for initial sector expiration
Browse files Browse the repository at this point in the history
  • Loading branch information
zlhwdsz committed Jul 29, 2021
1 parent ee20d30 commit ef6620a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions extern/storage-sealing/states_sealing.go
Original file line number Diff line number Diff line change
Expand Up @@ -311,9 +311,9 @@ func (m *Sealing) preCommitParams(ctx statemachine.Context, sector SectorInfo) (

msd := policy.GetMaxProveCommitDuration(actors.VersionForNetwork(nv), sector.SectorType)

// Assume: both precommit msg & commit msg land on chain as late as possible
minExpiration := sector.TicketEpoch + policy.MaxPreCommitRandomnessLookback + msd + miner.MinSectorExpiration
if expiration < minExpiration {
if minExpiration := height + msd + miner.MinSectorExpiration + 10; expiration < minExpiration {
expiration = minExpiration
}

// Assume: both precommit msg & commit msg land on chain as early as possible
maxExpiration := height + policy.GetPreCommitChallengeDelay() + policy.GetMaxSectorExpirationExtension()
Expand Down

0 comments on commit ef6620a

Please sign in to comment.