From 1f4fc2fe87b63104b672050c3c2d53ae995e5d18 Mon Sep 17 00:00:00 2001 From: Matheus Pimenta Date: Tue, 12 Aug 2025 14:34:12 +0100 Subject: [PATCH] Fix GitRepository controller stalling when it shouldn't Signed-off-by: Matheus Pimenta --- internal/controller/gitrepository_controller.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/controller/gitrepository_controller.go b/internal/controller/gitrepository_controller.go index 7d4efc4f..5bafc1a0 100644 --- a/internal/controller/gitrepository_controller.go +++ b/internal/controller/gitrepository_controller.go @@ -591,7 +591,7 @@ func (r *GitRepositoryReconciler) reconcileSource(ctx context.Context, sp *patch // Validate sparse checkout paths after successful checkout. if err := r.validateSparseCheckoutPaths(ctx, obj, dir); err != nil { - e := serror.NewStalling( + e := serror.NewGeneric( fmt.Errorf("failed to sparse checkout directories : %w", err), sourcev1.GitOperationFailedReason, ) @@ -747,7 +747,7 @@ func (r *GitRepositoryReconciler) getAuthOpts(ctx context.Context, obj *sourcev1 default: // analyze secret, if it has github app data, perhaps provider should have been github. if appID := authData[github.KeyAppID]; len(appID) != 0 { - e := serror.NewStalling( + e := serror.NewGeneric( fmt.Errorf("secretRef '%s/%s' has github app data but provider is not set to github", obj.GetNamespace(), obj.Spec.SecretRef.Name), sourcev1.InvalidProviderConfigurationReason, )