Skip to content

Commit bd6d090

Browse files
authored
Merge pull request #1865 from fluxcd/fix-stalled-errors
Fix GitRepository controller stalling when it shouldn't
2 parents a84403c + 1f4fc2f commit bd6d090

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

internal/controller/gitrepository_controller.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -591,7 +591,7 @@ func (r *GitRepositoryReconciler) reconcileSource(ctx context.Context, sp *patch
591591

592592
// Validate sparse checkout paths after successful checkout.
593593
if err := r.validateSparseCheckoutPaths(ctx, obj, dir); err != nil {
594-
e := serror.NewStalling(
594+
e := serror.NewGeneric(
595595
fmt.Errorf("failed to sparse checkout directories : %w", err),
596596
sourcev1.GitOperationFailedReason,
597597
)
@@ -747,7 +747,7 @@ func (r *GitRepositoryReconciler) getAuthOpts(ctx context.Context, obj *sourcev1
747747
default:
748748
// analyze secret, if it has github app data, perhaps provider should have been github.
749749
if appID := authData[github.KeyAppID]; len(appID) != 0 {
750-
e := serror.NewStalling(
750+
e := serror.NewGeneric(
751751
fmt.Errorf("secretRef '%s/%s' has github app data but provider is not set to github", obj.GetNamespace(), obj.Spec.SecretRef.Name),
752752
sourcev1.InvalidProviderConfigurationReason,
753753
)

0 commit comments

Comments
 (0)