Preparing report...

Report for github.com/hyperledger/fabric

(v1.4.12)

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


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.

    • orderer/consensus/etcdraft/chain.go
    • Line 575: warning: cyclomatic complexity 48 of function (*Chain).serveRequest() is high (> 15) (gocyclo)
    • Line 1020: warning: cyclomatic complexity 23 of function (*Chain).apply() is high (> 15) (gocyclo)
    • Line 377: warning: cyclomatic complexity 16 of function (*Chain).checkConfigUpdateValidity() is high (> 15) (gocyclo)
    • core/scc/lscc/lscc.go
    • Line 800: warning: cyclomatic complexity 48 of function (*LifeCycleSysCC).Invoke() is high (> 15) (gocyclo)
    • Line 235: warning: cyclomatic complexity 21 of function checkCollectionMemberPolicy() is high (> 15) (gocyclo)
    • core/ledger/util/couchdb/couchdb.go
    • Line 1662: warning: cyclomatic complexity 31 of function (*CouchInstance).handleRequest() is high (> 15) (gocyclo)
    • Line 746: warning: cyclomatic complexity 20 of function (*CouchDatabase).ReadDoc() is high (> 15) (gocyclo)
    • Line 880: warning: cyclomatic complexity 17 of function (*CouchDatabase).ReadDocRange() is high (> 15) (gocyclo)
    • idemix/signature.go
    • Line 53: warning: cyclomatic complexity 20 of function NewSignature() is high (> 15) (gocyclo)
    • Line 246: warning: cyclomatic complexity 19 of function (*Signature).Ver() is high (> 15) (gocyclo)
    • msp/idemixmsp.go
    • Line 374: warning: cyclomatic complexity 29 of function (*idemixmsp).satisfiesPrincipalValidated() is high (> 15) (gocyclo)
    • Line 84: warning: cyclomatic complexity 20 of function (*idemixmsp).Setup() is high (> 15) (gocyclo)
    • protos/utils/proputils_test.go
    • Line 248: warning: cyclomatic complexity 26 of function TestProposal() is high (> 15) (gocyclo)
    • Line 492: warning: cyclomatic complexity 20 of function TestEnvelope() is high (> 15) (gocyclo)
    • Line 389: warning: cyclomatic complexity 16 of function TestProposalResponse() is high (> 15) (gocyclo)
    • msp/mspimpl.go
    • Line 459: warning: cyclomatic complexity 21 of function (*bccspmsp).satisfiesPrincipalInternalPreV13() is high (> 15) (gocyclo)
    • orderer/consensus/kafka/chain.go
    • Line 609: warning: cyclomatic complexity 37 of function (*chainImpl).processRegular() is high (> 15) (gocyclo)
    • Line 345: warning: cyclomatic complexity 25 of function (*chainImpl).processMessagesToBlocks() is high (> 15) (gocyclo)
    • Line 1025: warning: cyclomatic complexity 19 of function setupTopicForChannel() is high (> 15) (gocyclo)
    • orderer/consensus/kafka/chain_test.go
    • Line 2472: warning: cyclomatic complexity 54 of function TestResubmission() is high (> 15) (gocyclo)
    • Line 964: warning: cyclomatic complexity 26 of function TestProcessMessagesToBlocks() is high (> 15) (gocyclo)
    • Line 44: warning: cyclomatic complexity 24 of function TestChain() is high (> 15) (gocyclo)
    • Line 3380: warning: cyclomatic complexity 24 of function TestDeliverSession() is high (> 15) (gocyclo)
    • gossip/gossip/orgs_test.go
    • Line 289: warning: cyclomatic complexity 36 of function TestConfidentiality() is high (> 15) (gocyclo)
    • Line 140: warning: cyclomatic complexity 21 of function TestMultipleOrgEndpointLeakage() is high (> 15) (gocyclo)
    • peer/chaincode/common.go
    • Line 219: warning: cyclomatic complexity 23 of function checkChaincodeCmdParams() is high (> 15) (gocyclo)
    • Line 426: warning: cyclomatic complexity 20 of function ChaincodeInvokeOrQuery() is high (> 15) (gocyclo)
    • Line 344: warning: cyclomatic complexity 16 of function InitCmdFactory() 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!