Preparing report...

Report for github.com/micro/go-api

A+    Excellent!    Found 26 issues across 37 files

Tweet

gofmt94%

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.


golint43%

Golint is a linter for Go source code.

    • go-api/resolver/grpc/grpc.go
    • Line 12: warning: exported type Resolver should have comment or be unexported (golint)
    • Line 14: warning: exported method Resolver.Resolve should have comment or be unexported (golint)
    • Line 36: warning: exported function NewResolver should have comment or be unexported (golint)
    • go-api/handler/api/api.go
    • Line 22: warning: exported const Handler should have comment (or a comment on this block) or be unexported (golint)
    • Line 104: warning: exported function NewHandler should have comment or be unexported (golint)
    • Line 111: warning: exported function WithService should have comment or be unexported (golint)
    • go-api/handler/rpc/rpc.go
    • Line 27: warning: exported const Handler should have comment (or a comment on this block) or be unexported (golint)
    • Line 184: warning: receiver name rh should be consistent with previous receiver name h for rpcHandler (golint)
    • Line 294: warning: exported function NewHandler should have comment or be unexported (golint)
    • Line 301: warning: exported function WithService should have comment or be unexported (golint)
    • go-api/handler/file/file.go
    • Line 8: warning: exported type Handler should have comment or be unexported (golint)
    • Line 10: warning: exported method Handler.Serve should have comment or be unexported (golint)
    • go-api/handler/options.go
    • Line 8: warning: exported type Options should have comment or be unexported (golint)
    • Line 14: warning: exported type Option should have comment or be unexported (golint)
    • go-api/router/options.go
    • Line 10: warning: exported type Options should have comment or be unexported (golint)
    • Line 17: warning: exported type Option should have comment or be unexported (golint)
    • Line 19: warning: exported function NewOptions should have comment or be unexported (golint)
    • Line 39: warning: exported function WithHandler should have comment or be unexported (golint)
    • Line 45: warning: exported function WithNamespace should have comment or be unexported (golint)
    • Line 51: warning: exported function WithRegistry should have comment or be unexported (golint)
    • Line 57: warning: exported function WithResolver should have comment or be unexported (golint)
    • go-api/resolver/path/path.go
    • Line 12: warning: exported type Resolver should have comment or be unexported (golint)
    • Line 14: warning: exported method Resolver.Resolve should have comment or be unexported (golint)
    • Line 31: warning: exported function NewResolver should have comment or be unexported (golint)
    • go-api/resolver/micro/micro.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)
    • go-api/handler/web/web.go
    • Line 20: warning: exported const Handler should have comment (or a comment on this block) or be unexported (golint)
    • Line 164: warning: exported function NewHandler should have comment or be unexported (golint)
    • Line 170: warning: exported function WithService should have comment or be unexported (golint)
    • go-api/server/options.go
    • Line 7: warning: exported type Option should have comment or be unexported (golint)
    • Line 9: warning: exported type Options should have comment or be unexported (golint)
    • Line 16: warning: exported function ACMEHosts should have comment or be unexported (golint)
    • Line 22: warning: exported function EnableACME should have comment or be unexported (golint)
    • Line 28: warning: exported function EnableTLS should have comment or be unexported (golint)
    • Line 34: warning: exported function TLSConfig should have comment or be unexported (golint)
    • go-api/resolver/host/host.go
    • Line 10: warning: exported type Resolver should have comment or be unexported (golint)
    • Line 12: warning: exported method Resolver.Resolve should have comment or be unexported (golint)
    • Line 25: warning: exported function NewResolver should have comment or be unexported (golint)
    • go-api/resolver/vpath/vpath.go
    • Line 13: warning: exported type Resolver should have comment or be unexported (golint)
    • Line 19: warning: exported method Resolver.Resolve should have comment or be unexported (golint)
    • Line 57: warning: exported function NewResolver should have comment or be unexported (golint)
    • go-api/handler/broker/broker.go
    • Line 20: warning: exported const Handler should have comment (or a comment on this block) or be unexported (golint)
    • Line 237: warning: exported function NewHandler should have comment or be unexported (golint)
    • Line 250: warning: exported function WithCors should have comment or be unexported (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!