From 94b65106a97f1732357c81fbd7884edc02567851 Mon Sep 17 00:00:00 2001 From: Dan Rammer Date: Wed, 24 May 2023 14:41:32 -0500 Subject: [PATCH] only initializing maptask if there is no failure (#352) Signed-off-by: Daniel Rammer --- flyteplugins/go/tasks/plugins/array/k8s/executor.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/flyteplugins/go/tasks/plugins/array/k8s/executor.go b/flyteplugins/go/tasks/plugins/array/k8s/executor.go index 7902cef156..79da214f3e 100644 --- a/flyteplugins/go/tasks/plugins/array/k8s/executor.go +++ b/flyteplugins/go/tasks/plugins/array/k8s/executor.go @@ -89,7 +89,7 @@ func (e Executor) Handle(ctx context.Context, tCtx core.TaskExecutionContext) (c nextState, err = array.DetermineDiscoverability(ctx, tCtx, pluginConfig.MaxArrayJobSize, pluginState) nextPhase, _ := nextState.GetPhase() - if err == nil && nextPhase != arrayCore.PhaseStart { + if err == nil && nextPhase != arrayCore.PhaseStart && nextPhase != arrayCore.PhasePermanentFailure { // we wait to transition out of PhaseStart to InitializeExternalResources because then the array // job configuration has then been validated and all of the metadata necessary to report subtask // status (ie. cache hit / etc) is available.