mirror of
https://github.com/kubevela/kubevela.git
synced 2026-08-27 16:17:34 +00:00
Fix: fix unhandled err (#2423)
* Fix: fix unhandled err refer to https://lift.sonatype.com/result/bhamail/kubevela/01FFT7CSVNCPF6808ZM856V3HN?tab=results * Test: fix panic err
This commit is contained in:
@@ -284,7 +284,7 @@ func (r *Reconciler) handleFinalizers(ctx context.Context, envBinding *v1alpha1.
|
||||
func (r *Reconciler) endWithNegativeCondition(ctx context.Context, envBinding *v1alpha1.EnvBinding, cond condition.Condition) (ctrl.Result, error) {
|
||||
envBinding.SetConditions(cond)
|
||||
if err := r.Client.Status().Patch(ctx, envBinding, client.Merge); err != nil {
|
||||
return ctrl.Result{}, errors.WithMessage(err, "cannot update initializer status")
|
||||
return ctrl.Result{}, errors.WithMessage(err, "cannot update envbinding status")
|
||||
}
|
||||
// if any condition is changed, patching status can trigger requeue the resource and we should return nil to
|
||||
// avoid requeue it again
|
||||
|
||||
@@ -663,7 +663,6 @@ var _ = Describe("EnvBinding Normal tests", func() {
|
||||
By("Create envBinding")
|
||||
Expect(k8sClient.Create(ctx, envBinding)).Should(BeNil())
|
||||
|
||||
testutil.ReconcileOnce(&r, req)
|
||||
testutil.ReconcileRetry(&r, req)
|
||||
|
||||
By("Check the Application created by EnvBinding Controller")
|
||||
|
||||
Reference in New Issue
Block a user