Preparing report...

Report for github.com/leaf-ai/platform-services

A+    Excellent!    Found 24 issues across 37 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!


gocyclo94%

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.


golint43%

Golint is a linter for Go source code.

    • platform-services/internal/platform/log.go
    • Line 20: warning: exported type Logger should have comment or be unexported (golint)
    • Line 24: warning: exported function NewLogger should have comment or be unexported (golint)
    • Line 30: warning: exported method Logger.Trace should have comment or be unexported (golint)
    • Line 37: warning: exported method Logger.Debug should have comment or be unexported (golint)
    • Line 44: warning: exported method Logger.Info should have comment or be unexported (golint)
    • Line 51: warning: exported method Logger.Warn should have comment or be unexported (golint)
    • Line 65: warning: exported method Logger.Fatal should have comment or be unexported (golint)
    • Line 72: warning: exported method Logger.Log should have comment or be unexported (golint)
    • Line 79: warning: exported method Logger.SetLevel should have comment or be unexported (golint)
    • Line 83: warning: exported method Logger.IsTrace should have comment or be unexported (golint)
    • Line 87: warning: exported method Logger.IsDebug should have comment or be unexported (golint)
    • Line 91: warning: exported method Logger.IsInfo should have comment or be unexported (golint)
    • Line 95: warning: exported method Logger.IsWarn should have comment or be unexported (golint)
    • platform-services/internal/experiment/db.go
    • Line 55: warning: exported const ExpectedDBVersion should have comment or be unexported (golint)
    • Line 76: warning: exported type DBErr should have comment or be unexported (golint)
    • Line 145: warning: error should be the last type when returning multiple items (golint)
    • Line 216: warning: exported type DBErrorMsg should have comment or be unexported (golint)
    • Line 344: warning: comment on exported function GetDBStatus should be of the form "GetDBStatus ..." (golint)
    • Line 423: warning: comment on exported function DBShowAllTrace should be of the form "DBShowAllTrace ..." (golint)
    • platform-services/cmd/downstream/modules.go
    • Line 17: warning: exported type Modules should have comment or be unexported (golint)
    • Line 33: warning: exported method Modules.AddListener should have comment or be unexported (golint)
    • Line 39: warning: exported method Modules.SetModule should have comment or be unexported (golint)
    • platform-services/cmd/restpoc/errorresp.go
    • Line 26: warning: exported method ErrResponse.Render should have comment or be unexported (golint)
    • Line 31: warning: exported function ErrInvalidRequest should have comment or be unexported (golint)
    • Line 40: warning: exported function ErrRender should have comment or be unexported (golint)
    • Line 49: warning: exported var ErrNotFound should have comment or be unexported (golint)
    • platform-services/cmd/downstream/server.go
    • Line 27: warning: exported type DownstreamServer should have comment or be unexported (golint)
    • Line 31: warning: exported method DownstreamServer.Ping should have comment or be unexported (golint)
    • Line 44: warning: exported method DownstreamServer.Check should have comment or be unexported (golint)
    • Line 48: warning: exported method DownstreamServer.Watch should have comment or be unexported (golint)
    • platform-services/cmd/experimentsrv/server.go
    • Line 35: warning: exported type ExperimentServer should have comment or be unexported (golint)
    • Line 96: warning: exported method ExperimentServer.MeshCheck should have comment or be unexported (golint)
    • Line 114: warning: exported method ExperimentServer.Create should have comment or be unexported (golint)
    • Line 131: warning: exported method ExperimentServer.Get should have comment or be unexported (golint)
    • Line 149: warning: exported method ExperimentServer.Check should have comment or be unexported (golint)
    • Line 149: warning: receiver name es should be consistent with previous receiver name eServer for ExperimentServer (golint)
    • Line 153: warning: exported method ExperimentServer.Watch should have comment or be unexported (golint)
    • Line 153: warning: receiver name es should be consistent with previous receiver name eServer for ExperimentServer (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign91%

IneffAssign detects ineffectual assignments in Go code.


misspell86%

Misspell Finds commonly misspelled English words