gatekeeper icon indicating copy to clipboard operation
gatekeeper copied to clipboard

spec.preserveUnknownFields has been deprecated in favor of x-kubernetes-preserve-unknown-fields: true in the CRD v1

Open sathieu opened this issue 6 months ago • 4 comments

What steps did you take and what happened:

According to https://argo-cd.readthedocs.io/en/stable/operator-manual/upgrading/2.14-3.0/#removing-default-ignores-of-preserveunknownfields-for-crd:

The spec.preserveUnknownFields has been deprecated in favor of x-kubernetes-preserve-unknown-fields: true in the CRD v1.

What did you expect to happen:

No diff in argoCD (i.e. no usage of field that is dropped by api).

  • removal of https://github.com/open-policy-agent/gatekeeper/blob/e5de78bf7bf9d736562e283bac66d3dc15a207dc/config/crd/patches/preserve_unknown_fields_false.yaml#L1-L6
  • +kubebuilder:validation:XPreserveUnknownFields replaced by +kubebuilder:pruning:PreserveUnknownFields (ref)

Anything else you would like to add:

Environment:

  • Gatekeeper version:
  • Kubernetes version: (use kubectl version):

sathieu avatar Jun 10 '25 08:06 sathieu

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Aug 09 '25 08:08 stale[bot]

not stale.

quercus-carsten avatar Aug 14 '25 09:08 quercus-carsten

@sathieu @quercus-carsten (or anyone else) would you be interested in contributing this change?

sozercan avatar Aug 18 '25 16:08 sozercan

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Nov 30 '25 17:11 stale[bot]