Preparing report...

Report for github.com/appscode/kubed

A+    Excellent!    Found 22 issues across 29 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!


gocyclo100%

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.

No problems detected. Good job!


golint24%

Golint is a linter for Go source code.

    • kubed/pkg/operator/operator.go
    • Line 26: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 36: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 39: warning: exported type Operator should have comment or be unexported (golint)
    • Line 51: warning: exported method Operator.Configure should have comment or be unexported (golint)
    • Line 84: warning: exported method Operator.Run should have comment or be unexported (golint)
    • kubed/pkg/cmds/server/start.go
    • Line 35: warning: exported type KubedOptions should have comment or be unexported (golint)
    • Line 43: warning: exported function NewKubedOptions should have comment or be unexported (golint)
    • Line 60: warning: exported method KubedOptions.AddFlags should have comment or be unexported (golint)
    • Line 65: warning: exported method KubedOptions.Validate should have comment or be unexported (golint)
    • Line 69: warning: exported method KubedOptions.Complete should have comment or be unexported (golint)
    • Line 73: warning: exported method KubedOptions.Config should have comment or be unexported (golint)
    • Line 97: warning: exported method KubedOptions.Run should have comment or be unexported (golint)
    • kubed/test/e2e/framework/configmaps.go
    • Line 27: warning: should not use dot imports (golint)
    • Line 38: warning: exported method Invocation.NewConfigMap should have comment or be unexported (golint)
    • Line 54: warning: exported method Invocation.EventuallyNumOfConfigmaps should have comment or be unexported (golint)
    • Line 58: warning: exported method Invocation.EventuallyNumOfConfigmapsForContext should have comment or be unexported (golint)
    • Line 70: warning: exported method Invocation.EventuallyNumOfConfigmapsForClient should have comment or be unexported (golint)
    • Line 82: warning: exported method Invocation.EventuallyConfigMapSynced should have comment or be unexported (golint)
    • Line 106: warning: exported method Invocation.EventuallyConfigMapNotSynced should have comment or be unexported (golint)
    • Line 125: warning: exported method Invocation.EventuallyConfigMapSyncedToNamespace should have comment or be unexported (golint)
    • Line 132: warning: exported method Invocation.EventuallySyncedConfigMapsUpdated should have comment or be unexported (golint)
    • Line 159: warning: exported method Invocation.EventuallySyncedConfigMapsDeleted should have comment or be unexported (golint)
    • Line 183: warning: exported method Invocation.ReadConfigMapFromRecycleBin should have comment or be unexported (golint)
    • Line 219: warning: exported method Invocation.DeleteAllConfigmaps should have comment or be unexported (golint)
    • Line 235: warning: exported method Invocation.CreateConfigMap should have comment or be unexported (golint)
    • Line 238: warning: exported method Invocation.DeleteConfigMap should have comment or be unexported (golint)
    • kubed/test/e2e/framework/framework.go
    • Line 23: warning: should not use dot imports (golint)
    • Line 31: warning: exported type Framework should have comment or be unexported (golint)
    • Line 40: warning: exported function New should have comment or be unexported (golint)
    • Line 56: warning: exported method Framework.Invoke should have comment or be unexported (golint)
    • Line 63: warning: exported method Invocation.App should have comment or be unexported (golint)
    • Line 67: warning: exported type Invocation should have comment or be unexported (golint)
    • kubed/pkg/syncer/util.go
    • Line 31: warning: exported type SyncOptions should have comment or be unexported (golint)
    • Line 36: warning: exported function GetSyncOptions should have comment or be unexported (golint)
    • Line 51: warning: exported function NamespacesForSelector should have comment or be unexported (golint)
    • kubed/pkg/eventer/recoder.go
    • Line 31: warning: comment on exported const EventReasonOriginConflict should be of the form "EventReasonOriginConflict ..." (golint)
    • Line 35: warning: exported function NewEventRecorder should have comment or be unexported (golint)
    • kubed/pkg/operator/config.go
    • Line 31: warning: exported type Config should have comment or be unexported (golint)
    • Line 40: warning: exported type OperatorConfig should have comment or be unexported (golint)
    • Line 47: warning: exported function NewOperatorConfig should have comment or be unexported (golint)
    • Line 53: warning: exported method OperatorConfig.New should have comment or be unexported (golint)
    • kubed/pkg/cmds/server/options.go
    • Line 28: warning: exported type OperatorOptions should have comment or be unexported (golint)
    • Line 38: warning: exported function NewOperatorOptions should have comment or be unexported (golint)
    • Line 52: warning: exported method OperatorOptions.AddFlags should have comment or be unexported (golint)
    • Line 62: warning: exported method OperatorOptions.ApplyTo should have comment or be unexported (golint)
    • kubed/test/e2e/framework/namespaces.go
    • Line 22: warning: should not use dot imports (golint)
    • Line 31: warning: exported method Framework.Namespace should have comment or be unexported (golint)
    • Line 35: warning: exported method Framework.EnsureNamespace should have comment or be unexported (golint)
    • Line 47: warning: exported method Framework.NewNamespace should have comment or be unexported (golint)
    • Line 54: warning: exported method Invocation.NewNamespaceWithLabel should have comment or be unexported (golint)
    • Line 65: warning: exported method Invocation.NumberOfNameSpace should have comment or be unexported (golint)
    • Line 71: warning: exported method Framework.CreateNamespace should have comment or be unexported (golint)
    • Line 75: warning: exported method Framework.DeleteNamespace should have comment or be unexported (golint)
    • Line 79: warning: exported method Framework.EventuallyNamespaceDeleted should have comment or be unexported (golint)
    • Line 86: warning: exported method Invocation.EnsureNamespaceForContext should have comment or be unexported (golint)
    • Line 112: warning: exported method Invocation.DeleteNamespaceForContext should have comment or be unexported (golint)
    • kubed/test/e2e/framework/util.go
    • Line 41: warning: exported method Invocation.WaitUntilDeploymentReady should have comment or be unexported (golint)
    • Line 50: warning: exported method Invocation.WaitUntilDeploymentTerminated should have comment or be unexported (golint)
    • Line 59: warning: exported method Invocation.RemoveFromOperatorPod should have comment or be unexported (golint)
    • Line 73: warning: exported method Invocation.OperatorPod should have comment or be unexported (golint)
    • Line 90: warning: exported method Invocation.DeleteService should have comment or be unexported (golint)
    • Line 94: warning: exported method Invocation.DeleteEndpoints should have comment or be unexported (golint)
    • kubed/pkg/syncer/resourcehandlers.go
    • Line 27: warning: exported method ConfigSyncer.ConfigMapHandler should have comment or be unexported (golint)
    • Line 81: warning: exported method ConfigSyncer.SecretHandler should have comment or be unexported (golint)
    • Line 135: warning: exported method ConfigSyncer.NamespaceHandler should have comment or be unexported (golint)
    • kubed/pkg/cmds/root.go
    • Line 28: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 32: warning: exported function NewCmdKubed should have comment or be unexported (golint)
    • kubed/test/e2e/framework/secrets.go
    • Line 25: warning: should not use dot imports (golint)
    • Line 36: warning: exported method Invocation.NewSecret should have comment or be unexported (golint)
    • Line 52: warning: exported method Invocation.EventuallyNumOfSecrets should have comment or be unexported (golint)
    • Line 56: warning: exported method Invocation.EventuallyNumOfSecretsForContext should have comment or be unexported (golint)
    • Line 69: warning: exported method Invocation.EventuallyNumOfSecretsForClient should have comment or be unexported (golint)
    • Line 81: warning: exported method Invocation.EventuallySecretSynced should have comment or be unexported (golint)
    • Line 105: warning: exported method Invocation.EventuallySecretNotSynced should have comment or be unexported (golint)
    • Line 124: warning: exported method Invocation.EventuallySecretSyncedToNamespace should have comment or be unexported (golint)
    • Line 131: warning: exported method Invocation.EventuallySyncedSecretsUpdated should have comment or be unexported (golint)
    • Line 158: warning: exported method Invocation.EventuallySyncedSecretsDeleted should have comment or be unexported (golint)
    • Line 182: warning: exported method Invocation.DeleteAllSecrets should have comment or be unexported (golint)
    • Line 199: warning: exported method Framework.CreateSecret should have comment or be unexported (golint)
    • Line 203: warning: exported method Framework.DeleteSecret should have comment or be unexported (golint)
    • Line 207: warning: exported method Invocation.SecretForWebhookNotifier should have comment or be unexported (golint)
    • Line 224: warning: exported method Invocation.WaitUntilSecretCreated should have comment or be unexported (golint)
    • Line 229: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 237: warning: exported method Invocation.WaitUntilSecretDeleted should have comment or be unexported (golint)
    • Line 242: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • kubed/pkg/syncer/syncer.go
    • Line 38: warning: exported const ConfigSyncKey should have comment (or a comment on this block) or be unexported (golint)
    • Line 47: warning: exported type ConfigSyncer should have comment or be unexported (golint)
    • Line 56: warning: exported function New should have comment or be unexported (golint)
    • Line 63: warning: exported method ConfigSyncer.Configure should have comment or be unexported (golint)
    • Line 117: warning: exported method ConfigSyncer.SyncIntoNamespace should have comment or be unexported (golint)
    • kubed/pkg/server/server.go
    • Line 31: warning: exported var Scheme should have comment or be unexported (golint)
    • Line 53: warning: exported type KubedConfig should have comment or be unexported (golint)
    • Line 64: warning: exported method KubedServer.Run should have comment or be unexported (golint)
    • Line 74: warning: exported type CompletedConfig should have comment or be unexported (golint)
    • kubed/pkg/syncer/configmap.go
    • Line 34: warning: exported method ConfigSyncer.SyncConfigMap should have comment or be unexported (golint)
    • Line 55: warning: comment on exported method ConfigSyncer.SyncDeletedConfigMap should be of the form "SyncDeletedConfigMap ..." (golint)
    • kubed/pkg/syncer/secret.go
    • Line 34: warning: exported method ConfigSyncer.SyncSecret should have comment or be unexported (golint)
    • Line 55: warning: comment on exported method ConfigSyncer.SyncDeletedSecret should be of the form "SyncDeletedSecret ..." (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!