Preparing report...

Report for github.com/go-flow/flow

A+    Excellent!    Found 14 issues across 35 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!


gocyclo82%

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.

    • flow/tree_test.go
    • Line 498: warning: cyclomatic complexity 19 of function TestTreeFindCaseInsensitivePath() is high (> 15) (gocyclo)
    • flow/router.go
    • Line 262: warning: cyclomatic complexity 19 of function (*Router).dispatchRequest() is high (> 15) (gocyclo)
    • flow/tree.go
    • Line 501: warning: cyclomatic complexity 48 of function (*node).findCaseInsensitivePathRec() is high (> 15) (gocyclo)
    • Line 326: warning: cyclomatic complexity 38 of function (*node).getValue() is high (> 15) (gocyclo)
    • Line 109: warning: cyclomatic complexity 21 of function (*node).addRoute() is high (> 15) (gocyclo)
    • flow/path.go
    • Line 20: warning: cyclomatic complexity 28 of function CleanPath() is high (> 15) (gocyclo)
    • flow/module.go
    • Line 30: warning: cyclomatic complexity 20 of function NewModule() is high (> 15) (gocyclo)

golint74%

Golint is a linter for Go source code.

    • flow/response/download.go
    • Line 11: warning: exported type Download should have comment or be unexported (golint)
    • Line 31: warning: exported method Download.Status should have comment or be unexported (golint)
    • Line 35: warning: exported method Download.Handle should have comment or be unexported (golint)
    • flow/response/file.go
    • Line 5: warning: exported type File should have comment or be unexported (golint)
    • Line 9: warning: exported function NewFile should have comment or be unexported (golint)
    • Line 15: warning: exported method File.Status should have comment or be unexported (golint)
    • Line 19: warning: exported method File.Handle should have comment or be unexported (golint)
    • flow/provider.go
    • Line 3: warning: exported type Provider should have comment or be unexported (golint)
    • Line 15: warning: exported function NewProvider should have comment or be unexported (golint)
    • flow/response/render.go
    • Line 11: warning: exported type Render should have comment or be unexported (golint)
    • Line 16: warning: exported method Render.Status should have comment or be unexported (golint)
    • Line 20: warning: exported method Render.Handle should have comment or be unexported (golint)
    • Line 20: warning: receiver name rr should be consistent with previous receiver name re for Render (golint)
    • Line 38: warning: comment on exported function NewJSON should be of the form "NewJSON ..." (golint)
    • Line 62: warning: comment on exported function NewData should be of the form "NewData ..." (golint)
    • flow/module.go
    • Line 192: warning: exported method Module.IsRoot should have comment or be unexported (golint)
    • flow/response.go
    • Line 26: warning: exported function ResponseHeader should have comment or be unexported (golint)
    • flow/response/error.go
    • Line 5: warning: exported type Error should have comment or be unexported (golint)
    • Line 10: warning: exported function NewError should have comment or be unexported (golint)
    • Line 17: warning: exported method Error.Status should have comment or be unexported (golint)
    • Line 21: warning: exported method Error.Handle should have comment or be unexported (golint)
    • flow/response/headers.go
    • Line 5: warning: exported type Headers should have comment or be unexported (golint)
    • Line 10: warning: exported function NewHeaders should have comment or be unexported (golint)
    • Line 17: warning: exported method Headers.Status should have comment or be unexported (golint)
    • Line 21: warning: exported method Headers.Handle should have comment or be unexported (golint)
    • flow/response/redirect.go
    • Line 5: warning: exported type Redirect should have comment or be unexported (golint)
    • Line 18: warning: exported method Redirect.Status should have comment or be unexported (golint)
    • Line 22: warning: exported method Redirect.Handle should have comment or be unexported (golint)
    • Line 22: warning: receiver name rr should be consistent with previous receiver name re for Redirect (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!