-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Losing When Expressions converting from v1beta1 to v1alpha1 #3815
Comments
Could we avoid storing the status if possible? |
I'm not sure we can - if we returned a PipelineRun's YAML without the status and the user re-applied that against a cluster they would have lost information I think. |
Moving this to 0.24 because it's not clear to me yet that #3854 is the way to go. |
Issues go stale after 90d of inactivity. /lifecycle stale Send feedback to tektoncd/plumbing. |
@sbwsg would it be fair to consider this fixed? i think you've specifically fixed this for when expressions at least. I think there might still be the issue of how to fix this broadly for all new fields we add - due to the lack of activity I'm wondering how important that is 🤔 |
Hey @bobcatfish we fixed this for |
Expected Behavior
All of the fields in a v1beta1 document are "round-trippable" through older versions like v1alpha1 without losing any data.
Actual Behavior
We lose certain fields that had no representation in the older v1alpha1 version when converting down from v1beta1. If a stored v1beta1 document has WhenExpressions, for example, then fetching the doc as v1alpha1 will drop those WhenExpressions from the returned data. Applying that returned document back to the cluster would result in the original stored v1beta1 resource being overwritten with a version that does not have WhenExpressions.
Steps to Reproduce the Problem
k get pipeline.v1alpha1.tekton.dev -o yaml <name of pipeline with when expressions> > test.yaml
test.yaml
to remove UID and any other server-generated fieldsk apply -f ./test.yaml
k get pipeline.v1beta1.tekton.dev -o yaml <name of pipeline with when when expressions> | less
Additional Info
v0.21.0
The text was updated successfully, but these errors were encountered: