Add golang-ci and other linters #1
code-quality.yaml
on: push
golangci-lint (components/notebook-controller)
1m 25s
golangci-lint (components/odh-notebook-controller)
1m 28s
Annotations
42 errors
golangci-lint (components/notebook-controller)
Process completed with exit code 2.
|
golangci-lint (components/notebook-controller):
components/notebook-controller/controllers/culling_controller_test.go#L256
Error return value is not checked (errcheck)
|
golangci-lint (components/notebook-controller):
components/notebook-controller/api/v1beta1/notebook_webhook.go#L24
var `notebooklog` is unused (unused)
|
golangci-lint (components/notebook-controller):
components/notebook-controller/controllers/suite_test.go#L43
var `cfg` is unused (unused)
|
golangci-lint (components/notebook-controller):
components/notebook-controller/controllers/notebook_controller_bdd_test.go#L65
S1008: should use 'return err == nil' instead of 'if err != nil { return false }; return true' (gosimple)
|
golangci-lint (components/notebook-controller):
components/notebook-controller/controllers/notebook_controller.go#L96
S1021: should merge variable declaration with assignment on next line (gosimple)
|
golangci-lint (components/notebook-controller):
components/notebook-controller/pkg/culler/culler.go#L325
S1009: should omit nil check; len() for []github.com/kubeflow/kubeflow/components/notebook-controller/pkg/culler.KernelStatus is defined as zero (gosimple)
|
golangci-lint (components/notebook-controller):
components/notebook-controller/pkg/culler/culler.go#L362
S1009: should omit nil check; len() for []github.com/kubeflow/kubeflow/components/notebook-controller/pkg/culler.TerminalStatus is defined as zero (gosimple)
|
golangci-lint (components/notebook-controller):
components/notebook-controller/controllers/culling_controller.go#L359
S1009: should omit nil check; len() for []github.com/kubeflow/kubeflow/components/notebook-controller/controllers.KernelStatus is defined as zero (gosimple)
|
golangci-lint (components/notebook-controller):
components/notebook-controller/controllers/culling_controller.go#L395
S1009: should omit nil check; len() for []github.com/kubeflow/kubeflow/components/notebook-controller/controllers.TerminalStatus is defined as zero (gosimple)
|
golangci-lint (components/notebook-controller):
components/notebook-controller/pkg/culler/culler.go#L137
S1033: unnecessary guard around call to delete (gosimple)
|
golangci-lint (components/notebook-controller)
notebook.main calls manager.New, which eventually calls http2.ConfigureTransports
|
golangci-lint (components/notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.ConnectionError.Error
|
golangci-lint (components/notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.ErrCode.String
|
golangci-lint (components/notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.FrameHeader.String
|
golangci-lint (components/notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.FrameType.String
|
golangci-lint (components/notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.GoAwayError.Error
|
golangci-lint (components/notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.Setting.String
|
golangci-lint (components/notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.SettingID.String
|
golangci-lint (components/notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.StreamError.Error
|
golangci-lint (components/notebook-controller)
culler.getNotebookResourceResponse calls http.Client.Get, which eventually calls http2.Transport.NewClientConn
|
golangci-lint (components/odh-notebook-controller)
Process completed with exit code 2.
|
golangci-lint (components/odh-notebook-controller)
notebook.main calls manager.New, which eventually calls http2.ConfigureTransports
|
golangci-lint (components/odh-notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.ConnectionError.Error
|
golangci-lint (components/odh-notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.ErrCode.String
|
golangci-lint (components/odh-notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.FrameHeader.String
|
golangci-lint (components/odh-notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.FrameType.String
|
golangci-lint (components/odh-notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.GoAwayError.Error
|
golangci-lint (components/odh-notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.Setting.String
|
golangci-lint (components/odh-notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.SettingID.String
|
golangci-lint (components/odh-notebook-controller)
culler.UpdateNotebookLastActivityAnnotation calls fmt.Sprintf, which eventually calls http2.StreamError.Error
|
golangci-lint (components/odh-notebook-controller)
culler.getNotebookResourceResponse calls http.Client.Get, which eventually calls http2.Transport.NewClientConn
|
golangci-lint (components/odh-notebook-controller):
components/odh-notebook-controller/controllers/notebook_controller.go#L116
Error return value of `retry.OnError` is not checked (errcheck)
|
golangci-lint (components/odh-notebook-controller):
components/odh-notebook-controller/controllers/notebook_oauth.go#L190
Error return value of `rand.Read` is not checked (errcheck)
|
golangci-lint (components/odh-notebook-controller):
components/odh-notebook-controller/controllers/suite_test.go#L57
var `cfg` is unused (unused)
|
golangci-lint (components/odh-notebook-controller):
components/odh-notebook-controller/controllers/suite_test.go#L66
const `timeout` is unused (unused)
|
golangci-lint (components/odh-notebook-controller):
components/odh-notebook-controller/controllers/suite_test.go#L67
const `interval` is unused (unused)
|
golangci-lint (components/odh-notebook-controller):
components/odh-notebook-controller/controllers/notebook_route.go#L47
SA1019: pointer.Int32Ptr is deprecated: Use Int32 instead. (staticcheck)
|
golangci-lint (components/odh-notebook-controller):
components/odh-notebook-controller/controllers/notebook_webhook.go#L187
SA1019: pointer.Int32Ptr is deprecated: Use Int32 instead. (staticcheck)
|
golangci-lint (components/odh-notebook-controller):
components/odh-notebook-controller/controllers/notebook_webhook.go#L210
SA1019: pointer.Int32Ptr is deprecated: Use Int32 instead. (staticcheck)
|
golangci-lint (components/odh-notebook-controller):
components/odh-notebook-controller/controllers/notebook_controller_test.go#L144
SA1019: pointer.BoolPtr is deprecated: Use Bool instead. (staticcheck)
|
golangci-lint (components/odh-notebook-controller):
components/odh-notebook-controller/controllers/notebook_controller_test.go#L145
SA1019: pointer.BoolPtr is deprecated: Use Bool instead. (staticcheck)
|