Preparing report...

Report for github.com/itzmanish/micro

A+    Excellent!    Found 78 issues across 181 files

Tweet

gofmt96%

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


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!


gocyclo89%

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.

    • micro/client/web/web.go
    • Line 450: warning: cyclomatic complexity 23 of function Run() is high (> 15) (gocyclo)
    • Line 96: warning: cyclomatic complexity 16 of function (*srv).ServeHTTP() is high (> 15) (gocyclo)

golint64%

Golint is a linter for Go source code.

    • micro/internal/namespace/resolver.go
    • Line 12: warning: exported function NewResolver should have comment or be unexported (golint)
    • Line 26: warning: exported method Resolver.ResolveWithType should have comment or be unexported (golint)
    • Line 30: warning: exported method Resolver.Resolve should have comment or be unexported (golint)
    • micro/internal/command/cli/command.go
    • Line 174: warning: exported function RegisterService should have comment or be unexported (golint)
    • Line 199: warning: exported function DeregisterService should have comment or be unexported (golint)
    • Line 224: warning: exported function GetService should have comment or be unexported (golint)
    • Line 299: warning: exported function NetworkConnect should have comment or be unexported (golint)
    • Line 326: warning: exported function NetworkConnections should have comment or be unexported (golint)
    • Line 372: warning: exported function NetworkGraph should have comment or be unexported (golint)
    • Line 387: warning: exported function NetworkNodes should have comment or be unexported (golint)
    • Line 429: warning: exported function NetworkRoutes should have comment or be unexported (golint)
    • Line 514: warning: exported function NetworkServices should have comment or be unexported (golint)
    • Line 542: warning: exported function NetworkDNSAdvertise should have comment or be unexported (golint)
    • Line 550: warning: exported function NetworkDNSRemove should have comment or be unexported (golint)
    • Line 558: warning: exported function NetworkDNSResolve should have comment or be unexported (golint)
    • Line 632: warning: exported function ListServices should have comment or be unexported (golint)
    • Line 654: warning: exported function Publish should have comment or be unexported (golint)
    • Line 682: warning: exported function CallService should have comment or be unexported (golint)
    • Line 746: warning: exported function QueryHealth should have comment or be unexported (golint)
    • Line 818: warning: exported function QueryStats should have comment or be unexported (golint)
    • micro/client/cli/util/util.go
    • Line 1: warning: package comment should be of the form "Package util ..." (golint)
    • Line 123: warning: exported type Env should have comment or be unexported (golint)
    • Line 128: warning: exported function AddEnv should have comment or be unexported (golint)
    • Line 188: warning: exported function GetEnvByName should have comment or be unexported (golint)
    • Line 209: warning: exported function GetEnvs should have comment or be unexported (golint)
    • Line 234: warning: exported function IsLocal should have comment or be unexported (golint)
    • Line 238: warning: exported function IsServer should have comment or be unexported (golint)
    • Line 242: warning: exported function IsPlatform should have comment or be unexported (golint)
    • micro/cmd/cmd.go
    • Line 45: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 47: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 51: warning: exported var GitCommit should have comment or be unexported (golint)
    • micro/internal/resolver/api/api.go
    • Line 10: warning: comment on exported type Resolver should be of the form "Resolver ..." (with optional leading article) (golint)
    • Line 18: warning: exported method Resolver.Resolve should have comment or be unexported (golint)
    • micro/service/config/handler/handler.go
    • Line 21: warning: exported var PathSplitter should have comment or be unexported (golint)
    • Line 30: warning: exported type Config should have comment or be unexported (golint)
    • Line 93: warning: exported method Config.Create should have comment or be unexported (golint)
    • Line 141: warning: exported method Config.Update should have comment or be unexported (golint)
    • Line 246: warning: exported method Config.Delete should have comment or be unexported (golint)
    • Line 332: warning: exported method Config.List should have comment or be unexported (golint)
    • Line 366: warning: exported method Config.Watch should have comment or be unexported (golint)
    • Line 401: warning: comment on exported function Watcher should be of the form "Watcher ..." (golint)
    • micro/cmd/usage/client/main.go
    • Line 13: warning: exported type Result should have comment or be unexported (golint)
    • Line 139: warning: should omit 2nd value from range; this loop is equivalent to `for k := range ...` (golint)
    • micro/service/broker/handler/handler.go
    • Line 13: warning: exported type Broker should have comment or be unexported (golint)
    • Line 17: warning: exported method Broker.Publish should have comment or be unexported (golint)
    • Line 32: warning: exported method Broker.Subscribe should have comment or be unexported (golint)
    • micro/internal/helper/helper.go
    • Line 18: warning: exported function ACMEHosts should have comment or be unexported (golint)
    • Line 28: warning: exported function RequestToContext should have comment or be unexported (golint)
    • Line 37: warning: exported function TLSConfig should have comment or be unexported (golint)
    • Line 82: warning: exported function UnexpectedCommand should have comment or be unexported (golint)
    • Line 94: warning: exported function MissingCommand should have comment or be unexported (golint)
    • micro/internal/version/version.go
    • Line 1: warning: package comment should be of the form "Package version ..." (golint)
    • Line 5: warning: exported const V should have comment (or a comment on this block) or be unexported (golint)
    • micro/service/router/handler/table.go
    • Line 11: warning: exported type Table should have comment or be unexported (golint)
    • Line 15: warning: exported method Table.Create should have comment or be unexported (golint)
    • Line 32: warning: exported method Table.Update should have comment or be unexported (golint)
    • Line 49: warning: exported method Table.Delete should have comment or be unexported (golint)
    • Line 92: warning: exported method Table.Query should have comment or be unexported (golint)
    • micro/client/bot/bot.go
    • Line 42: warning: comment on exported var Name should be of the form "Name ..." (golint)
    • Line 443: warning: exported function Commands should have comment or be unexported (golint)
    • micro/client/proxy/proxy.go
    • Line 40: warning: comment on exported var Address should be of the form "Address ..." (golint)
    • Line 42: warning: comment on exported var Protocol should be of the form "Protocol ..." (golint)
    • Line 44: warning: comment on exported var Endpoint should be of the form "Endpoint ..." (golint)
    • Line 46: warning: comment on exported var ACMEProvider should be of the form "ACMEProvider ..." (golint)
    • Line 48: warning: exported var ACMEChallengeProvider should have comment or be unexported (golint)
    • Line 52: warning: exported function Run should have comment or be unexported (golint)
    • Line 278: warning: exported function Commands should have comment or be unexported (golint)
    • micro/client/cli/cli.go
    • Line 39: warning: exported function Run should have comment or be unexported (golint)
    • Line 253: warning: exported function RegistryCommands should have comment or be unexported (golint)
    • micro/service/store/handler/handler.go
    • Line 17: warning: exported type Store should have comment or be unexported (golint)
    • Line 164: warning: exported method Store.Delete should have comment or be unexported (golint)
    • Line 190: warning: comment on exported method Store.Databases should be of the form "Databases ..." (golint)
    • Line 203: warning: comment on exported method Store.Tables should be of the form "Tables ..." (golint)
    • Line 216: warning: exported method Store.List should have comment or be unexported (golint)
    • micro/service/runtime/handler/handler.go
    • Line 14: warning: exported type Runtime should have comment or be unexported (golint)
    • Line 36: warning: exported method Runtime.Create should have comment or be unexported (golint)
    • Line 61: warning: exported method Runtime.Update should have comment or be unexported (golint)
    • Line 86: warning: exported method Runtime.Delete should have comment or be unexported (golint)
    • Line 111: warning: exported method Runtime.Logs should have comment or be unexported (golint)
    • micro/service/network/api/api.go
    • Line 50: warning: exported type Network should have comment or be unexported (golint)
    • Line 184: warning: comment on exported method Network.Nodes should be of the form "Nodes ..." (golint)
    • Line 225: warning: exported function Run should have comment or be unexported (golint)
    • micro/client/api/api.go
    • Line 43: warning: exported var Name should have comment or be unexported (golint)
    • Line 59: warning: exported function Run should have comment or be unexported (golint)
    • Line 322: warning: exported function Commands should have comment or be unexported (golint)
    • micro/internal/platform/platform.go
    • Line 19: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 23: warning: comment on exported var Version should be of the form "Version ..." (golint)
    • Line 27: warning: comment on exported var Services should be of the form "Services ..." (golint)
    • micro/service/registry/registry.go
    • Line 22: warning: comment on exported var Address should be of the form "Address ..." (golint)
    • Line 81: warning: exported function Run should have comment or be unexported (golint)
    • Line 129: warning: exported function Commands should have comment or be unexported (golint)
    • micro/service/service.go
    • Line 21: warning: exported function Run should have comment or be unexported (golint)
    • Line 120: warning: exported function Commands should have comment or be unexported (golint)
    • micro/service/broker/broker.go
    • Line 17: warning: comment on exported var Address should be of the form "Address ..." (golint)
    • Line 21: warning: exported function Run should have comment or be unexported (golint)
    • Line 66: warning: exported function Commands should have comment or be unexported (golint)
    • micro/service/config/config.go
    • Line 21: warning: comment on exported var Name should be of the form "Name ..." (golint)
    • Line 23: warning: comment on exported var Database should be of the form "Database ..." (golint)
    • Line 25: warning: comment on exported var Namespace should be of the form "Namespace ..." (golint)
    • Line 29: warning: exported function Run should have comment or be unexported (golint)
    • Line 181: warning: exported function Commands should have comment or be unexported (golint)
    • micro/service/network/network.go
    • Line 1: warning: package comment should be of the form "Package network ..." (golint)
    • Line 37: warning: comment on exported var Network should be of the form "Network ..." (golint)
    • Line 41: warning: comment on exported var Advertise should be of the form "Advertise ..." (golint)
    • Line 45: warning: comment on exported var Token should be of the form "Token ..." (golint)
    • Line 221: warning: exported function Commands should have comment or be unexported (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!


misspell94%

Misspell Finds commonly misspelled English words

    • micro/cmd/cmd.go
    • Line 270: warning: "overriden" is a misspelling of "overridden" (misspell)
    • Line 275: warning: "overriden" is a misspelling of "overridden" (misspell)