Skip to content
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

task results reassertion #2701

Closed
pritidesai opened this issue May 28, 2020 · 10 comments
Closed

task results reassertion #2701

pritidesai opened this issue May 28, 2020 · 10 comments
Labels
area/api Indicates an issue or PR that deals with the API.

Comments

@pritidesai
Copy link
Member

pritidesai commented May 28, 2020

  • TaskResultsNotProduced: TaskRun for a task should result in failure if task results are not populated. Tasks are declared successful today even before initializing task results from container status. updateTaskRunResourceResult is executed when a taskRun is declared successful. TaskRun is declared complete and successful here, we should add a check on task results even before updating taskRun.status.

  • InvalidTaskResultReference: Task execution order is set such that the task producing a result is executed before the task referencing that result. In case of a failure of a referenced task, pipeline exits without executing the rest of the pipeline tasks. But when a referenced task succeeds and does not instantiate the result, the task referencing that result is not executed and pipeline results in failure. Pipeline exits with PipelineValidationFailed since the result did not exist. Replace PipelineValidationFailed with something more specific InvalidTaskResultReference.

An example of such task and pipeline execution here.

I think, we might not even get to this kind of error if TaskResultsNotProduced is implemented.

  • MissingTaskResultReference: A task might be set to produce task results but these results are not referenced in any of the pipeline tasks. This scenario is ignored today, does not impact task execution order and does not produce any failure. Pipeline should result in failure if task results are not referenced at all.

Please feel free to suggest better naming if these does not make sense.

@bobcatfish
Copy link
Collaborator

Hey @pritidesai ! I think I'm missing a bit of context for this one: is this about changing the error "reason" fields in Status conditions?

@bobcatfish bobcatfish added the triage/needs-information Indicates an issue needs more information in order to work on it. label May 28, 2020
@pritidesai
Copy link
Member Author

yes changing the reason field from generic PipelineValidationFailed to specific InvalidTaskResultReference and also changing the existing behavior where taskRun is marked successful without checking if task results were initialized/populated or not ... change TaskRun reconciler such that, check on task results are done before changing taskRun status to sucess.

@ghost ghost removed the triage/needs-information Indicates an issue needs more information in order to work on it. label Jul 7, 2020
@nikhil-thomas
Copy link
Member

/area api

@tekton-robot tekton-robot added the area/api Indicates an issue or PR that deals with the API. label Jul 10, 2020
@tekton-robot
Copy link
Collaborator

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.
If this issue is safe to close now please do so with /close.

/lifecycle rotten

Send feedback to tektoncd/plumbing.

@tekton-robot
Copy link
Collaborator

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

/close

Send feedback to tektoncd/plumbing.

@tekton-robot tekton-robot added the lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. label Aug 15, 2020
@tekton-robot
Copy link
Collaborator

@tekton-robot: Closing this issue.

In response to this:

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

/close

Send feedback to tektoncd/plumbing.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@vdemeester
Copy link
Member

/remove-lifecycle rotten
/remove-lifecycle stale
/reopen

@tekton-robot tekton-robot reopened this Aug 17, 2020
@tekton-robot
Copy link
Collaborator

@vdemeester: Reopened this issue.

In response to this:

/remove-lifecycle rotten
/remove-lifecycle stale
/reopen

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@tekton-robot tekton-robot removed the lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. label Aug 17, 2020
@bobcatfish
Copy link
Collaborator

bobcatfish commented Nov 4, 2020

@pritidesai looking at this more closely would you say #3497 is a duplicate of this issue? It sounds like this issue is about trying to add more validation around expectations for Task results?

@pritidesai
Copy link
Member Author

pritidesai commented Nov 4, 2020

This issue is about documenting and implementing the expected behavior in cases such as TaskResultsNotProduced i.e. a task must fail if the result is not populated (same as issue #3497), and InvalidTaskResultReference which was implemented with PR #2538.

MissingTaskResultReference is something not discussed much but does not warrant any changes in pipeline. A task is allowed to produce a number of results but pipeline does not enforce all of them being utilized by other tasks.

Yup, we can close this as a duplicate of #3497

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/api Indicates an issue or PR that deals with the API.
Projects
None yet
Development

No branches or pull requests

5 participants