diff --git a/workflow/controller/artifact_gc.go b/workflow/controller/artifact_gc.go index cc98a422d7dd..be0f30b89368 100644 --- a/workflow/controller/artifact_gc.go +++ b/workflow/controller/artifact_gc.go @@ -508,7 +508,7 @@ func (woc *wfOperationCtx) processArtifactGCCompletion(ctx context.Context) erro return fmt.Errorf("failed to get pods from informer: %w", err) } - anyPodSuccess := false + anyPodSuccess := len(pods) == 0 for _, obj := range pods { pod := obj.(*corev1.Pod) if pod.Labels[common.LabelKeyComponent] != artifactGCComponent { // make sure it's an Artifact GC Pod