Preparing report...

Report for github.com/go-ego/riot

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


gocyclo97%

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.

    • riot/core/indexer.go
    • Line 561: warning: cyclomatic complexity 33 of function (*Indexer).LogicLookup() is high (> 15) (gocyclo)
    • Line 417: warning: cyclomatic complexity 29 of function (*Indexer).internalLookup() is high (> 15) (gocyclo)
    • Line 732: warning: cyclomatic complexity 17 of function computeTokenProximity() is high (> 15) (gocyclo)
    • riot/segment.go
    • Line 128: warning: cyclomatic complexity 17 of function (*Engine).segmenterData() is high (> 15) (gocyclo)

golint98%

Golint is a linter for Go source code.

    • riot/test_utils.go
    • Line 9: warning: exported type ScoringFields should have comment or be unexported (golint)
    • Line 22: warning: exported var Req1 should have comment or be unexported (golint)
    • Line 51: warning: exported type RankByTokenProximity should have comment or be unexported (golint)
    • Line 54: warning: exported method RankByTokenProximity.Score should have comment or be unexported (golint)
    • Line 62: warning: exported function OrderlessOpts should have comment or be unexported (golint)
    • Line 98: warning: exported var TestIndexOpts should have comment or be unexported (golint)
    • Line 103: warning: exported function AddDocs should have comment or be unexported (golint)
    • Line 139: warning: exported function AddDocsWithLabels should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign0%

IneffAssign detects ineffectual assignments in Go code.

An error occurred while running this test (exit status 3)


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!