Remove network version panic
This commit is contained in:
@@ -738,8 +738,12 @@ func (s *WindowPoStScheduler) batchPartitions(partitions []api.Partition, nv net
|
||||
}
|
||||
|
||||
// Also respect the AddressedPartitionsMax (which is the same as DeclarationsMax (which is all really just MaxPartitionsPerDeadline))
|
||||
if partitionsPerMsg > policy.GetDeclarationsMax(nv) {
|
||||
partitionsPerMsg = policy.GetDeclarationsMax(nv)
|
||||
declMax, err := policy.GetDeclarationsMax(nv)
|
||||
if err != nil {
|
||||
return nil, xerrors.Errorf("getting max declarations: %w", err)
|
||||
}
|
||||
if partitionsPerMsg > declMax {
|
||||
partitionsPerMsg = declMax
|
||||
}
|
||||
|
||||
// The number of messages will be:
|
||||
|
||||
Reference in New Issue
Block a user