-
Notifications
You must be signed in to change notification settings - Fork 139
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
chore: store taskRuns in rh_advisiories #1474
Conversation
pkg/clients/tekton/pipelineruns.go
Outdated
@@ -239,7 +239,7 @@ func (t *TektonController) StorePipelineRun(prefix string, pipelineRun *pipeline | |||
|
|||
pipelineRunYaml, err := yaml.Marshal(pipelineRun) | |||
if err != nil { | |||
return err | |||
g.GinkgoWriter.Printf("failed to store pipelineRun %s:%s: %s\n", pipelineRun.GetNamespace(), pipelineRun.GetName(), err.Error()) |
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.
Shouldn't you still return the error after this in case tests are checking if this function returns error?
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.
To help debug, ignore the errors to store as many logs as it could.
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.
@jinqi7 would it be better to print out only this error instead?
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.
I want to make the change in Line#236.
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.
The error message may be misleading. Changed it.
pkg/clients/tekton/taskruns.go
Outdated
return err | ||
} | ||
if err := t.StoreTaskRun(taskRun.Name, taskRun); err != nil{ | ||
g.GinkgoWriter.Printf("failed to store taskRun %s:%s: %s\n", taskRun.GetNamespace(), taskRun.GetName(), err.Error()) |
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.
return the error here too, no?
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.
It's to print & ignore the error and store more content for debugging. Changed the message which may be misleading
/retest |
Signed-off-by: Jing Qi <[email protected]>
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: psturc 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 |
/retest |
1 similar comment
/retest |
/lgtm |
Description
Please include a summary of the changes and the related issue. Please also include relevant motivation and context. List any dependencies that are required for this change.
Issue ticket number and link
Type of change
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
Checklist: