Skip to content

Commit 64bfc42

Browse files
committed
fix: compare status correctly
Signed-off-by: Rob Bell <robell@redhat.com>
1 parent 9d92079 commit 64bfc42

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

pkg/controller/trainjob_controller.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ func (r *TrainJobReconciler) Reconcile(ctx context.Context, req ctrl.Request) (c
142142

143143
deadlineResult := r.reconcileDeadline(ctx, &trainJob)
144144

145-
if !equality.Semantic.DeepEqual(&trainJob.Status, prevTrainJob.Status) {
145+
if !equality.Semantic.DeepEqual(trainJob.Status, prevTrainJob.Status) {
146146
// TODO(astefanutti): Consider using SSA once controller-runtime client has SSA support
147147
// for sub-resources. See: https://github.com/kubernetes-sigs/controller-runtime/issues/3183
148148
err = errors.Join(err, r.client.Status().Patch(ctx, &trainJob, client.MergeFrom(prevTrainJob)))

0 commit comments

Comments
 (0)