-
Notifications
You must be signed in to change notification settings - Fork 149
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
Enable gocritic and gocyclo linters #2236
Conversation
Thanks for submitting this pull request π. The team will review it soon and get back to you. If you haven't already, please take a moment to review our project contributing guideline and Code of Conduct document. |
Let's mention the linter names in the PR title as well. |
@@ -503,7 +501,7 @@ func parseGenericObjectReference(s string) (crv1alpha1.ObjectReference, error) { | |||
}, nil | |||
} | |||
|
|||
func parseObjectsFromSelector(selector, kind, sns string, cli kubernetes.Interface, osCli osversioned.Interface, parsed map[string]bool) ([]crv1alpha1.ObjectReference, error) { | |||
func parseObjectsFromSelector(selector, kind, sns string, cli kubernetes.Interface, osCli osversioned.Interface, parsed map[string]bool) ([]crv1alpha1.ObjectReference, error) { //nolint:gocyclo |
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.
Does this fail even with 30 cyclo limit?
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.
We are setting the limit to 20, that's where it's failing. It has complexity of 21.
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.
Will re-review once we address the comments
@pavannd1 PTAL at the PR again. |
Change Overview
gocritic
andgocyclo
linters.Pull request type
Please check the type of change your PR introduces:
Issues
Test Plan