Skip to content

Conversation

alvaroaleman
Copy link
Member

Prior to this, updates through Apply did not call versionedTracker.updateObject which does a number of things such as:

  • Resetting status if the object has a status resource and its not a status update
  • Fail if the RV is incorrect
  • Bump the RV
  • Delete the object if the request removed the last finalizer

The reason this happend is that versionedTracker embedded an testing.ObjectTracker and as a result, we inherited the Apply of that upstream tracker rather than implementing our own.

This PR contains three commits:

  1. Move versionedTracker into its own file
  2. Make versionedTracker a testing.ObjectTracker and stop embedding its upstream
  3. Call updateObject from the versioned trackers Apply and update things as needed, as well as adding tests

/assign @sbueringer
/hold

@alvaroaleman alvaroaleman added the tide/merge-method-squash Denotes a PR that should be squashed by tide when it merges. label Sep 14, 2025
@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Sep 14, 2025
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Sep 14, 2025
@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 14, 2025
@alvaroaleman alvaroaleman changed the title ⚠️ Fakeclient: Fix a number of bugs when updating obj through apply ⚠️ Fakeclient: Fix a number of bugs when updating through apply Sep 14, 2025
@k8s-ci-robot k8s-ci-robot added the size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. label Sep 14, 2025
@alvaroaleman alvaroaleman force-pushed the fakestatus branch 2 times, most recently from 8e536d1 to a8c73d7 Compare September 15, 2025 00:06
@sbueringer
Copy link
Member

Thank you very much!

/lgtm
/approve
/hold cancel

@k8s-ci-robot k8s-ci-robot added lgtm "Looks good to me", indicates that a PR is ready to be merged. and removed do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. labels Sep 18, 2025
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 52f5bd390f08a0938a3e8958ab16b46c962b664e

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: alvaroaleman, sbueringer

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [alvaroaleman,sbueringer]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot merged commit 961fc2c into kubernetes-sigs:main Sep 18, 2025
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. tide/merge-method-squash Denotes a PR that should be squashed by tide when it merges.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants