Hello,
It seems that the image-reflector-controllers reconciler is always returning the result and error object without checking whether the error is not nil.
I do see these messages upon error:
Warning: Reconciler returned both a non-zero result and a non-nil error. The result will always be ignored if the error is non-nil and the non-nil error causes reqeueuing with exponential backoff. For more details, see: https://pkg.go.dev/sigs.k8s.io/controller-runtime/pkg/reconcile#Reconciler
I suggest to change this:
to something like this:
if retErr != nil {
return nil, retErr
}
return result, nil
Same can be applied for the imagepolicy controller:
There might be other flux components doing the same, but I didn't check them.
Hello,
It seems that the image-reflector-controllers reconciler is always returning the result and error object without checking whether the error is not nil.
I do see these messages upon error:
I suggest to change this:
image-reflector-controller/internal/controller/imagerepository_controller.go
Line 192 in a71ffb3
to something like this:
Same can be applied for the imagepolicy controller:
image-reflector-controller/internal/controller/imagepolicy_controller.go
Line 198 in a71ffb3
There might be other flux components doing the same, but I didn't check them.