diff --git a/validator/client/runner.go b/validator/client/runner.go index d4929692c..afe548e64 100644 --- a/validator/client/runner.go +++ b/validator/client/runner.go @@ -58,7 +58,7 @@ func run(ctx context.Context, v iface.Validator) { if v.ProposerSettings() != nil { log.Infof("Validator client started with provided proposer settings that sets options such as fee recipient"+ " and will periodically update the beacon node and custom builder (if --%s)", flags.EnableBuilderFlag.Name) - deadline := time.Now().Add(time.Duration(params.BeaconConfig().SecondsPerSlot) * time.Second) + deadline := time.Now().Add(5 * time.Minute) if err := v.PushProposerSettings(ctx, km, headSlot, deadline); err != nil { if errors.Is(err, ErrBuilderValidatorRegistration) { log.WithError(err).Warn("Push proposer settings error") diff --git a/validator/client/runner_test.go b/validator/client/runner_test.go index a83b6de1a..2926f2e4e 100644 --- a/validator/client/runner_test.go +++ b/validator/client/runner_test.go @@ -248,31 +248,6 @@ func TestUpdateProposerSettingsAt_EpochStart(t *testing.T) { assert.LogsContain(t, hook, "updated proposer settings") } -func TestUpdateProposerSettingsAt_EpochEndExceeded(t *testing.T) { - v := &testutil.FakeValidator{Km: &mockKeymanager{accountsChangedFeed: &event.Feed{}}, ProposerSettingWait: time.Duration(params.BeaconConfig().SecondsPerSlot+1) * time.Second} - err := v.SetProposerSettings(context.Background(), &validatorserviceconfig.ProposerSettings{ - DefaultConfig: &validatorserviceconfig.ProposerOption{ - FeeRecipientConfig: &validatorserviceconfig.FeeRecipientConfig{ - FeeRecipient: common.HexToAddress("0x046Fb65722E7b2455012BFEBf6177F1D2e9738D9"), - }, - }, - }) - require.NoError(t, err) - ctx, cancel := context.WithCancel(context.Background()) - hook := logTest.NewGlobal() - slot := params.BeaconConfig().SlotsPerEpoch - 1 //have it set close to the end of epoch - ticker := make(chan primitives.Slot) - v.NextSlotRet = ticker - go func() { - ticker <- slot - cancel() - }() - - run(ctx, v) - // can't test "Failed to update proposer settings" because of log.fatal - assert.LogsContain(t, hook, "deadline exceeded") -} - func TestUpdateProposerSettingsAt_EpochEndOk(t *testing.T) { v := &testutil.FakeValidator{Km: &mockKeymanager{accountsChangedFeed: &event.Feed{}}, ProposerSettingWait: time.Duration(params.BeaconConfig().SecondsPerSlot-1) * time.Second} err := v.SetProposerSettings(context.Background(), &validatorserviceconfig.ProposerSettings{