Preparing report...

Report for github.com/threefoldtech/0-stor

A+    Excellent!    Found 14 issues across 123 files

Tweet

gofmt99%

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!


gocyclo95%

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.

    • 0-stor/client/datastor/pipeline/storage/distributed.go
    • Line 408: warning: cyclomatic complexity 28 of function (*DistributedChunkStorage).CheckChunk() is high (> 15) (gocyclo)
    • Line 242: warning: cyclomatic complexity 24 of function (*DistributedChunkStorage).readChunk() is high (> 15) (gocyclo)
    • Line 89: warning: cyclomatic complexity 22 of function (*DistributedChunkStorage).WriteChunk() is high (> 15) (gocyclo)
    • 0-stor/client/datastor/pipeline/storage/replicated.go
    • Line 130: warning: cyclomatic complexity 24 of function (*ReplicatedChunkStorage).CheckChunk() is high (> 15) (gocyclo)
    • Line 469: warning: cyclomatic complexity 21 of function (*ReplicatedChunkStorage).write() is high (> 15) (gocyclo)
    • Line 265: warning: cyclomatic complexity 17 of function (*ReplicatedChunkStorage).RepairChunk() is high (> 15) (gocyclo)
    • 0-stor/client/datastor/pipeline/async_splitter.go
    • Line 317: warning: cyclomatic complexity 28 of function (*AsyncSplitterPipeline).Read() is high (> 15) (gocyclo)
    • Line 127: warning: cyclomatic complexity 20 of function (*AsyncSplitterPipeline).Write() is high (> 15) (gocyclo)
    • Line 509: warning: cyclomatic complexity 19 of function (*AsyncSplitterPipeline).Check() is high (> 15) (gocyclo)

golint98%

Golint is a linter for Go source code.

    • 0-stor/client/datastor/zerodb/test/inmem_zerodb.go
    • Line 27: warning: exported type InMem0DBServer should have comment or be unexported (golint)
    • Line 35: warning: exported function NewInMem0DBServer should have comment or be unexported (golint)
    • Line 59: warning: exported method InMem0DBServer.Close should have comment or be unexported (golint)
    • Line 63: warning: exported method InMem0DBServer.ItemsSize should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign96%

IneffAssign detects ineffectual assignments in Go code.


misspell99%

Misspell Finds commonly misspelled English words