Preparing report...

Report for github.com/storageos/cluster-operator

A+    Excellent!    Found 12 issues across 127 files

Tweet

gofmt100%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command

No problems detected. Good job!


go_vet100%

go vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string.

No problems detected. Good job!


gocyclo93%

Gocyclo calculates cyclomatic complexities of functions in Go source code. The cyclomatic complexity of a function is calculated according to the following rules: 1 is the base complexity of a function +1 for each 'if', 'for', 'case', '&&' or '||' Go Report Card warns on functions with cyclomatic complexity > 15.

    • cluster-operator/pkg/storageos/deploy_test.go
    • Line 148: warning: cyclomatic complexity 30 of function TestCreateDaemonSet() is high (> 15) (gocyclo)
    • Line 1361: warning: cyclomatic complexity 23 of function TestDelete() is high (> 15) (gocyclo)
    • Line 1010: warning: cyclomatic complexity 18 of function TestDeployTolerations() is high (> 15) (gocyclo)
    • Line 510: warning: cyclomatic complexity 17 of function TestCreateAPIManager() is high (> 15) (gocyclo)
    • Line 1977: warning: cyclomatic complexity 16 of function TestContainerImageSelection() is high (> 15) (gocyclo)

golint96%

Golint is a linter for Go source code.

    • cluster-operator/test/e2e/util/logs.go
    • Line 19: warning: exported function GetOperatorLogs should have comment or be unexported (golint)
    • Line 40: warning: exported function GetAPIManagerLogs should have comment or be unexported (golint)
    • Line 69: warning: exported function GetPodLogs should have comment or be unexported (golint)
    • Line 93: warning: exported function GetContainerLogs should have comment or be unexported (golint)
    • cluster-operator/internal/pkg/storageos/cluster.go
    • Line 10: warning: exported type Cluster should have comment or be unexported (golint)
    • Line 19: warning: exported method Cluster.IsEqual should have comment or be unexported (golint)
    • Line 23: warning: exported method Client.GetCluster should have comment or be unexported (golint)
    • Line 40: warning: exported method Client.UpdateCluster should have comment or be unexported (golint)
    • cluster-operator/pkg/apis/storageos/v1/zz_generated.openapi.go
    • Line 12: warning: exported function GetOpenAPIDefinitions should have comment or be unexported (golint)
    • Line 29: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_Job should be schemaPkgApisStorageosV1Job (golint)
    • Line 72: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_JobSpec should be schemaPkgApisStorageosV1JobSpec (golint)
    • Line 162: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_JobStatus should be schemaPkgApisStorageosV1JobStatus (golint)
    • Line 182: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_NFSServer should be schemaPkgApisStorageosV1NFSServer (golint)
    • Line 225: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_NFSServerSpec should be schemaPkgApisStorageosV1NFSServerSpec (golint)
    • Line 319: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_NFSServerStatus should be schemaPkgApisStorageosV1NFSServerStatus (golint)
    • Line 353: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_StorageOSCluster should be schemaPkgApisStorageosV1StorageOSCluster (golint)
    • Line 396: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_StorageOSClusterSpec should be schemaPkgApisStorageosV1StorageOSClusterSpec (golint)
    • Line 585: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_StorageOSClusterStatus should be schemaPkgApisStorageosV1StorageOSClusterStatus (golint)
    • Line 641: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_StorageOSUpgrade should be schemaPkgApisStorageosV1StorageOSUpgrade (golint)
    • Line 684: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_StorageOSUpgradeSpec should be schemaPkgApisStorageosV1StorageOSUpgradeSpec (golint)
    • Line 705: warning: don't use underscores in Go names; func schema_pkg_apis_storageos_v1_StorageOSUpgradeStatus should be schemaPkgApisStorageosV1StorageOSUpgradeStatus (golint)

ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!