Preparing report...

Report for github.com/jim3ma/gota

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


golint50%

Golint is a linter for Go source code.

    • gota/conn_test.go
    • Line 70: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • gota/meta.go
    • Line 25: warning: exported type GotaFrame should have comment or be unexported (golint)
    • Line 130: warning: exported const MaxDataLength should have comment or be unexported (golint)
    • Line 131: warning: exported const MaxConnID should have comment or be unexported (golint)
    • Line 132: warning: exported const ControlFlagBit should have comment or be unexported (golint)
    • Line 133: warning: exported const FastOpenInitSeqNum should have comment or be unexported (golint)
    • Line 134: warning: exported const FastOpenDelayNanosecond should have comment or be unexported (golint)
    • Line 136: warning: comment on exported const TMHeartBeatSecond should be of the form "TMHeartBeatSecond ..." (golint)
    • Line 138: warning: exported const TMHeartBeatTickerSecond should have comment or be unexported (golint)
    • Line 139: warning: exported const TMHeartBeatTimeOutSecond should have comment or be unexported (golint)
    • Line 140: warning: exported const TMStatReportSecond should have comment or be unexported (golint)
    • Line 143: warning: exported const TMControlStartSeq should have comment (or a comment on this block) or be unexported (golint)
    • Line 162: warning: comment on exported const TMWithoutPayloadBoundary should be of the form "TMWithoutPayloadBoundary ..." (golint)
    • Line 170: warning: exported const TMConnBiuniqueMode should have comment (or a comment on this block) or be unexported (golint)
    • Line 176: warning: exported var TMHeartBeatPingBytes should have comment or be unexported (golint)
    • Line 177: warning: exported var TMHeartBeatPingGotaFrame should have comment or be unexported (golint)
    • Line 178: warning: exported var TMHeartBeatPongBytes should have comment or be unexported (golint)
    • Line 179: warning: exported var TMHeartBeatPongGotaFrame should have comment or be unexported (golint)
    • Line 180: warning: exported var TMCloseTunnelBytes should have comment or be unexported (golint)
    • Line 181: warning: exported var TMCloseTunnelGotaFrame should have comment or be unexported (golint)
    • Line 182: warning: exported var TMCloseTunnelOKBytes should have comment or be unexported (golint)
    • Line 183: warning: exported var TMCloseTunnelOKGotaFrame should have comment or be unexported (golint)
    • Line 184: warning: exported var TMTunnelAuthOKBytes should have comment or be unexported (golint)
    • Line 185: warning: exported var TMTunnelAuthOKGotaFrame should have comment or be unexported (golint)
    • Line 186: warning: exported var TMTunnelAuthErrBytes should have comment or be unexported (golint)
    • Line 187: warning: exported var TMTunnelAuthErrGotaFrame should have comment or be unexported (golint)
    • Line 189: warning: exported var TMControlSignalMap should have comment or be unexported (golint)
    • Line 191: warning: exported const HeaderLength should have comment or be unexported (golint)
    • Line 193: warning: error var HeaderOnly should have name of the form ErrFoo (golint)
    • Line 193: warning: exported var HeaderOnly should have comment or be unexported (golint)
    • Line 194: warning: exported var ErrInsufficientData should have comment or be unexported (golint)
    • Line 195: warning: exported var ErrUnmatchedDataLength should have comment or be unexported (golint)
    • Line 197: warning: exported function WrapGotaFrame should have comment or be unexported (golint)
    • Line 202: warning: exported function UnwrapGotaFrame should have comment or be unexported (golint)
    • Line 208: warning: exported function ReadGotaFrame should have comment or be unexported (golint)
    • Line 237: warning: exported function EmbedClientIDHeaderToPayload should have comment or be unexported (golint)
    • Line 249: warning: exported function ParseClientIDHeaderFromPayload should have comment or be unexported (golint)
    • gota/misc.go
    • Line 17: warning: exported type ByteSize should have comment or be unexported (golint)
    • Line 21: warning: exported const KB should have comment (or a comment on this block) or be unexported (golint)
    • Line 68: warning: exported function NewStatistic should have comment or be unexported (golint)
    • Line 166: warning: exported var ErrNoMoreBytes should have comment or be unexported (golint)
    • Line 238: warning: exported function NewBasicAuthGotaFrame should have comment or be unexported (golint)
    • Line 251: warning: exported function SetLogLevel should have comment or be unexported (golint)
    • Line 270: warning: exported function ShutdownGota should have comment or be unexported (golint)
    • gota/proxy.go
    • Line 25: warning: exported var TLSConfig should have comment or be unexported (golint)
    • Line 108: warning: exported function FromURL should have comment or be unexported (golint)
    • Line 112: warning: exported function FromEnvironment should have comment or be unexported (golint)
    • gota/gota/cmd/client.go
    • Line 18: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 22: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • gota/conn.go
    • Line 107: warning: exported method ConnManager.EnableFastOpen should have comment or be unexported (golint)
    • Line 111: warning: exported method ConnManager.SetConnPool should have comment or be unexported (golint)
    • Line 517: warning: exported type ConnHandler should have comment or be unexported (golint)
    • Line 779: warning: exported const DefaultConnCount should have comment or be unexported (golint)
    • Line 780: warning: exported const DefaultConnAliveSecond should have comment or be unexported (golint)
    • Line 782: warning: exported type ConnPool should have comment or be unexported (golint)
    • Line 797: warning: exported function NewConnPool should have comment or be unexported (golint)
    • Line 822: warning: exported method ConnPool.Start should have comment or be unexported (golint)
    • Line 829: warning: exported method ConnPool.Stop should have comment or be unexported (golint)
    • Line 833: warning: exported method ConnPool.Fetch should have comment or be unexported (golint)
    • Line 934: warning: exported const CHMaxRetryTimes should have comment or be unexported (golint)
    • gota/debug.go
    • Line 39: warning: comment on exported function GoFileNameFull should be of the form "GoFileNameFull ..." (golint)
    • Line 57: warning: exported function Recover should have comment or be unexported (golint)
    • Line 64: warning: exported function SetVerbose should have comment or be unexported (golint)
    • Line 68: warning: exported function IsVerbose should have comment or be unexported (golint)
    • Line 72: warning: exported function Verbosef should have comment or be unexported (golint)
    • Line 88: warning: exported function DumpStacks should have comment or be unexported (golint)
    • gota/gota.go
    • Line 4: warning: exported var Version should have comment or be unexported (golint)
    • gota/tunnel.go
    • Line 18: warning: exported type TunnelAuthCredential should have comment or be unexported (golint)
    • Line 23: warning: exported type TunnelActiveConfig should have comment or be unexported (golint)
    • Line 29: warning: exported type TunnelPassiveConfig should have comment or be unexported (golint)
    • Line 33: warning: exported type ClientID should have comment or be unexported (golint)
    • Line 35: warning: exported type TunnelManager should have comment or be unexported (golint)
    • Line 106: warning: exported function TMAuth should have comment or be unexported (golint)
    • Line 113: warning: exported method TunnelManager.Mode should have comment or be unexported (golint)
    • Line 117: warning: exported method TunnelManager.SetConfig should have comment or be unexported (golint)
    • Line 144: warning: exported method TunnelManager.SetWhiteIPs should have comment or be unexported (golint)
    • Line 152: warning: exported method TunnelManager.SetCCIDChannel should have comment or be unexported (golint)
    • Line 158: warning: exported method TunnelManager.SetClientID should have comment or be unexported (golint)
    • Line 164: warning: exported method TunnelManager.Start should have comment or be unexported (golint)
    • Line 176: warning: exported method TunnelManager.Stop should have comment or be unexported (golint)
    • Line 568: warning: exported type TunnelTransport should have comment or be unexported (golint)
    • Line 600: warning: exported function NewTunnelTransport should have comment or be unexported (golint)
    • Line 638: warning: exported method TunnelTransport.SetCCIDChannel should have comment or be unexported (golint)
    • Line 908: warning: exported method TunnelTransport.Stopped should have comment or be unexported (golint)
    • Line 913: warning: exported const ActiveMode should have comment (or a comment on this block) or be unexported (golint)
    • Line 919: warning: error var TMErrUnsupportedConfig should have name of the form ErrFoo (golint)
    • Line 919: warning: exported var TMErrUnsupportedConfig should have comment or be unexported (golint)

gocyclo100%

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.

No problems detected. Good job!


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


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!