Preparing report...

Report for github.com/s7techlab/cckit

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


gocyclo98%

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.


golint36%

Golint is a linter for Go source code.

    • cckit/examples/erc20/erc20_fixedsupply.go
    • Line 10: warning: exported const SymbolKey should have comment or be unexported (golint)
    • Line 11: warning: exported const NameKey should have comment or be unexported (golint)
    • Line 12: warning: exported const TotalSupplyKey should have comment or be unexported (golint)
    • Line 14: warning: exported function NewErc20FixedSupply should have comment or be unexported (golint)
    • cckit/extensions/pinger/pinger.go
    • Line 13: warning: comment on exported const PingKeyPrefix should be of the form "PingKeyPrefix ..." (golint)
    • Line 32: warning: exported method PingInfo.Key should have comment or be unexported (golint)
    • cckit/router/param/parameters.go
    • Line 11: warning: exported const LastPosKey should have comment or be unexported (golint)
    • Line 43: warning: exported method Parameter.ValueFromContext should have comment or be unexported (golint)
    • cckit/state/state_list.go
    • Line 15: warning: exported type StateList should have comment or be unexported (golint)
    • Line 22: warning: exported function NewStateList should have comment or be unexported (golint)
    • Line 36: warning: exported method StateList.Fill should have comment or be unexported (golint)
    • Line 53: warning: exported method StateList.Get should have comment or be unexported (golint)
    • Line 82: warning: exported method StateList.AddElementToList should have comment or be unexported (golint)
    • cckit/gateway/events/service.go
    • Line 12: warning: exported type ChaincodeEventGateway should have comment or be unexported (golint)
    • Line 25: warning: exported method ChaincodeEventGateway.EventStream should have comment or be unexported (golint)
    • Line 25: warning: receiver name s should be consistent with previous receiver name c for ChaincodeEventGateway (golint)
    • cckit/gateway/event_stream.go
    • Line 12: warning: exported type ChaincodeEventServerStream should have comment or be unexported (golint)
    • Line 20: warning: exported function NewChaincodeEventServerStream should have comment or be unexported (golint)
    • Line 36: warning: exported method ChaincodeEventServerStream.SetHeader should have comment or be unexported (golint)
    • Line 40: warning: exported method ChaincodeEventServerStream.SendHeader should have comment or be unexported (golint)
    • Line 44: warning: exported method ChaincodeEventServerStream.SetTrailer should have comment or be unexported (golint)
    • Line 47: warning: exported method ChaincodeEventServerStream.Context should have comment or be unexported (golint)
    • Line 51: warning: exported method ChaincodeEventServerStream.SendMsg should have comment or be unexported (golint)
    • Line 72: warning: exported method ChaincodeEventServerStream.Recv should have comment or be unexported (golint)
    • Line 76: warning: exported method ChaincodeEventServerStream.RecvMsg should have comment or be unexported (golint)
    • Line 90: warning: exported method ChaincodeEventServerStream.Events should have comment or be unexported (golint)
    • Line 94: warning: exported method ChaincodeEventServerStream.Close should have comment or be unexported (golint)
    • cckit/extensions/debug/handler.go
    • Line 11: warning: exported const InvokeStateCleanFunc should have comment (or a comment on this block) or be unexported (golint)
    • Line 25: warning: comment on exported var PrefixesParam should be of the form "PrefixesParam ..." (golint)
    • Line 32: warning: comment on exported function AddHandlers should be of the form "AddHandlers ..." (golint)
    • Line 70: warning: comment on exported function InvokeStatePut should be of the form "InvokeStatePut ..." (golint)
    • Line 94: warning: comment on exported function InvokeStateDelete should be of the form "InvokeStateDelete ..." (golint)
    • cckit/router/param/type.go
    • Line 13: warning: exported var ErrProtoExpected should have comment or be unexported (golint)
    • Line 21: warning: exported function Strings should have comment or be unexported (golint)
    • Line 53: warning: exported function TypeErrorMiddleware should have comment or be unexported (golint)
    • cckit/gateway/context.go
    • Line 9: warning: exported const CtxTransientKey should have comment or be unexported (golint)
    • Line 11: warning: exported function ContextWithTransientMap should have comment or be unexported (golint)
    • Line 15: warning: exported function ContextWithTransientValue should have comment or be unexported (golint)
    • Line 24: warning: exported function TransientFromContext should have comment or be unexported (golint)
    • Line 27: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • cckit/identity/cert_identity.go
    • Line 58: warning: comment on exported method CertIdentity.GetMSPID should be of the form "GetMSPID ..." (golint)
    • Line 63: warning: exported method CertIdentity.ExpiresAt should have comment or be unexported (golint)
    • Line 67: warning: exported method CertIdentity.GetMSPIdentifier should have comment or be unexported (golint)
    • Line 71: warning: exported method CertIdentity.GetIdentifier should have comment or be unexported (golint)
    • Line 78: warning: exported method CertIdentity.Validate should have comment or be unexported (golint)
    • Line 82: warning: exported method CertIdentity.Verify should have comment or be unexported (golint)
    • Line 86: warning: exported method CertIdentity.Anonymous should have comment or be unexported (golint)
    • Line 90: warning: exported method CertIdentity.GetOrganizationalUnits should have comment or be unexported (golint)
    • Line 104: warning: exported method CertIdentity.GetPublicKey should have comment or be unexported (golint)
    • Line 124: warning: exported method CertIdentity.Serialize should have comment or be unexported (golint)
    • Line 133: warning: exported method CertIdentity.SatisfiesPrincipal should have comment or be unexported (golint)
    • Line 137: warning: exported method CertIdentity.Sign should have comment or be unexported (golint)
    • Line 141: warning: exported method CertIdentity.GetPublicVersion should have comment or be unexported (golint)
    • cckit/state/mapping/state_mapping_opt.go
    • Line 15: warning: exported const TimestampKeyLayout should have comment (or a comment on this block) or be unexported (golint)
    • Line 25: warning: exported function KeyerFor should have comment or be unexported (golint)
    • Line 52: warning: exported function WithIndex should have comment or be unexported (golint)
    • Line 96: warning: exported function PKeyAttr should have comment or be unexported (golint)
    • Line 128: warning: exported function PKeyer should have comment or be unexported (golint)
    • cckit/examples/payment/mapping.go
    • Line 9: warning: comment on exported var StateMappings should be of the form "StateMappings ..." (golint)
    • Line 17: warning: comment on exported var EventMappings should be of the form "EventMappings ..." (golint)
    • cckit/gateway/service/context.go
    • Line 17: warning: exported const CtxSignerKey should have comment (or a comment on this block) or be unexported (golint)
    • Line 21: warning: exported function ContextWithDefaultSigner should have comment or be unexported (golint)
    • Line 24: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 29: warning: exported function ContextWithSigner should have comment or be unexported (golint)
    • Line 33: warning: exported function SignerFromContext should have comment or be unexported (golint)
    • Line 36: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 41: warning: exported function ContextWithDefaultDoOption should have comment or be unexported (golint)
    • Line 44: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 49: warning: exported function ContextWithDoOption should have comment or be unexported (golint)
    • Line 53: warning: exported function DoOptionFromContext should have comment or be unexported (golint)
    • cckit/examples/cpaper_extended/chaincode.go
    • Line 1: warning: don't use an underscore in package name (golint)
    • Line 17: warning: comment on exported var StateMappings should be of the form "StateMappings ..." (golint)
    • Line 26: warning: comment on exported var EventMappings should be of the form "EventMappings ..." (golint)
    • Line 36: warning: exported function NewCC should have comment or be unexported (golint)
    • cckit/state/mapping/state.go
    • Line 14: warning: exported type MappedState should have comment or be unexported (golint)
    • Line 28: warning: exported type Impl should have comment or be unexported (golint)
    • Line 34: warning: exported function WrapState should have comment or be unexported (golint)
    • Line 41: warning: exported method Impl.MappingNamespace should have comment or be unexported (golint)
    • Line 50: warning: exported method Impl.Get should have comment or be unexported (golint)
    • Line 70: warning: exported method Impl.GetHistory should have comment or be unexported (golint)
    • Line 79: warning: exported method Impl.Exists should have comment or be unexported (golint)
    • Line 88: warning: exported method Impl.Put should have comment or be unexported (golint)
    • Line 145: warning: exported method Impl.Insert should have comment or be unexported (golint)
    • Line 166: warning: exported method Impl.List should have comment or be unexported (golint)
    • Line 182: warning: exported method Impl.ListWith should have comment or be unexported (golint)
    • Line 197: warning: exported method Impl.GetByUniqKey should have comment or be unexported (golint)
    • Line 202: warning: exported method Impl.GetByKey should have comment or be unexported (golint)
    • Line 217: warning: exported method Impl.Delete should have comment or be unexported (golint)
    • Line 250: warning: exported method Impl.Logger should have comment or be unexported (golint)
    • Line 254: warning: exported method Impl.UseKeyTransformer should have comment or be unexported (golint)
    • Line 258: warning: exported method Impl.GetPrivate should have comment or be unexported (golint)
    • Line 267: warning: exported method Impl.DeletePrivate should have comment or be unexported (golint)
    • Line 277: warning: exported method Impl.ListPrivate should have comment or be unexported (golint)
    • Line 291: warning: exported method Impl.InsertPrivate should have comment or be unexported (golint)
    • Line 312: warning: exported method Impl.PutPrivate should have comment or be unexported (golint)
    • Line 335: warning: exported method Impl.ExistsPrivate should have comment or be unexported (golint)
    • cckit/examples/insurance/dto.go
    • Line 12: warning: exported type ContractTypeDTO should have comment or be unexported (golint)
    • Line 17: warning: exported type ContractTypeActiveDTO should have comment or be unexported (golint)
    • Line 22: warning: exported type ShopTypeDTO should have comment or be unexported (golint)
    • Line 50: warning: comment on exported type GetUserDTO should be of the form "GetUserDTO ..." (with optional leading article) (golint)
    • Line 55: warning: comment on exported type ResponseUserDTO should be of the form "ResponseUserDTO ..." (with optional leading article) (golint)
    • cckit/extensions/encryption/state.go
    • Line 106: warning: comment on exported function FromBytesDecryptor should be of the form "FromBytesDecryptor ..." (golint)
    • Line 120: warning: comment on exported function ToBytesEncryptor should be of the form "ToBytesEncryptor ..." (golint)
    • cckit/examples/cpaper_asservice/service/service.go
    • Line 14: warning: exported type CPaperImpl should have comment or be unexported (golint)
    • Line 17: warning: exported function New should have comment or be unexported (golint)
    • Line 43: warning: exported method CPaperImpl.List should have comment or be unexported (golint)
    • Line 50: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 55: warning: exported method CPaperImpl.Get should have comment or be unexported (golint)
    • Line 58: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 63: warning: exported method CPaperImpl.GetByExternalId should have comment or be unexported (golint)
    • Line 67: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 72: warning: exported method CPaperImpl.Issue should have comment or be unexported (golint)
    • Line 100: warning: exported method CPaperImpl.Buy should have comment or be unexported (golint)
    • Line 139: warning: exported method CPaperImpl.Redeem should have comment or be unexported (golint)
    • Line 173: warning: exported method CPaperImpl.Delete should have comment or be unexported (golint)
    • cckit/state/tranformer.go
    • Line 6: warning: comment on exported type FromBytesTransformer should be of the form "FromBytesTransformer ..." (with optional leading article) (golint)
    • Line 15: warning: comment on exported type StringTransformer should be of the form "StringTransformer ..." (with optional leading article) (golint)
    • Line 19: warning: exported function ConvertFromBytes should have comment or be unexported (golint)
    • Line 27: warning: exported function ConvertToBytes should have comment or be unexported (golint)
    • Line 31: warning: comment on exported function KeyAsIs should be of the form "KeyAsIs ..." (golint)
    • Line 36: warning: exported function NameAsIs should have comment or be unexported (golint)
    • cckit/state/mapping/state_mapped.go
    • Line 9: warning: exported type ProtoStateMapped should have comment or be unexported (golint)
    • Line 17: warning: exported function NewProtoStateMapped should have comment or be unexported (golint)
    • Line 24: warning: exported method ProtoStateMapped.Key should have comment or be unexported (golint)
    • Line 33: warning: exported method ProtoStateMapped.Keys should have comment or be unexported (golint)
    • Line 37: warning: exported method ProtoStateMapped.ToBytes should have comment or be unexported (golint)
    • Line 41: warning: exported method ProtoStateMapped.Mapper should have comment or be unexported (golint)
    • cckit/testing/identity.go
    • Line 9: warning: exported type Identities should have comment or be unexported (golint)
    • Line 11: warning: exported type ReadFile should have comment or be unexported (golint)
    • Line 13: warning: exported type IdentitySample should have comment or be unexported (golint)
    • Line 18: warning: exported function MustIdentityFromPem should have comment or be unexported (golint)
    • Line 60: warning: comment on exported function MustIdentitiesFromFiles should be of the form "MustIdentitiesFromFiles ..." (golint)
    • cckit/testing/tx.go
    • Line 12: warning: exported type TxHandler should have comment or be unexported (golint)
    • Line 18: warning: exported type TxResult should have comment or be unexported (golint)
    • Line 25: warning: exported function NewTxHandler should have comment or be unexported (golint)
    • Line 40: warning: exported method TxHandler.From should have comment or be unexported (golint)
    • Line 45: warning: exported method TxHandler.Init should have comment or be unexported (golint)
    • Line 75: warning: comment on exported method TxHandler.TxFunc should be of the form "TxFunc ..." (golint)
    • Line 101: warning: exported method TxResult.Expect should have comment or be unexported (golint)
    • cckit/convert/convert.go
    • Line 18: warning: exported const TypeInt should have comment or be unexported (golint)
    • Line 19: warning: exported const TypeString should have comment or be unexported (golint)
    • Line 20: warning: exported const TypeBool should have comment or be unexported (golint)
    • cckit/gateway/service/mock/invoker.go
    • Line 13: warning: exported var InvokeErrorResponse should have comment or be unexported (golint)
    • Line 16: warning: exported function FailInvokeChaincode should have comment or be unexported (golint)
    • Line 29: warning: exported function FailChaincode should have comment or be unexported (golint)
    • cckit/identity/entry.go
    • Line 1: warning: package comment should be of the form "Package identity ..." (golint)
    • Line 54: warning: comment on exported method Entry.GetPEM should be of the form "GetPEM ..." (golint)
    • Line 59: warning: exported method Entry.GetPublicKey should have comment or be unexported (golint)
    • Line 85: warning: exported method Entry.GetIdentityEntry should have comment or be unexported (golint)
    • Line 99: warning: exported function EntryFromStub should have comment or be unexported (golint)
    • cckit/examples/erc20/erc20_ops.go
    • Line 10: warning: exported const BalancePrefix should have comment (or a comment on this block) or be unexported (golint)
    • Line 15: warning: exported var ErrNotEnoughFunds should have comment or be unexported (golint)
    • Line 21: warning: exported type Transfer should have comment or be unexported (golint)
    • Line 27: warning: exported type Approve should have comment or be unexported (golint)
    • cckit/state/mapping/event_mapped.go
    • Line 6: warning: exported type ProtoEventMapped should have comment or be unexported (golint)
    • Line 12: warning: exported function NewProtoEventMapped should have comment or be unexported (golint)
    • Line 16: warning: exported method ProtoEventMapped.Name should have comment or be unexported (golint)
    • Line 20: warning: exported method ProtoEventMapped.ToBytes should have comment or be unexported (golint)
    • cckit/state/mapping/state_mapping.go
    • Line 22: warning: comment on exported type StateMapper should be of the form "StateMapper ..." (with optional leading article) (golint)
    • Line 38: warning: exported type InstanceMultiKeyer should have comment or be unexported (golint)
    • Line 40: warning: exported type StateMapped should have comment or be unexported (golint)
    • Line 63: warning: exported type StateIndexDef should have comment or be unexported (golint)
    • Line 71: warning: exported type StateMappings should have comment or be unexported (golint)
    • Line 73: warning: exported type StateMappingOpt should have comment or be unexported (golint)
    • Line 80: warning: exported method StateMappings.Add should have comment or be unexported (golint)
    • Line 101: warning: exported function SchemaNamespace should have comment or be unexported (golint)
    • Line 120: warning: comment on exported method StateMappings.GetByNamespace should be of the form "GetByNamespace ..." (golint)
    • Line 131: warning: exported method StateMappings.Exists should have comment or be unexported (golint)
    • Line 136: warning: exported method StateMappings.PrimaryKey should have comment or be unexported (golint)
    • Line 144: warning: exported method StateMappings.Map should have comment or be unexported (golint)
    • Line 158: warning: comment on exported method StateMappings.IdxKey should be of the form "IdxKey ..." (golint)
    • Line 164: warning: exported method StateMapping.Namespace should have comment or be unexported (golint)
    • Line 168: warning: exported method StateMapping.Indexes should have comment or be unexported (golint)
    • Line 172: warning: exported method StateMapping.Schema should have comment or be unexported (golint)
    • Line 176: warning: exported method StateMapping.List should have comment or be unexported (golint)
    • Line 180: warning: exported method StateMapping.PrimaryKey should have comment or be unexported (golint)
    • Line 192: warning: comment on exported method StateMapping.Keys should be of the form "Keys ..." (golint)
    • Line 220: warning: exported method StateMapping.AddIndex should have comment or be unexported (golint)
    • Line 229: warning: exported method StateMapping.Index should have comment or be unexported (golint)
    • Line 239: warning: exported method StateMapping.KeyerFor should have comment or be unexported (golint)
    • cckit/testing/gomega/matchers/stringer.go
    • Line 10: warning: exported type StringerEqualMatcher should have comment or be unexported (golint)
    • Line 14: warning: exported type Stringer should have comment or be unexported (golint)
    • Line 18: warning: exported method StringerEqualMatcher.Match should have comment or be unexported (golint)
    • Line 35: warning: exported method StringerEqualMatcher.FailureMessage should have comment or be unexported (golint)
    • Line 45: warning: exported method StringerEqualMatcher.NegatedFailureMessage should have comment or be unexported (golint)
    • cckit/state/key.go
    • Line 24: warning: exported type Key should have comment or be unexported (golint)
    • Line 26: warning: comment on exported type TransformedKey should be of the form "TransformedKey ..." (with optional leading article) (golint)
    • Line 33: warning: comment on exported type KeyFunc should be of the form "KeyFunc ..." (with optional leading article) (golint)
    • Line 44: warning: comment on exported type StringsKeyer should be of the form "StringsKeyer ..." (with optional leading article) (golint)
    • Line 61: warning: exported method Key.Append should have comment or be unexported (golint)
    • Line 70: warning: exported function NormalizeKey should have comment or be unexported (golint)
    • Line 86: warning: exported function KeyFromComposite should have comment or be unexported (golint)
    • Line 106: warning: exported function KeyToComposite should have comment or be unexported (golint)
    • Line 115: warning: exported function KeyToString should have comment or be unexported (golint)
    • cckit/state/mapping/event.go
    • Line 11: warning: exported type EventImpl should have comment or be unexported (golint)
    • Line 17: warning: exported function NewEvent should have comment or be unexported (golint)
    • Line 24: warning: exported function WrapEvent should have comment or be unexported (golint)
    • Line 39: warning: exported method EventImpl.Set should have comment or be unexported (golint)
    • Line 51: warning: exported method EventImpl.UseNameTransformer should have comment or be unexported (golint)
    • Line 55: warning: exported method EventImpl.UseSetTransformer should have comment or be unexported (golint)
    • cckit/state/mapping/event_mapping.go
    • Line 14: warning: exported type Namer should have comment or be unexported (golint)
    • Line 16: warning: exported type EventMapping should have comment or be unexported (golint)
    • Line 21: warning: exported type EventMappings should have comment or be unexported (golint)
    • Line 23: warning: exported type EventMapped should have comment or be unexported (golint)
    • Line 27: warning: exported type EventMappers should have comment or be unexported (golint)
    • Line 33: warning: exported type EventMapper should have comment or be unexported (golint)
    • Line 38: warning: exported type EventMappingOpt should have comment or be unexported (golint)
    • Line 41: warning: exported method EventMappings.Add should have comment or be unexported (golint)
    • Line 63: warning: exported method EventMappings.Get should have comment or be unexported (golint)
    • Line 71: warning: exported method EventMappings.Exists should have comment or be unexported (golint)
    • Line 76: warning: exported method EventMappings.Map should have comment or be unexported (golint)
    • Line 90: warning: exported method EventMapping.Schema should have comment or be unexported (golint)
    • Line 94: warning: exported method EventMapping.Name should have comment or be unexported (golint)
    • cckit/extensions/encryption/event.go
    • Line 44: warning: comment on exported function StringEncryptor should be of the form "StringEncryptor ..." (golint)
    • Line 81: warning: comment on exported function DecryptEvent should be of the form "DecryptEvent ..." (golint)
    • cckit/extensions/debug/debug_state.go
    • Line 13: warning: exported type StateService should have comment or be unexported (golint)
    • Line 21: warning: exported function StateAsIs should have comment or be unexported (golint)
    • Line 25: warning: exported function NewStateService should have comment or be unexported (golint)
    • Line 31: warning: exported method StateService.StateClean should have comment or be unexported (golint)
    • Line 55: warning: exported method StateService.StateKeys should have comment or be unexported (golint)
    • Line 73: warning: exported method StateService.StateGet should have comment or be unexported (golint)
    • Line 97: warning: exported method StateService.StatePut should have comment or be unexported (golint)
    • Line 104: warning: exported method StateService.StateDelete should have comment or be unexported (golint)
    • cckit/testing/gomega/matchers/erroris.go
    • Line 10: warning: exported type ErrorIslMatcher should have comment or be unexported (golint)
    • Line 14: warning: exported method ErrorIslMatcher.Match should have comment or be unexported (golint)
    • Line 25: warning: exported method ErrorIslMatcher.FailureMessage should have comment or be unexported (golint)
    • Line 29: warning: exported method ErrorIslMatcher.NegatedFailureMessage should have comment or be unexported (golint)
    • cckit/testing/must.go
    • Line 13: warning: comment on exported function PanicIfError should be of the form "PanicIfError ..." (golint)
    • Line 28: warning: exported function MustJSONMarshal should have comment or be unexported (golint)
    • Line 41: warning: comment on exported function MustProtoTimestamp should be of the form "MustProtoTimestamp ..." (golint)
    • Line 48: warning: exported function MustConvertFromBytes should have comment or be unexported (golint)
    • cckit/gateway/service/chaincode.go
    • Line 14: warning: exported type ChaincodeEventsServer should have comment or be unexported (golint)
    • Line 22: warning: exported function New should have comment or be unexported (golint)
    • Line 26: warning: exported method ChaincodeService.Exec should have comment or be unexported (golint)
    • Line 36: warning: exported method ChaincodeService.Invoke should have comment or be unexported (golint)
    • Line 62: warning: exported method ChaincodeService.Query should have comment or be unexported (golint)
    • Line 75: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 80: warning: exported method ChaincodeService.Events should have comment or be unexported (golint)
    • cckit/testing/mockstub.go
    • Line 20: warning: exported const EventChannelBufferSize should have comment or be unexported (golint)
    • Line 31: warning: exported type StateItem should have comment or be unexported (golint)
    • Line 53: warning: exported type CreatorTransformer should have comment or be unexported (golint)
    • Line 102: warning: exported method MockStub.EventSubscription should have comment or be unexported (golint)
    • Line 216: warning: exported method MockStub.DumpStateBuffer should have comment or be unexported (golint)
    • Line 235: warning: comment on exported method MockStub.MockQuery should be of the form "MockQuery ..." (golint)
    • Line 240: warning: exported method MockStub.MockTransactionStart should have comment or be unexported (golint)
    • Line 250: warning: exported method MockStub.MockTransactionEnd should have comment or be unexported (golint)
    • Line 262: warning: comment on exported method MockStub.MockInvoke should be of the form "MockInvoke ..." (golint)
    • Line 288: warning: comment on exported method MockStub.InvokeBytes should be of the form "InvokeBytes ..." (golint)
    • Line 298: warning: exported method MockStub.Query should have comment or be unexported (golint)
    • Line 327: warning: exported method MockStub.GetTransient should have comment or be unexported (golint)
    • Line 377: warning: exported type PrivateMockStateRangeQueryIterator should have comment or be unexported (golint)
    • Line 409: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 460: warning: exported function NewPrivateMockStateRangeQueryIterator should have comment or be unexported (golint)
    • cckit/examples/cars/cars.go
    • Line 1: warning: package comment should be of the form "Package cars ..." (golint)
    • Line 12: warning: exported const CarEntity should have comment or be unexported (golint)
    • Line 13: warning: exported const CarRegisteredEvent should have comment or be unexported (golint)
    • Line 36: warning: exported function New should have comment or be unexported (golint)
    • cckit/extensions/encryption/testing.go
    • Line 44: warning: exported method MockStub.Invoke should have comment or be unexported (golint)
    • Line 66: warning: exported method MockStub.Query should have comment or be unexported (golint)
    • Line 70: warning: exported method MockStub.Init should have comment or be unexported (golint)
    • Line 78: warning: exported method MockStub.From should have comment or be unexported (golint)
    • Line 83: warning: exported method MockStub.LastEvent should have comment or be unexported (golint)
    • cckit/examples/insurance/app/data.go
    • Line 13: warning: comment on exported type ContractType should be of the form "ContractType ..." (with optional leading article) (golint)
    • Line 26: warning: comment on exported type Contract should be of the form "Contract ..." (with optional leading article) (golint)
    • Line 37: warning: comment on exported type Item should be of the form "Item ..." (with optional leading article) (golint)
    • Line 47: warning: comment on exported type Claim should be of the form "Claim ..." (with optional leading article) (golint)
    • Line 59: warning: comment on exported type ClaimStatus should be of the form "ClaimStatus ..." (with optional leading article) (golint)
    • Line 63: warning: comment on exported const ClaimStatusUnknown should be of the form "ClaimStatusUnknown ..." (golint)
    • Line 65: warning: comment on exported const ClaimStatusNew should be of the form "ClaimStatusNew ..." (golint)
    • Line 67: warning: comment on exported const ClaimStatusRejected should be of the form "ClaimStatusRejected ..." (golint)
    • Line 69: warning: comment on exported const ClaimStatusRepair should be of the form "ClaimStatusRepair ..." (golint)
    • Line 71: warning: comment on exported const ClaimStatusReimbursement should be of the form "ClaimStatusReimbursement ..." (golint)
    • Line 73: warning: comment on exported const ClaimStatusTheftConfirmed should be of the form "ClaimStatusTheftConfirmed ..." (golint)
    • Line 77: warning: exported method ClaimStatus.UnmarshalJSON should have comment or be unexported (golint)
    • Line 101: warning: exported method ClaimStatus.MarshalJSON should have comment or be unexported (golint)
    • Line 124: warning: comment on exported type User should be of the form "User ..." (with optional leading article) (golint)
    • Line 133: warning: comment on exported type RepairOrder should be of the form "RepairOrder ..." (with optional leading article) (golint)
    • Line 141: warning: exported method User.Contacts should have comment or be unexported (golint)
    • Line 170: warning: exported method Contract.Claims should have comment or be unexported (golint)
    • Line 192: warning: exported method Contract.User should have comment or be unexported (golint)
    • Line 216: warning: exported method Claim.Contract should have comment or be unexported (golint)
    • cckit/extensions/encryption/middleware_pre.go
    • Line 17: warning: comment on exported function ArgsDecrypt should be of the form "ArgsDecrypt ..." (golint)
    • Line 23: warning: exported function ArgsDecryptExcept should have comment or be unexported (golint)
    • Line 98: warning: comment on exported function EncStateContextIfKeyProvided should be of the form "EncStateContextIfKeyProvided ..." (golint)
    • cckit/gateway/client.go
    • Line 8: warning: exported type ChaincodeClient should have comment or be unexported (golint)
    • Line 12: warning: exported type ClientOpt should have comment or be unexported (golint)
    • Line 19: warning: exported function NewChaincodeClient should have comment or be unexported (golint)
    • cckit/testing/expect/tx.go
    • Line 11: warning: exported type Stringer should have comment or be unexported (golint)
    • Line 15: warning: exported type TxRes should have comment or be unexported (golint)
    • Line 22: warning: exported method TxRes.HasError should have comment or be unexported (golint)
    • Line 31: warning: exported method TxRes.HasNoError should have comment or be unexported (golint)
    • Line 35: warning: exported method TxRes.Is should have comment or be unexported (golint)
    • cckit/gateway/service/mock/chaincode.go
    • Line 16: warning: exported const MessageProtocolVersion should have comment (or a comment on this block) or be unexported (golint)
    • Line 20: warning: exported type ChaincodeService should have comment or be unexported (golint)
    • Line 32: warning: exported function New should have comment or be unexported (golint)
    • Line 46: warning: exported function DefaultInvoker should have comment or be unexported (golint)
    • Line 76: warning: exported method ChaincodeService.Exec should have comment or be unexported (golint)
    • Line 103: warning: exported method ChaincodeService.Query should have comment or be unexported (golint)
    • Line 110: warning: exported method ChaincodeService.Invoke should have comment or be unexported (golint)
    • Line 117: warning: exported method ChaincodeService.Events should have comment or be unexported (golint)
    • cckit/gateway/opt.go
    • Line 14: warning: exported type Opt should have comment or be unexported (golint)
    • Line 16: warning: exported type ContextOpt should have comment or be unexported (golint)
    • Line 17: warning: exported type InputOpt should have comment or be unexported (golint)
    • Line 18: warning: exported type OutputOpt should have comment or be unexported (golint)
    • Line 19: warning: exported type EventOpt should have comment or be unexported (golint)
    • Line 21: warning: exported function WithDefaultSigner should have comment or be unexported (golint)
    • Line 29: warning: exported function WithDefaultDoOpts should have comment or be unexported (golint)
    • Line 37: warning: exported function WithTransientValue should have comment or be unexported (golint)
    • Line 45: warning: exported function WithEncryption should have comment or be unexported (golint)
    • Line 54: warning: exported function WithArgsEncryption should have comment or be unexported (golint)
    • Line 63: warning: exported function WithInvokePayloadDecryption should have comment or be unexported (golint)
    • Line 75: warning: exported function WithEventDecryption should have comment or be unexported (golint)
    • cckit/router/router.go
    • Line 15: warning: exported type MethodType should have comment or be unexported (golint)
    • Line 35: warning: exported type HandlerMeta should have comment or be unexported (golint)
    • Line 57: warning: exported type Router should have comment or be unexported (golint)
    • Line 66: warning: exported const InitFunc should have comment (or a comment on this block) or be unexported (golint)
    • Line 151: warning: exported method Group.Pre should have comment or be unexported (golint)
    • Line 156: warning: exported method Group.After should have comment or be unexported (golint)
    • Line 215: warning: exported method Group.Init should have comment or be unexported (golint)
    • cckit/state/state.go
    • Line 105: warning: exported type Impl should have comment or be unexported (golint)
    • Line 141: warning: exported method Impl.Logger should have comment or be unexported (golint)
    • Line 145: warning: exported method Impl.Key should have comment or be unexported (golint)
    • Line 193: warning: exported method Impl.GetInt should have comment or be unexported (golint)
    • Line 302: warning: exported method Impl.Keys should have comment or be unexported (golint)
    • Line 402: warning: exported method Impl.UseKeyTransformer should have comment or be unexported (golint)
    • Line 407: warning: exported method Impl.UseKeyReverseTransformer should have comment or be unexported (golint)
    • Line 412: warning: exported method Impl.UseStateGetTransformer should have comment or be unexported (golint)
    • Line 417: warning: exported method Impl.UseStatePutTransformer should have comment or be unexported (golint)
    • Line 422: warning: comment on exported method Impl.GetPrivate should be of the form "GetPrivate ..." (golint)
    • Line 447: warning: comment on exported method Impl.ExistsPrivate should be of the form "ExistsPrivate ..." (golint)
    • Line 461: warning: comment on exported method Impl.ListPrivate should be of the form "ListPrivate ..." (golint)
    • Line 519: warning: comment on exported method Impl.PutPrivate should be of the form "PutPrivate ..." (golint)
    • Line 539: warning: comment on exported method Impl.InsertPrivate should be of the form "InsertPrivate ..." (golint)
    • Line 555: warning: comment on exported method Impl.DeletePrivate should be of the form "DeletePrivate ..." (golint)
    • cckit/examples/insurance/fixtures.go
    • Line 10: warning: comment on exported var ContractType1 should be of the form "ContractType1 ..." (golint)
    • Line 25: warning: exported var ContractType2 should have comment or be unexported (golint)
    • Line 39: warning: comment on exported var Contract1 should be of the form "Contract1 ..." (golint)
    • cckit/examples/cpaper_asservice/chaincode.go
    • Line 1: warning: don't use an underscore in package name (golint)
    • Line 12: warning: exported function CCRouter should have comment or be unexported (golint)
    • Line 24: warning: exported function NewCC should have comment or be unexported (golint)
    • Line 33: warning: exported function NewCCEncrypted should have comment or be unexported (golint)
    • cckit/state/state_cached.go
    • Line 4: warning: exported type Cached should have comment or be unexported (golint)
    • Line 10: warning: comment on exported function WithCache should be of the form "WithCache ..." (golint)
    • cckit/testing/mocked_peer.go
    • Line 17: warning: exported type ChannelMockStubs should have comment or be unexported (golint)
    • Line 19: warning: exported type ChannelsMockStubs should have comment or be unexported (golint)
    • Line 21: warning: exported type MockedPeer should have comment or be unexported (golint)
    • Line 27: warning: exported type EventSubscription should have comment or be unexported (golint)
    • Line 34: warning: comment on exported function NewPeer should be of the form "NewPeer ..." (golint)
    • Line 41: warning: exported method MockedPeer.WithChannel should have comment or be unexported (golint)
    • Line 63: warning: exported method MockedPeer.Invoke should have comment or be unexported (golint)
    • Line 82: warning: exported method MockedPeer.Query should have comment or be unexported (golint)
    • Line 99: warning: exported method MockedPeer.Subscribe should have comment or be unexported (golint)
    • Line 120: warning: exported method MockedPeer.Chaincode should have comment or be unexported (golint)
    • Line 129: warning: exported method EventSubscription.Events should have comment or be unexported (golint)
    • Line 133: warning: exported method EventSubscription.Errors should have comment or be unexported (golint)
    • Line 137: warning: exported method EventSubscription.Close should have comment or be unexported (golint)
    • cckit/extensions/owner/owner.go
    • Line 21: warning: exported function IsSetted should have comment or be unexported (golint)
    • Line 25: warning: exported function Get should have comment or be unexported (golint)
    • Line 72: warning: comment on exported function Insert should be of the form "Insert ..." (golint)
    • Line 114: warning: comment on exported function IdentityEntryFromState should be of the form "IdentityEntryFromState ..." (golint)
    • cckit/extensions/ecdh/ecdh.go
    • Line 7: warning: exported function Marshall should have comment or be unexported (golint)
    • Line 21: warning: exported function GenerateSharedSecret should have comment or be unexported (golint)
    • cckit/gateway/api.go
    • Line 11: warning: exported type RegisterHandlerFromEndpoint should have comment or be unexported (golint)
    • Line 13: warning: exported type ServiceDef should have comment or be unexported (golint)
    • cckit/gateway/chaincode.go
    • Line 11: warning: exported type Action should have comment or be unexported (golint)
    • Line 14: warning: exported const Query should have comment (or a comment on this block) or be unexported (golint)
    • Line 25: warning: exported type ChaincodeEventSub should have comment or be unexported (golint)
    • Line 43: warning: exported function NewChaincode should have comment or be unexported (golint)
    • Line 83: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 97: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • cckit/state/mapping/state_keyref.go
    • Line 16: warning: exported var KeyRefMapper should have comment or be unexported (golint)
    • Line 22: warning: exported var KeyRefIDMapper should have comment or be unexported (golint)
    • Line 28: warning: exported function NewKeyRef should have comment or be unexported (golint)
    • Line 37: warning: exported function NewKeyRefID should have comment or be unexported (golint)
    • Line 45: warning: exported function NewKeyRefMapped should have comment or be unexported (golint)
    • Line 49: warning: exported function NewKeyRefIDMapped should have comment or be unexported (golint)
    • cckit/examples/cpaper/chaincode.go
    • Line 12: warning: exported type TaskState should have comment or be unexported (golint)
    • Line 15: warning: exported const CommercialPaperTypeName should have comment (or a comment on this block) or be unexported (golint)
    • Line 22: warning: exported type CommercialPaper should have comment or be unexported (golint)
    • Line 32: warning: comment on exported method CommercialPaper.Key should be of the form "Key ..." (golint)
    • Line 37: warning: exported type IssueCommercialPaper should have comment or be unexported (golint)
    • Line 45: warning: exported type BuyCommercialPaper should have comment or be unexported (golint)
    • Line 54: warning: exported type RedeemCommercialPaper should have comment or be unexported (golint)
    • Line 61: warning: exported function NewCC should have comment or be unexported (golint)
    • cckit/state/event.go
    • Line 16: warning: exported type Namer should have comment or be unexported (golint)
    • Line 25: warning: exported type EventImpl should have comment or be unexported (golint)
    • Line 41: warning: exported method EventImpl.UseSetTransformer should have comment or be unexported (golint)
    • Line 46: warning: exported method EventImpl.UseNameTransformer should have comment or be unexported (golint)
    • Line 51: warning: exported method EventImpl.Set should have comment or be unexported (golint)
    • Line 70: warning: exported method EventImpl.ArgNameValue should have comment or be unexported (golint)
    • Line 88: warning: exported function NormalizeEventName should have comment or be unexported (golint)
    • cckit/examples/private_cars/cars.go
    • Line 1: warning: package comment should be of the form "Package cars ..." (golint)
    • Line 12: warning: exported const CarEntity should have comment or be unexported (golint)
    • Line 13: warning: exported const CarRegisteredEvent should have comment or be unexported (golint)
    • Line 36: warning: exported function New should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign97%

IneffAssign detects ineffectual assignments in Go code.


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!