NameReference Transformer doesn't work with annotations. #4682
Labels
kind/bug
Categorizes issue or PR as related to a bug.
triage/accepted
Indicates an issue or PR is ready to be actively worked on.
The NameReference Transformer used on annotations doesn't work, Bcoz of the refBy field being added in annotations by this PR
some how when it moves up kustomization stack and when refBy field needs to be deleted from Resource Node it also removes referred annotations and thus transform doesn't apply on annotations.
Files that can reproduce the issue
For below files
kustomization.yaml
resources.yaml
kustomize build folder_name
doesn't produce expected output, the expected output used to come for version 4.2.0 , so its a bug which should have been caught in regression.
Expected output
Actual output
Kustomize version
kustomize/v4.5.2
Platform
Linux/macOS
Additional context
I am not sure on how to fix this
but if i add below code in kustomize/api/resource/resource.go on line no 371 and create the kustomize binary i get the expected output.
I am unsure on how to solve it , i don't see the new annotation refBy being used somewhere else, so can we just revert this PR or what?
The text was updated successfully, but these errors were encountered: