-
Notifications
You must be signed in to change notification settings - Fork 1.2k
⚠️ Fakeclient: Remove support for objects with pointer meta #3228
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
⚠️ Fakeclient: Remove support for objects with pointer meta #3228
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: alvaroaleman 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:
Approvers can indicate their approval by writing |
This change removes supports for objects that have type or object meta defined as pointer. This is because the `FieldManagedObjectTracker` needed for support of SSA in the fakeclient can not support it, as it has a lot of places where it unconditionally accesses these fields using reflect, which will cause panics.
f20e2fe
to
06ac559
Compare
Do we have any idea of the use case for this? When would someone be deliberately using pointers here? Any scope of who we might break and how this might break them? |
I think its pretty uncommon and I think the main/only reason this might happen is when using gogo protobuf generation. It also didn't work at all until ~2 years ago: #2633 |
/lgtm |
LGTM label has been added. Git tree hash: 45206b294cd752c37b711051e3f5ea377e2f9069
|
/lgtm |
This change removes supports for objects that have type or object meta defined as pointer.
This is because the
FieldManagedObjectTracker
needed for support of SSA in the fakeclient can not support it, as it has a lot of places where it unconditionally accesses these fields using reflect, which will cause panics.