-
Notifications
You must be signed in to change notification settings - Fork 216
genric_handler: error when object has no name #33
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
Conversation
|
|
||
| func applyUnstructured(client dynamic.ResourceInterface, required *unstructured.Unstructured) (*unstructured.Unstructured, bool, error) { | ||
| if required.GetName() == "" { | ||
| return nil, false, fmt.Errorf("invalid object: name cannot be empty") |
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.
hrm. Is there some way we can get an identifier here to help the log-reader figure out what needs fixing? Ordinarily that would be the name, but in this case... ? Maybe push this up into genericBuilder.Do where we can dump the broken b.raw?
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.
Or maybe keep more information (like the GVK?) from the initial m lib.Manifest in NewGenericBuilder?
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.
cluster-version-operator/pkg/cvo/sync.go
Line 51 in 4356101
| if err := b.Do(); err != nil { |
We print out the details of the task.
|
/lgtm |
|
/test e2e-aws |
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: abhinavdahiya, crawford, wking The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
fixes #32
/cc @wking