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

Label user error for failure PipelineRun Status Message #7475

Merged
merged 1 commit into from
Jan 16, 2024

Conversation

JeromeJu
Copy link
Member

@JeromeJu JeromeJu commented Dec 11, 2023

Changes

This commit labels the user errors for failed PipelineRun status. This aims to
communicate explicitly with users of whether the run failed could be
attributed to users' responsibility.

/kind misc
part of #7276

Submitter Checklist

As the author of this PR, please check off the items in this checklist:

  • Has Docs if any changes are user facing, including updates to minimum requirements e.g. Kubernetes version bumps
  • Has Tests included if any functionality added or changed
  • Follows the commit message standard
  • Meets the Tekton contributor standards (including functionality, content, code)
  • Has a kind label. You can add one by adding a comment on this PR that contains /kind <type>. Valid types are bug, cleanup, design, documentation, feature, flake, misc, question, tep
  • Release notes block below has been updated with any user facing changes (API changes, bug fixes, changes requiring upgrade notices or deprecation warnings). See some examples of good release notes.
  • Release notes contains the string "action required" if the change requires additional action from users switching to the new release

Release Notes

user error attributions can now be seen via PipelineRunStatus condition messages

@tekton-robot
Copy link
Collaborator

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@tekton-robot tekton-robot added kind/misc Categorizes issue or PR as a miscellaneuous one. release-note-none Denotes a PR that doesnt merit a release note. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. labels Dec 11, 2023
@JeromeJu JeromeJu changed the title 7276 reason user error Label user error for failure PipelineRun Status Reason Dec 11, 2023
@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 88.7% -0.8

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage-df to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 88.7% -0.8

@JeromeJu JeromeJu marked this pull request as ready for review December 11, 2023 16:29
@tekton-robot tekton-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Dec 11, 2023
@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 88.7% -0.8
pkg/reconciler/pipelinerun/resources/resultrefresolution.go 98.3% 99.2% 0.8

@JeromeJu
Copy link
Member Author

One bit that is off is that when I label the error messages with "[User error]" label, it appears to me that I have to match the exact event strings while previously it only required to provide the first half of the strings. This does not make our tests more fragile though from my understanding.

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 92.5% 2.9

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage-df to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 92.5% 2.9

@JeromeJu
Copy link
Member Author

/retest

@JeromeJu JeromeJu changed the title Label user error for failure PipelineRun Status Reason Label user error for failure PipelineRun Status Message Dec 19, 2023
@JeromeJu
Copy link
Member Author

Updated to label user message instead of reasons as we discussed how users would use reasons for downstream condition judgement.

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 92.5% 2.9

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage-df to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 92.5% 2.9
pkg/reconciler/pipelinerun/resources/resultrefresolution.go 99.2% 98.3% -0.8

Comment on lines 653 to 654
"Validation failed for pipelinerun with error %s",
pipelineErrors.WrapUserError(err))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need to include pipelinerun name here or it is added ?

@tekton-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Yongxuanzhang

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@tekton-robot tekton-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Dec 19, 2023
@tekton-robot tekton-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Dec 21, 2023
@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage-df to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 92.5% 2.9
pkg/reconciler/pipelinerun/resources/resultrefresolution.go 99.2% 98.3% -0.8

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 92.5% 2.9
pkg/reconciler/pipelinerun/resources/resultrefresolution.go 99.2% 98.3% -0.8

This commit labels the user errors for failed PipelineRun status. This aims to
communicate explicitly with users of whether the run failed could be
attributed to users' responsibility.

/kind misc
part of tektoncd#7276
JeromeJu added a commit to JeromeJu/pipeline that referenced this pull request Jan 3, 2024
This commit follows up tektoncd#7475 and labels user error for failed TaskRun
status messages. It marks off user errors in the taskrun reconciler and
communicate to users via TaskRunStatus condition messages.

/kind misc
part of tektoncd#7276
@tekton-robot tekton-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed release-note-none Denotes a PR that doesnt merit a release note. labels Jan 3, 2024
@JeromeJu
Copy link
Member Author

JeromeJu commented Jan 4, 2024

cc @tektoncd/core-maintainers
Looking for some feedback on this 🙏

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 92.5% 2.9

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage-df to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/errors/errors.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_types.go 89.5% 92.5% 2.9

@chitrangpatel chitrangpatel added this to the Pipelines v0.56 milestone Jan 9, 2024
@chitrangpatel
Copy link
Contributor

Thanks 🎉
/lgtm

@tekton-robot tekton-robot added the lgtm Indicates that a PR is ready to be merged. label Jan 16, 2024
@tekton-robot tekton-robot merged commit b4c7250 into tektoncd:main Jan 16, 2024
12 checks passed
JeromeJu added a commit to JeromeJu/pipeline that referenced this pull request Jan 17, 2024
This commit follows up tektoncd#7475 and labels user error for failed TaskRun
status messages. It marks off user errors in the taskrun reconciler and
communicate to users via TaskRunStatus condition messages.

/kind misc
part of tektoncd#7276
JeromeJu added a commit to JeromeJu/pipeline that referenced this pull request Jan 17, 2024
This commit follows up tektoncd#7475 and labels user error for failed TaskRun
status messages. It marks off user errors in the taskrun reconciler and
communicate to users via TaskRunStatus condition messages.

/kind misc
part of tektoncd#7276
JeromeJu added a commit to JeromeJu/pipeline that referenced this pull request Jan 24, 2024
This commit follows up tektoncd#7475 and labels user error for failed TaskRun
status messages. It marks off user errors in the taskrun reconciler and
communicate to users via TaskRunStatus condition messages.

/kind misc
part of tektoncd#7276
JeromeJu added a commit to JeromeJu/pipeline that referenced this pull request Jan 24, 2024
This commit follows up tektoncd#7475 and labels user error for failed TaskRun
status messages. It marks off user errors in the taskrun reconciler and
communicate to users via TaskRunStatus condition messages.

/kind misc
part of tektoncd#7276
tekton-robot pushed a commit that referenced this pull request Jan 30, 2024
This commit follows up #7475 and labels user error for failed TaskRun
status messages. It marks off user errors in the taskrun reconciler and
communicate to users via TaskRunStatus condition messages.

/kind misc
part of #7276
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. kind/misc Categorizes issue or PR as a miscellaneuous one. lgtm Indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants