Preparing report...

Report for github.com/etcd-io/etcd

(v2.3.8+incompatible)

A+    Excellent!    Found 151 issues across 469 files

Tweet

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!


gofmt88%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


gocyclo78%

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.

    • Godeps/_workspace/src/github.com/ugorji/go/codec/msgpack.go
    • Line 284: warning: cyclomatic complexity 33 of function (*msgpackDecDriver).DecodeNaked() is high (> 15) (gocyclo)
    • Line 564: warning: cyclomatic complexity 25 of function (*msgpackDecDriver).ContainerType() is high (> 15) (gocyclo)
    • Line 427: warning: cyclomatic complexity 20 of function (*msgpackDecDriver).DecodeUint() is high (> 15) (gocyclo)
    • Line 383: warning: cyclomatic complexity 16 of function (*msgpackDecDriver).DecodeInt() is high (> 15) (gocyclo)
    • etcdmain/etcd.go
    • Line 78: warning: cyclomatic complexity 27 of function Main() is high (> 15) (gocyclo)
    • Line 199: warning: cyclomatic complexity 26 of function startEtcd() is high (> 15) (gocyclo)
    • Line 351: warning: cyclomatic complexity 22 of function startProxy() is high (> 15) (gocyclo)
    • integration/v3_watch_test.go
    • Line 556: warning: cyclomatic complexity 21 of function testV3WatchMultipleWatchers() is high (> 15) (gocyclo)
    • Line 33: warning: cyclomatic complexity 19 of function TestV3WatchFromCurrentRevision() is high (> 15) (gocyclo)
    • Line 418: warning: cyclomatic complexity 16 of function TestV3WatchCurrentPutOverlap() is high (> 15) (gocyclo)
    • raft/raft.go
    • Line 570: warning: cyclomatic complexity 32 of function stepLeader() is high (> 15) (gocyclo)
    • etcdserver/etcdhttp/client.go
    • Line 447: warning: cyclomatic complexity 29 of function parseKeyRequest() is high (> 15) (gocyclo)
    • Line 208: warning: cyclomatic complexity 26 of function (*membersHandler).ServeHTTP() is high (> 15) (gocyclo)
    • Godeps/_workspace/src/github.com/ugorji/go/codec/decode.go
    • Line 1642: warning: cyclomatic complexity 53 of function (*Decoder).getDecFn() is high (> 15) (gocyclo)
    • Line 810: warning: cyclomatic complexity 49 of function (*decFnInfo).kSlice() is high (> 15) (gocyclo)
    • Line 1468: warning: cyclomatic complexity 47 of function (*Decoder).decode() is high (> 15) (gocyclo)
    • Line 1010: warning: cyclomatic complexity 35 of function (*decFnInfo).kMap() is high (> 15) (gocyclo)
    • Line 700: warning: cyclomatic complexity 29 of function (*decFnInfo).kStruct() is high (> 15) (gocyclo)
    • Line 561: warning: cyclomatic complexity 22 of function (*decFnInfo).kInterfaceNaked() is high (> 15) (gocyclo)
    • Line 1393: warning: cyclomatic complexity 21 of function (*Decoder).swallow() is high (> 15) (gocyclo)
    • raft/node.go
    • Line 260: warning: cyclomatic complexity 32 of function (*node).run() is high (> 15) (gocyclo)
    • clientv3/watch.go
    • Line 262: warning: cyclomatic complexity 18 of function (*watcher).run() is high (> 15) (gocyclo)
    • Line 386: warning: cyclomatic complexity 17 of function (*watcher).serveStream() is high (> 15) (gocyclo)
    • etcdserver/server.go
    • Line 214: warning: cyclomatic complexity 41 of function NewServer() is high (> 15) (gocyclo)
    • Line 1053: warning: cyclomatic complexity 19 of function (*EtcdServer).applyRequest() is high (> 15) (gocyclo)
    • wal/wal.go
    • Line 229: warning: cyclomatic complexity 20 of function (*WAL).ReadAll() is high (> 15) (gocyclo)
    • etcdserver/cluster.go
    • Line 240: warning: cyclomatic complexity 19 of function (*cluster).ValidateConfigurationChange() is high (> 15) (gocyclo)
    • Godeps/_workspace/src/github.com/russross/blackfriday/block.go
    • Line 1074: warning: cyclomatic complexity 45 of function (*parser).listItem() is high (> 15) (gocyclo)
    • Line 1283: warning: cyclomatic complexity 29 of function (*parser).paragraph() is high (> 15) (gocyclo)
    • Line 542: warning: cyclomatic complexity 29 of function (*parser).isFencedCode() is high (> 15) (gocyclo)
    • Line 724: warning: cyclomatic complexity 28 of function (*parser).tableHeader() is high (> 15) (gocyclo)
    • Line 25: warning: cyclomatic complexity 24 of function (*parser).block() is high (> 15) (gocyclo)
    • Line 209: warning: cyclomatic complexity 21 of function (*parser).prefixHeader() is high (> 15) (gocyclo)
    • Line 302: warning: cyclomatic complexity 18 of function (*parser).html() is high (> 15) (gocyclo)
    • Line 420: warning: cyclomatic complexity 16 of function (*parser).htmlHr() is high (> 15) (gocyclo)
    • Godeps/_workspace/src/golang.org/x/net/http2/transport.go
    • Line 587: warning: cyclomatic complexity 34 of function (*ClientConn).RoundTrip() is high (> 15) (gocyclo)
    • Line 1120: warning: cyclomatic complexity 20 of function (*clientConnReadLoop).run() is high (> 15) (gocyclo)
    • Line 787: warning: cyclomatic complexity 19 of function (*clientStream).writeRequestBody() is high (> 15) (gocyclo)
    • Line 1220: warning: cyclomatic complexity 16 of function (*clientConnReadLoop).handleResponse() is high (> 15) (gocyclo)
    • Godeps/_workspace/src/github.com/russross/blackfriday/inline.go
    • Line 202: warning: cyclomatic complexity 91 of function link() is high (> 15) (gocyclo)
    • Line 674: warning: cyclomatic complexity 35 of function autoLink() is high (> 15) (gocyclo)
    • Line 943: warning: cyclomatic complexity 33 of function helperFindEmphChar() is high (> 15) (gocyclo)
    • Line 829: warning: cyclomatic complexity 31 of function tagLength() is high (> 15) (gocyclo)
    • Line 69: warning: cyclomatic complexity 18 of function emphasis() is high (> 15) (gocyclo)
    • Godeps/_workspace/src/github.com/spf13/cobra/command.go
    • Line 515: warning: cyclomatic complexity 23 of function (*Command).execute() is high (> 15) (gocyclo)
    • Line 393: warning: cyclomatic complexity 18 of function (*Command).Find() is high (> 15) (gocyclo)
    • Line 337: warning: cyclomatic complexity 17 of function stripFlags() is high (> 15) (gocyclo)
    • Line 622: warning: cyclomatic complexity 16 of function (*Command).ExecuteC() is high (> 15) (gocyclo)
    • etcdserver/v3demo_server.go
    • Line 561: warning: cyclomatic complexity 19 of function applyCompare() is high (> 15) (gocyclo)
    • Line 326: warning: cyclomatic complexity 18 of function applyRange() is high (> 15) (gocyclo)
    • Godeps/_workspace/src/github.com/ugorji/go/codec/gen.go
    • Line 1023: warning: cyclomatic complexity 43 of function (*genRunner).dec() is high (> 15) (gocyclo)
    • Line 613: warning: cyclomatic complexity 37 of function (*genRunner).enc() is high (> 15) (gocyclo)
    • Line 164: warning: cyclomatic complexity 26 of function Gen() is high (> 15) (gocyclo)
    • Line 772: warning: cyclomatic complexity 23 of function (*genRunner).encStruct() is high (> 15) (gocyclo)
    • Line 1611: warning: cyclomatic complexity 18 of function genMethodNameT() is high (> 15) (gocyclo)
    • Line 366: warning: cyclomatic complexity 17 of function (*genRunner).genRefPkgs() is high (> 15) (gocyclo)
    • Line 1191: warning: cyclomatic complexity 16 of function (*genRunner).decTryAssignPrimitive() is high (> 15) (gocyclo)
    • Line 1739: warning: cyclomatic complexity 16 of function genInternalDecCommandAsString() is high (> 15) (gocyclo)
    • store/stats.go
    • Line 113: warning: cyclomatic complexity 16 of function (*Stats).Inc() is high (> 15) (gocyclo)
    • Godeps/_workspace/src/github.com/ugorji/go/codec/encode.go
    • Line 1181: warning: cyclomatic complexity 45 of function (*Encoder).getEncFn() is high (> 15) (gocyclo)
    • Line 687: warning: cyclomatic complexity 41 of function (*Encoder).kMapCanonical() is high (> 15) (gocyclo)
    • Line 1049: warning: cyclomatic complexity 35 of function (*Encoder).encode() is high (> 15) (gocyclo)
    • Line 381: warning: cyclomatic complexity 25 of function (*encFnInfo).kSlice() is high (> 15) (gocyclo)
    • Line 497: warning: cyclomatic complexity 21 of function (*encFnInfo).kStruct() is high (> 15) (gocyclo)
    • Line 607: warning: cyclomatic complexity 16 of function (*encFnInfo).kMap() is high (> 15) (gocyclo)
    • wal/wal_test.go
    • Line 319: warning: cyclomatic complexity 16 of function TestRecoverAfterCut() is high (> 15) (gocyclo)
    • client/client.go
    • Line 443: warning: cyclomatic complexity 16 of function (*simpleHTTPClient).Do() is high (> 15) (gocyclo)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!