-
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
Change the behavior of outputs that are also used as inputs. #1122
Conversation
/hold this should be submitted after the next release. |
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
/test pull-tekton-pipeline-integration-tests |
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
/test pull-tekton-pipeline-integration-tests |
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for this, I think it's an important change in the right direction!
I have some concerns though - it's probably ok to address them in a separate PR as long as keep it within the same release.
pkg/reconciler/v1alpha1/taskrun/resources/output_resource_test.go
Outdated
Show resolved
Hide resolved
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
Since we warned about this in 0.6 (#1119) I think we can merge this for 0.7. I'll take on fixing the integration test. |
This change makes the handling of Resources within a Task consistent, regardless of whether the same Resource is used as both an input and an output. Previously these were special cased, which made it hard to write Tasks consistently. This commit also makes a few minor changes to the way our bash output gets logged. I discovered this was missing during debugging, and made it consistent with the gsutil wrapper. This is a followup to tektoncd#1119 and should be submitted once the next release is cut.
The following is the coverage report on pkg/.
|
Now that we don't automatically copy the content of an input to an output (when the same resource is used as both an input and an output), this means that: - Our fan-in / fan-out test will need to explicitly write to the output path, instead of writing to the input path and assuming it would get copied over (the very behaviour we're changing in tektoncd#1188) - Data previously written to an output that is used as an input, and then an output later on, will be lost unless explicitly copied. In the update to the examples this was handled by symlinking the input to the output, I decided to instead update the test to no longer expect to see a file that was written by the first task in the graph and to not copy it explicitly. Note that there is actually a race between the two tasks fanning out - if the were writing the same file we would not be able to reliably predict which would win. Part of fixing tektoncd#1188
The following is the coverage report on pkg/.
|
Ready for another look @afrittoli ! And now that we've had the 0.6 release we should be able to merge this :D I also fixed the failing integration test. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm Nice work, thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: afrittoli, dlorenc, vdemeester 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 |
Since tektoncd#1122, we do not treat outputs that were inputs as well in any special way, meaning that the output folder will be empty unless we copy the input to the output. Fix the release pipeline to handle that. Fixes: tektoncd#1325
Since tektoncd#1122, we do not treat outputs that were inputs as well in any special way, meaning that the output folder will be empty unless we copy the input to the output. Fix the release pipeline to handle that.
Since #1122, we do not treat outputs that were inputs as well in any special way, meaning that the output folder will be empty unless we copy the input to the output. Fix the release pipeline to handle that.
Changes
This change makes the handling of Resources within a Task consistent, regardless of
whether the same Resource is used as both an input and an output. Previously these
were special cased, which made it hard to write Tasks consistently.
This is a followup to #1119 and should be submitted
once the next release is cut.
Fixes #1118
Submitter Checklist
These are the criteria that every PR should meet, please check them off as you
review them:
Release Notes