do not run assign every slot (#2412)

This commit is contained in:
Raul Jordan 2019-04-28 09:44:45 -05:00 committed by GitHub
parent 80d47468e4
commit 63378793b4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -140,9 +140,7 @@ func (v *validator) SlotDeadline(slot uint64) time.Time {
// list of upcoming assignments needs to be updated. For example, at the
// beginning of a new epoch.
func (v *validator) UpdateAssignments(ctx context.Context, slot uint64) error {
// Testing run time for fetching every slot. This is not meant for production!
// https://github.com/prysmaticlabs/prysm/issues/2167
if slot%params.BeaconConfig().SlotsPerEpoch != 0 && v.assignments != nil && false {
if slot%params.BeaconConfig().SlotsPerEpoch != 0 && v.assignments != nil {
// Do nothing if not epoch start AND assignments already exist.
return nil
}