Preparing report...

Report for github.com/mwitkow/go-httpwares

A    Great!    Found 56 issues across 72 files

Tweet

gofmt87%

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!


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!


golint31%

Golint is a linter for Go source code.

    • go-httpwares/metrics/prometheus/options.go
    • Line 4: warning: don't use an underscore in package name (golint)
    • Line 24: warning: exported function WithName should have comment or be unexported (golint)
    • Line 30: warning: exported function WithLatency should have comment or be unexported (golint)
    • Line 36: warning: exported function WithHostLabel should have comment or be unexported (golint)
    • Line 42: warning: exported function WithPathLabel should have comment or be unexported (golint)
    • Line 48: warning: exported function WithSizes should have comment or be unexported (golint)
    • go-httpwares/tags/context.go
    • Line 4: warning: don't use an underscore in package name (golint)
    • Line 51: warning: comment on exported function ExtractInboundFromCtx should be of the form "ExtractInboundFromCtx ..." (golint)
    • Line 71: warning: comment on exported function ExtractOutboundFromCtx should be of the form "ExtractOutboundFromCtx ..." (golint)
    • go-httpwares/testing/wares_suite.go
    • Line 4: warning: don't use an underscore in package name (golint)
    • Line 50: warning: exported method WaresTestSuite.SetupSuite should have comment or be unexported (golint)
    • Line 107: warning: exported method WaresTestSuite.ServerAddr should have comment or be unexported (golint)
    • Line 111: warning: exported method WaresTestSuite.SimpleCtx should have comment or be unexported (golint)
    • Line 116: warning: exported method WaresTestSuite.TearDownSuite should have comment or be unexported (golint)
    • go-httpwares/metrics/reporter.go
    • Line 4: warning: don't use an underscore in package name (golint)
    • Line 11: warning: comment on exported type Reporter should be of the form "Reporter ..." (with optional leading article) (golint)
    • Line 17: warning: comment on exported type Tracker should be of the form "Tracker ..." (with optional leading article) (golint)
    • go-httpwares/testing/pingback.go
    • Line 1: warning: don't use an underscore in package name (golint)
    • Line 10: warning: exported const DefaultPingBackStatusCode should have comment (or a comment on this block) or be unexported (golint)
    • Line 34: warning: should omit 2nd value from range; this loop is equivalent to `for k := range ...` (golint)
    • go-httpwares/tags/options.go
    • Line 4: warning: don't use an underscore in package name (golint)
    • Line 23: warning: exported var DefaultServiceName should have comment or be unexported (golint)
    • Line 47: warning: exported type Option should have comment or be unexported (golint)
    • go-httpwares/logging/logrus/options.go
    • Line 1: warning: don't use an underscore in package name (golint)
    • Line 53: warning: exported type Option should have comment or be unexported (golint)
    • Line 147: warning: comment on exported function WithResponseFieldExtractor should be of the form "WithResponseFieldExtractor ..." (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign97%

IneffAssign detects ineffectual assignments in Go code.


misspell97%

Misspell Finds commonly misspelled English words