-
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
set task as failed #3571
set task as failed #3571
Conversation
The following is the coverage report on the affected files.
|
When a pod exceeds node resources I think Kubernetes will try to re-schedule it again when resources may have freed up? So the TaskRun might eventually succeed. If I'm understanding right, I don't know if we want to mark that as an immediate failure? |
Set task as failed when it encounters "CreateContainerConfigError". TaskRun status is set to this reason and condition status is set to "false" instead of "unknown". Before this change, taskRun status had the same reason but status was set to "unknown" which means task is still running.
ac8850c
to
4ffe396
Compare
The following is the coverage report on the affected files.
|
I am not sure either, was going by the comment here. I have reverted the changes for Lines 64 to 66 in ba2d2e7
|
@pritidesai |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: sbwsg, vincent-pli 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 |
@pritidesai would this handle the case when someone has a bad imagePullSecret -- we get that all the time and just see the Task Cancelled with no explanation. If so this PR would be a huge help for users trying to determine what went wrong. |
ah... ok according to our team this is needed because currently if we hit a config error that results in an ImagePullErr Tekton will just hang and cycle to ImagePullBackOff before ultimately waiting for the Pipeline to timeout. We're managing this currently by detecting and cancelling the TaskRun but this unfortunately hides the ConfigError from the user. |
thanks @sbwsg and @vincent-pli for the review. |
awesome, thanks you so much for fixing this @pritidesai 🙇🏽 /lgtm |
/test check-pr-has-kind-label |
Changes
Set task as failed when the pod encounters
CreateContainerConfigError
. TaskRun status is now set tofalse
instead ofunknown
with the same reasonCreateContainerConfigError
.Before this change,
taskRun
status had the same reasonCreateContainerConfigError
but status was set tounknown
which means task is still running in turn pipeline is still running until it hits the timeout.PR #1907 tried to fix this issue which was also reported in issue #1902.
Fixes #3412
/cc @vdemeester @vincent-pli @afrittoli @chmouel
/kind bug
Submitter Checklist
These are the criteria that every PR should meet, please check them off as you
review them:
See the contribution guide for more details.
Double check this list of stuff that's easy to miss:
cmd
dir, please updatethe release Task to build and release this image.
Reviewer Notes
If API changes are included, additive changes must be approved by at least two OWNERS and backwards incompatible changes must be approved by more than 50% of the OWNERS, and they must first be added in a backwards compatible way.
Release Notes