-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Description
Expected Behavior
For already existing API objects, the Pipelines API client should return me the same response, regardless of API client version.
Actual Behavior
Because v0.46 removes the API types of pipeline resources along with the functionality, different responses are returned.
This is problematic for downstream users of pipelines (chains, tkn, dashboard, etc.) because we're potentially losing data about what ran if the client version doesn't match the server version.
Steps to Reproduce the Problem
https://github.com/wlynch/test/tree/master/tekton/pipeline-resources-test
-
Take a sample Task/TaskRun w/ PipelineResources created with pipelines <= v0.45.0
-
Use a pipelines v0.46.0 client to fetch the data
-
diff:
--- v0.45/spec.json 2023-03-24 10:29:21.915291695 -0400 +++ v0.46/spec.json 2023-03-24 10:30:22.343472020 -0400 @@ -1,30 +1,6 @@ { - "resources": { - "outputs": [ - { - "name": "image", - "resourceSpec": { - "type": "image", - "params": [ - { - "name": "url", - "value": "gcr.io/foo/bar" - } - ] - } - } - ] - }, "serviceAccountName": "default", "taskSpec": { - "resources": { - "outputs": [ - { - "name": "image", - "type": "image" - } - ] - }, "steps": [ { "name": "",
Additional Info
I noticed this with #6150 - I suspect this applies to all deprecated PipelineResource types. /cc @JeromeJu
While PipelineResources have been deprecated for a while, we were still allowing these resources to be created up until v0.45.0.
In general we shouldn't be removing fields from being read alongside feature deprecations - we should block creation of new resources with these fields and wait until we're reasonably confident they are no longer in use. I'd consider putting removal of fields through another deprecation cycle so there's a period where they are effectively in a read-only state.
-
Kubernetes version:
Output of
kubectl version:$ kubectl version --short Client Version: v1.25.4 Kustomize Version: v4.5.7 Server Version: v1.25.2 -
Tekton Pipeline version:
Output of
tkn versionorkubectl get pods -n tekton-pipelines -l app=tekton-pipelines-controller -o=jsonpath='{.items[0].metadata.labels.version}'$ tkn version Client version: 0.29.1 Chains version: devel Pipeline version: v0.45.0