Preparing report...

Report for github.com/abulo/ratel/v2

(v2.0.13)

A+    Excellent!    Found 77 issues across 206 files

Tweet

gofmt97%

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!


gocyclo93%

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.

    • ratel/v2/gin/tree.go
    • Line 423: warning: cyclomatic complexity 56 of function (*node).getValue() is high (> 15) (gocyclo)
    • Line 699: warning: cyclomatic complexity 48 of function (*node).findCaseInsensitivePathRec() is high (> 15) (gocyclo)
    • Line 153: warning: cyclomatic complexity 22 of function (*node).addRoute() is high (> 15) (gocyclo)
    • ratel/v2/config/read.go
    • Line 119: warning: cyclomatic complexity 27 of function (*Config).GetValue() is high (> 15) (gocyclo)
    • Line 20: warning: cyclomatic complexity 26 of function (*Config).Exists() is high (> 15) (gocyclo)
    • Line 508: warning: cyclomatic complexity 19 of function (*Config).StringMap() is high (> 15) (gocyclo)
    • ratel/v2/util/util.go
    • Line 2202: warning: cyclomatic complexity 75 of function VersionCompare() is high (> 15) (gocyclo)
    • Line 400: warning: cyclomatic complexity 39 of function ParseStr() is high (> 15) (gocyclo)
    • Line 1874: warning: cyclomatic complexity 31 of function IsNumeric() is high (> 15) (gocyclo)
    • Line 2991: warning: cyclomatic complexity 26 of function ToUintE() is high (> 15) (gocyclo)
    • Line 3195: warning: cyclomatic complexity 26 of function ToUint16E() is high (> 15) (gocyclo)
    • Line 3263: warning: cyclomatic complexity 26 of function ToUint8E() is high (> 15) (gocyclo)
    • Line 3127: warning: cyclomatic complexity 26 of function ToUint32E() is high (> 15) (gocyclo)
    • Line 3059: warning: cyclomatic complexity 26 of function ToUint64E() is high (> 15) (gocyclo)
    • Line 3370: warning: cyclomatic complexity 25 of function ToStringE() is high (> 15) (gocyclo)
    • Line 3456: warning: cyclomatic complexity 23 of function ToStringMapStringSliceE() is high (> 15) (gocyclo)
    • Line 2897: warning: cyclomatic complexity 19 of function ToInt8E() is high (> 15) (gocyclo)
    • Line 2803: warning: cyclomatic complexity 19 of function ToInt32E() is high (> 15) (gocyclo)
    • Line 2756: warning: cyclomatic complexity 19 of function ToInt64E() is high (> 15) (gocyclo)
    • Line 2944: warning: cyclomatic complexity 19 of function ToIntE() is high (> 15) (gocyclo)
    • Line 2850: warning: cyclomatic complexity 19 of function ToInt16E() is high (> 15) (gocyclo)
    • Line 1973: warning: cyclomatic complexity 18 of function System() is high (> 15) (gocyclo)
    • Line 2666: warning: cyclomatic complexity 18 of function ToFloat64E() is high (> 15) (gocyclo)
    • Line 2711: warning: cyclomatic complexity 18 of function ToFloat32E() is high (> 15) (gocyclo)
    • Line 615: warning: cyclomatic complexity 17 of function Wordwrap() is high (> 15) (gocyclo)
    • Line 4457: warning: cyclomatic complexity 16 of function ExtractIP() is high (> 15) (gocyclo)
    • ratel/v2/crontab/parser.go
    • Line 252: warning: cyclomatic complexity 18 of function getRange() is high (> 15) (gocyclo)
    • Line 160: warning: cyclomatic complexity 16 of function normalizeFields() is high (> 15) (gocyclo)

golint68%

Golint is a linter for Go source code.

    • ratel/v2/session/driver.go
    • Line 12: warning: exported type Session should have comment or be unexported (golint)
    • Line 18: warning: comment on exported method Session.Put should be of the form "Put ..." (golint)
    • Line 21: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
    • Line 58: warning: comment on exported method Session.Get should be of the form "Get ..." (golint)
    • Line 59: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
    • Line 79: warning: exported method Session.Remove should have comment or be unexported (golint)
    • Line 79: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
    • Line 166: warning: comment on exported method Session.Destroy should be of the form "Destroy ..." (golint)
    • Line 177: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
    • ratel/v2/crontab/cron.go
    • Line 129: warning: exported method FuncJob.Run should have comment or be unexported (golint)
    • Line 207: warning: exported method Cron.Len should have comment or be unexported (golint)
    • Line 211: warning: exported method Cron.WorkerStart should have comment or be unexported (golint)
    • Line 216: warning: exported method Cron.WorkerStop should have comment or be unexported (golint)
    • ratel/v2/config/write.go
    • Line 13: warning: error var readonlyErr should have name of the form errFoo (golint)
    • Line 14: warning: error var keyIsEmptyErr should have name of the form errFoo (golint)
    • ratel/v2/store/proxy/kafka.go
    • Line 7: warning: exported type ProxyKafka should have comment or be unexported (golint)
    • Line 21: warning: comment on exported method ProxyPool.StoreKafka should be of the form "StoreKafka ..." (golint)
    • Line 26: warning: comment on exported method ProxyPool.LoadKafka should be of the form "LoadKafka ..." (golint)
    • ratel/v2/store/proxy/kylin.go
    • Line 7: warning: exported type ProxyKylin should have comment or be unexported (golint)
    • Line 21: warning: comment on exported method ProxyPool.StoreKylin should be of the form "StoreKylin ..." (golint)
    • Line 26: warning: comment on exported method ProxyPool.LoadKylin should be of the form "LoadKylin ..." (golint)
    • ratel/v2/trace/hook_es.go
    • Line 13: warning: exported const MaxContentLength should have comment or be unexported (golint)
    • Line 17: warning: exported type ESTracedTransport should have comment or be unexported (golint)
    • Line 21: warning: exported method ESTracedTransport.RoundTrip should have comment or be unexported (golint)
    • Line 65: warning: exported function ESTraceServerInterceptor should have comment or be unexported (golint)
    • ratel/v2/crontab/parser.go
    • Line 11: warning: comment on exported type ParseOption should be of the form "ParseOption ..." (with optional leading article) (golint)
    • Line 18: warning: exported const Second should have comment (or a comment on this block) or be unexported (golint)
    • Line 47: warning: comment on exported type Parser should be of the form "Parser ..." (with optional leading article) (golint)
    • ratel/v2/wx/wechat.go
    • Line 24: warning: exported function NewClient should have comment or be unexported (golint)
    • Line 78: warning: comment on exported method Client.OpenPlatform should be of the form "OpenPlatform ..." (golint)
    • ratel/v2/metric/metric.go
    • Line 15: warning: exported var TypeGorm should have comment or be unexported (golint)
    • Line 24: warning: comment on exported var CodeJobSuccess should be of the form "CodeJobSuccess ..." (golint)
    • Line 31: warning: comment on exported var CodeCacheMiss should be of the form "CodeCacheMiss ..." (golint)
    • Line 36: warning: comment on exported var DefaultNamespace should be of the form "DefaultNamespace ..." (golint)
    • Line 83: warning: exported var LibHandleHistogram should have comment or be unexported (golint)
    • ratel/v2/store/query/query.go
    • Line 15: warning: exported const BETWEEN should have comment (or a comment on this block) or be unexported (golint)
    • Line 249: warning: exported method QueryBuilder.InnerJoin should have comment or be unexported (golint)
    • Line 371: warning: receiver name b should be consistent with previous receiver name query for QueryBuilder (golint)
    • Line 495: warning: exported method QueryBuilder.IsZero should have comment or be unexported (golint)
    • ratel/v2/rabbitmq/receiver.go
    • Line 9: warning: exported type RecvHander should have comment or be unexported (golint)
    • Line 11: warning: exported method RabbitMQClient.Consume should have comment or be unexported (golint)
    • ratel/v2/store/redis/options.go
    • Line 129: warning: comment on exported type RWType should be of the form "RWType ..." (with optional leading article) (golint)
    • Line 146: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • ratel/v2/util/util.go
    • Line 34: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 144: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 1468: warning: comment on exported function MultiArray should be of the form "MultiArray ..." (golint)
    • Line 2445: warning: exported function StrToInt64 should have comment or be unexported (golint)
    • Line 2453: warning: exported function UnixTimeFormatDate should have comment or be unexported (golint)
    • Line 2457: warning: exported function FormatDateTime should have comment or be unexported (golint)
    • Line 2464: warning: exported function FormatDate should have comment or be unexported (golint)
    • Line 2498: warning: exported function InterfaceToString should have comment or be unexported (golint)
    • Line 2505: warning: comment on exported function SplitString should be of the form "SplitString ..." (golint)
    • Line 2541: warning: exported function ArrayPluck should have comment or be unexported (golint)
    • Line 2567: warning: exported function ArrayKeyPluck should have comment or be unexported (golint)
    • Line 2575: warning: exported function ArrayMultiPluck should have comment or be unexported (golint)
    • Line 3987: warning: exported function AryMapStringToAryMapInterface should have comment or be unexported (golint)
    • Line 3995: warning: exported function MapStringToMapInterface should have comment or be unexported (golint)
    • Line 4004: warning: exported function AryMapInterfaceToAryMapString should have comment or be unexported (golint)
    • Line 4012: warning: exported function MapInterfaceToMapString should have comment or be unexported (golint)
    • Line 4021: warning: exported function ArgStringToAryInterface should have comment or be unexported (golint)
    • Line 4029: warning: exported function AryInterfaceToArgString should have comment or be unexported (golint)
    • Line 4037: warning: comment on exported function Divide should be of the form "Divide ..." (golint)
    • Line 4046: warning: exported function Add should have comment or be unexported (golint)
    • Line 4113: warning: exported function FromYearWeek should have comment or be unexported (golint)
    • Line 4153: warning: comment on exported function PrevMonthDate should be of the form "PrevMonthDate ..." (golint)
    • Line 4251: warning: comment on exported function Hour should be of the form "Hour ..." (golint)
    • Line 4331: warning: exported function ToWeekDay should have comment or be unexported (golint)
    • Line 4351: warning: don't use underscores in Go names; var which_week should be whichWeek (golint)
    • Line 4362: warning: exported function MarshalHTML should have comment or be unexported (golint)
    • Line 4367: warning: exported function MarshalJS should have comment or be unexported (golint)
    • Line 4372: warning: exported function JS should have comment or be unexported (golint)
    • Line 4376: warning: exported function Static should have comment or be unexported (golint)
    • Line 4380: warning: exported function DomainStatic should have comment or be unexported (golint)
    • Line 4384: warning: exported function UnescapeString should have comment or be unexported (golint)
    • Line 4558: warning: exported function GetMissingElement should have comment or be unexported (golint)
    • Line 4597: warning: exported function NewReplacer should have comment or be unexported (golint)
    • Line 4639: warning: exported function ByteReplace should have comment or be unexported (golint)
    • ratel/v2/img/img.go
    • Line 24: warning: exported const DefaultDPI should have comment (or a comment on this block) or be unexported (golint)
    • Line 27: warning: exported type Image should have comment or be unexported (golint)
    • Line 70: warning: exported method Image.SetSource should have comment or be unexported (golint)
    • Line 80: warning: comment on exported method Image.Height should be of the form "Height ..." (golint)
    • Line 313: warning: exported method Image.AddWaterMark should have comment or be unexported (golint)
    • Line 320: warning: comment on exported method Image.Compress should be of the form "Compress ..." (golint)
    • Line 450: warning: comment on exported function CalculatePt2 should be of the form "CalculatePt2 ..." (golint)
    • ratel/v2/server/server.go
    • Line 10: warning: exported type Option should have comment or be unexported (golint)
    • Line 34: warning: exported function ApplyOptions should have comment or be unexported (golint)
    • Line 42: warning: exported function WithScheme should have comment or be unexported (golint)
    • Line 48: warning: exported function WithAddress should have comment or be unexported (golint)
    • Line 54: warning: exported function WithName should have comment or be unexported (golint)
    • ratel/v2/store/proxy/redis.go
    • Line 5: warning: exported type ProxyRedis should have comment or be unexported (golint)
    • Line 19: warning: comment on exported method ProxyPool.StoreRedis should be of the form "StoreRedis ..." (golint)
    • Line 24: warning: comment on exported method ProxyPool.LoadRedis should be of the form "LoadRedis ..." (golint)
    • ratel/v2/store/query/null.go
    • Line 14: warning: exported type Nullable should have comment or be unexported (golint)
    • Line 24: warning: exported function NewString should have comment or be unexported (golint)
    • Line 28: warning: exported function NewNullString should have comment or be unexported (golint)
    • Line 32: warning: exported method NullString.MarshalJSON should have comment or be unexported (golint)
    • Line 39: warning: exported method NullString.UnmarshalJSON should have comment or be unexported (golint)
    • Line 51: warning: exported method NullString.IsEmpty should have comment or be unexported (golint)
    • Line 55: warning: exported method NullString.IsValid should have comment or be unexported (golint)
    • Line 59: warning: exported method NullString.Result should have comment or be unexported (golint)
    • Line 66: warning: exported method NullString.Convert should have comment or be unexported (golint)
    • Line 66: warning: receiver name n should be consistent with previous receiver name ns for NullString (golint)
    • Line 73: warning: comment on exported type NullDateTime should be of the form "NullDateTime ..." (with optional leading article) (golint)
    • Line 78: warning: exported function NewDateTime should have comment or be unexported (golint)
    • Line 82: warning: exported function NewNullDateTime should have comment or be unexported (golint)
    • Line 86: warning: exported method NullDateTime.Scan should have comment or be unexported (golint)
    • Line 90: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 94: 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 101: warning: exported method NullDateTime.MarshalJSON should have comment or be unexported (golint)
    • Line 101: warning: receiver name ns should be consistent with previous receiver name nt for NullDateTime (golint)
    • Line 108: warning: exported method NullDateTime.UnmarshalJSON should have comment or be unexported (golint)
    • Line 108: warning: receiver name ns should be consistent with previous receiver name nt for NullDateTime (golint)
    • Line 120: warning: exported method NullDateTime.IsEmpty should have comment or be unexported (golint)
    • Line 120: warning: receiver name ns should be consistent with previous receiver name nt for NullDateTime (golint)
    • Line 124: warning: exported method NullDateTime.IsValid should have comment or be unexported (golint)
    • Line 124: warning: receiver name ns should be consistent with previous receiver name nt for NullDateTime (golint)
    • Line 128: warning: exported method NullDateTime.Result should have comment or be unexported (golint)
    • Line 128: warning: receiver name ns should be consistent with previous receiver name nt for NullDateTime (golint)
    • Line 135: warning: exported type NullInt64 should have comment or be unexported (golint)
    • Line 137: warning: exported function NewInt64 should have comment or be unexported (golint)
    • Line 141: warning: exported function NewNullInt64 should have comment or be unexported (golint)
    • Line 145: warning: exported method NullInt64.MarshalJSON should have comment or be unexported (golint)
    • Line 152: warning: exported method NullInt64.UnmarshalJSON should have comment or be unexported (golint)
    • Line 164: warning: exported method NullInt64.IsEmpty should have comment or be unexported (golint)
    • Line 164: warning: receiver name n should be consistent with previous receiver name ni for NullInt64 (golint)
    • Line 168: warning: exported method NullInt64.IsValid should have comment or be unexported (golint)
    • Line 168: warning: receiver name n should be consistent with previous receiver name ni for NullInt64 (golint)
    • Line 172: warning: exported method NullInt64.Result should have comment or be unexported (golint)
    • Line 172: warning: receiver name ns should be consistent with previous receiver name ni for NullInt64 (golint)
    • Line 179: warning: exported method NullInt64.Convert should have comment or be unexported (golint)
    • Line 179: warning: receiver name n should be consistent with previous receiver name ni for NullInt64 (golint)
    • Line 186: warning: exported type NullInt32 should have comment or be unexported (golint)
    • Line 188: warning: exported function NewInt32 should have comment or be unexported (golint)
    • Line 192: warning: exported function NewNullInt32 should have comment or be unexported (golint)
    • Line 196: warning: exported method NullInt32.MarshalJSON should have comment or be unexported (golint)
    • Line 203: warning: exported method NullInt32.UnmarshalJSON should have comment or be unexported (golint)
    • Line 215: warning: exported method NullInt32.IsEmpty should have comment or be unexported (golint)
    • Line 215: warning: receiver name n should be consistent with previous receiver name ni for NullInt32 (golint)
    • Line 219: warning: exported method NullInt32.IsValid should have comment or be unexported (golint)
    • Line 219: warning: receiver name n should be consistent with previous receiver name ni for NullInt32 (golint)
    • Line 223: warning: exported method NullInt32.Result should have comment or be unexported (golint)
    • Line 223: warning: receiver name ns should be consistent with previous receiver name ni for NullInt32 (golint)
    • Line 230: warning: exported method NullInt32.Convert should have comment or be unexported (golint)
    • Line 230: warning: receiver name n should be consistent with previous receiver name ni for NullInt32 (golint)
    • Line 237: warning: exported type NullFloat64 should have comment or be unexported (golint)
    • Line 239: warning: exported function NewFloat64 should have comment or be unexported (golint)
    • Line 243: warning: exported function NewNullFloat64 should have comment or be unexported (golint)
    • Line 247: warning: exported method NullFloat64.MarshalJSON should have comment or be unexported (golint)
    • Line 254: warning: exported method NullFloat64.UnmarshalJSON should have comment or be unexported (golint)
    • Line 266: warning: exported method NullFloat64.IsEmpty should have comment or be unexported (golint)
    • Line 266: warning: receiver name n should be consistent with previous receiver name nf for NullFloat64 (golint)
    • Line 270: warning: exported method NullFloat64.IsValid should have comment or be unexported (golint)
    • Line 270: warning: receiver name n should be consistent with previous receiver name nf for NullFloat64 (golint)
    • Line 274: warning: exported method NullFloat64.Result should have comment or be unexported (golint)
    • Line 274: warning: receiver name ns should be consistent with previous receiver name nf for NullFloat64 (golint)
    • Line 281: warning: exported method NullFloat64.Convert should have comment or be unexported (golint)
    • Line 281: warning: receiver name n should be consistent with previous receiver name nf for NullFloat64 (golint)
    • Line 288: warning: exported type NullBool should have comment or be unexported (golint)
    • Line 290: warning: exported function NewBool should have comment or be unexported (golint)
    • Line 294: warning: exported function NewNullBool should have comment or be unexported (golint)
    • Line 298: warning: exported method NullBool.MarshalJSON should have comment or be unexported (golint)
    • Line 305: warning: exported method NullBool.UnmarshalJSON should have comment or be unexported (golint)
    • Line 317: warning: exported method NullBool.IsEmpty should have comment or be unexported (golint)
    • Line 317: warning: receiver name n should be consistent with previous receiver name nb for NullBool (golint)
    • Line 321: warning: exported method NullBool.IsValid should have comment or be unexported (golint)
    • Line 321: warning: receiver name n should be consistent with previous receiver name nb for NullBool (golint)
    • Line 325: warning: exported method NullBool.Result should have comment or be unexported (golint)
    • Line 325: warning: receiver name ns should be consistent with previous receiver name nb for NullBool (golint)
    • Line 329: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 336: warning: exported method NullBool.Convert should have comment or be unexported (golint)
    • Line 336: warning: receiver name n should be consistent with previous receiver name nb for NullBool (golint)
    • Line 340: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 352: warning: exported function NewDate should have comment or be unexported (golint)
    • Line 356: warning: exported function NewNullDate should have comment or be unexported (golint)
    • Line 360: warning: exported method NullDate.Scan should have comment or be unexported (golint)
    • Line 364: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 368: 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 375: warning: exported method NullDate.MarshalJSON should have comment or be unexported (golint)
    • Line 375: warning: receiver name ns should be consistent with previous receiver name nt for NullDate (golint)
    • Line 382: warning: exported method NullDate.UnmarshalJSON should have comment or be unexported (golint)
    • Line 382: warning: receiver name ns should be consistent with previous receiver name nt for NullDate (golint)
    • Line 394: warning: exported method NullDate.IsEmpty should have comment or be unexported (golint)
    • Line 394: warning: receiver name ns should be consistent with previous receiver name nt for NullDate (golint)
    • Line 398: warning: exported method NullDate.IsValid should have comment or be unexported (golint)
    • Line 398: warning: receiver name ns should be consistent with previous receiver name nt for NullDate (golint)
    • Line 402: warning: exported method NullDate.Result should have comment or be unexported (golint)
    • Line 402: warning: receiver name ns should be consistent with previous receiver name nt for NullDate (golint)
    • ratel/v2/rabbitmq/client.go
    • Line 10: warning: exported type RabbitMQClient should have comment or be unexported (golint)
    • Line 16: warning: exported type Config should have comment or be unexported (golint)
    • Line 24: warning: exported type SendConfig should have comment or be unexported (golint)
    • Line 29: warning: exported type RecvConfig should have comment or be unexported (golint)
    • Line 39: warning: exported function NewSendClient should have comment or be unexported (golint)
    • Line 77: warning: exported function NewRecvClient should have comment or be unexported (golint)
    • ratel/v2/goroutine/serial.go
    • Line 18: warning: comment on exported function SerialUntilError should be of the form "SerialUntilError ..." (golint)
    • Line 31: warning: comment on exported type WhenError should be of the form "WhenError ..." (with optional leading article) (golint)
    • ratel/v2/util/net.go
    • Line 26: warning: comment on exported function GetLocalMainIP should be of the form "GetLocalMainIP ..." (golint)
    • ratel/v2/config/load.go
    • Line 17: warning: exported function LoadDir should have comment or be unexported (golint)
    • Line 19: warning: comment on exported method Config.LoadDir should be of the form "LoadDir ..." (golint)
    • ratel/v2/store/query/database.go
    • Line 49: warning: exported method QueryDb.SetTrace should have comment or be unexported (golint)
    • Line 262: warning: exported method QueryTx.LastSql should have comment or be unexported (golint)
    • Line 267: warning: exported method QueryDb.LastSql should have comment or be unexported (golint)
    • Line 317: 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 325: warning: receiver name sql should be consistent with previous receiver name sqlRaw for Sql (golint)
    • ratel/v2/store/proxy/elasticsearch.go
    • Line 5: warning: exported type ProxyElasticSearch should have comment or be unexported (golint)
    • Line 19: warning: comment on exported method ProxyPool.StoreElasticSearch should be of the form "StoreElasticSearch ..." (golint)
    • Line 24: warning: comment on exported method ProxyPool.LoadElasticSearch should be of the form "LoadElasticSearch ..." (golint)
    • ratel/v2/store/proxy/hbase.go
    • Line 7: warning: exported type ProxyHbase should have comment or be unexported (golint)
    • Line 21: warning: comment on exported method ProxyPool.StoreHbase should be of the form "StoreHbase ..." (golint)
    • Line 26: warning: comment on exported method ProxyPool.LoadHbase should be of the form "LoadHbase ..." (golint)
    • ratel/v2/store/proxy/mongodb.go
    • Line 5: warning: exported type ProxyMongoDB should have comment or be unexported (golint)
    • Line 19: warning: comment on exported method ProxyPool.StoreMongoDB should be of the form "StoreMongoDB ..." (golint)
    • Line 24: warning: comment on exported method ProxyPool.LoadMongoDB should be of the form "LoadMongoDB ..." (golint)
    • ratel/v2/store/mongodb/client.go
    • Line 50: warning: exported method MongoDB.SetTrace should have comment or be unexported (golint)
    • Line 99: warning: receiver name client should be consistent with previous receiver name mongodb for MongoDB (golint)
    • Line 613: warning: exported function BeforeCreate should have comment or be unexported (golint)
    • Line 653: warning: exported function BeforeUpdate should have comment or be unexported (golint)
    • ratel/v2/store/query/grammar.go
    • Line 27: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 59: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 155: warning: exported method Grammar.Insert should have comment or be unexported (golint)
    • Line 161: warning: exported method Grammar.Replace should have comment or be unexported (golint)
    • Line 170: warning: should omit 2nd value from range; this loop is equivalent to `for kv := range ...` (golint)
    • Line 196: warning: exported method Grammar.Delete should have comment or be unexported (golint)
    • Line 221: warning: exported method Grammar.Update should have comment or be unexported (golint)
    • Line 234: warning: exported method Grammar.InsertUpdate should have comment or be unexported (golint)
    • Line 246: warning: exported method Grammar.ToSql should have comment or be unexported (golint)
    • ratel/v2/stack/stack.go
    • Line 7: warning: exported function NewStack should have comment or be unexported (golint)
    • Line 14: warning: exported type DeferStack should have comment or be unexported (golint)
    • Line 19: warning: exported method DeferStack.Push should have comment or be unexported (golint)
    • Line 25: warning: exported method DeferStack.Clean should have comment or be unexported (golint)
    • ratel/v2/server/rpc/server.go
    • Line 79: warning: exported method Server.Shutdown should have comment or be unexported (golint)
    • Line 84: warning: exported method Server.Info should have comment or be unexported (golint)
    • Line 124: warning: exported method Config.Address should have comment or be unexported (golint)
    • ratel/v2/example/main.go
    • Line 14: warning: comment on exported var Store should be of the form "Store ..." (golint)
    • Line 21: warning: exported type AdminPermission should have comment or be unexported (golint)
    • ratel/v2/store/query/error.go
    • Line 3: warning: exported type DbError should have comment or be unexported (golint)
    • Line 8: warning: exported type Epr should have comment or be unexported (golint)
    • Line 12: warning: exported function NewEpr should have comment or be unexported (golint)
    • Line 15: warning: exported method Epr.ToString should have comment or be unexported (golint)
    • Line 19: warning: exported function NewDBError should have comment or be unexported (golint)
    • ratel/v2/store/redis/hook.go
    • Line 17: warning: exported type OpenTelemetryHook should have comment or be unexported (golint)
    • Line 21: warning: exported method OpenTelemetryHook.BeforeProcess should have comment or be unexported (golint)
    • Line 40: warning: exported method OpenTelemetryHook.AfterProcess should have comment or be unexported (golint)
    • Line 51: warning: exported method OpenTelemetryHook.BeforeProcessPipeline should have comment or be unexported (golint)
    • Line 98: warning: exported function String should have comment or be unexported (golint)
    • Line 102: warning: exported method OpenTelemetryHook.AfterProcessPipeline should have comment or be unexported (golint)
    • Line 136: warning: exported function AppendArg should have comment or be unexported (golint)
    • ratel/v2/store/kafka/client.go
    • Line 27: warning: exported type Clientkafka should have comment or be unexported (golint)
    • Line 34: warning: exported type Writer should have comment or be unexported (golint)
    • Line 38: warning: exported type ClientWriter should have comment or be unexported (golint)
    • Line 42: warning: exported type Reader should have comment or be unexported (golint)
    • Line 46: warning: exported type ClientReader should have comment or be unexported (golint)
    • Line 81: warning: exported method Clientkafka.Kafka should have comment or be unexported (golint)
    • Line 89: warning: exported method Clientkafka.Host should have comment or be unexported (golint)
    • Line 185: warning: exported method ClientWriter.SendMessage should have comment or be unexported (golint)
    • Line 204: warning: exported method Clientkafka.NewReader should have comment or be unexported (golint)
    • Line 224: warning: exported method ClientReader.ReadMessage should have comment or be unexported (golint)
    • ratel/v2/watch/watch.go
    • Line 55: warning: exported type Level should have comment or be unexported (golint)
    • Line 59: warning: exported const LevelFatal should have comment (or a comment on this block) or be unexported (golint)
    • Line 68: warning: exported function Fatal should have comment or be unexported (golint)
    • Line 73: warning: exported function Fatalf should have comment or be unexported (golint)
    • Line 78: warning: exported function Error should have comment or be unexported (golint)
    • Line 82: warning: exported function Errorf should have comment or be unexported (golint)
    • Line 86: warning: exported function Warn should have comment or be unexported (golint)
    • Line 90: warning: exported function Warnf should have comment or be unexported (golint)
    • Line 94: warning: exported function Info should have comment or be unexported (golint)
    • Line 98: warning: exported function Infof should have comment or be unexported (golint)
    • Line 102: warning: exported function Debug should have comment or be unexported (golint)
    • Line 106: warning: exported function Debugf should have comment or be unexported (golint)
    • Line 110: warning: exported function SetLogLevel should have comment or be unexported (golint)
    • ratel/v2/img/fontx/font.go
    • Line 12: warning: exported type FontConfig should have comment or be unexported (golint)
    • Line 18: warning: exported type TrueTypeFont should have comment or be unexported (golint)
    • Line 33: warning: exported function NewFreeTypeContext should have comment or be unexported (golint)

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!


misspell97%

Misspell Finds commonly misspelled English words

    • ratel/v2/sysinfo/cpu/cpu.go
    • Line 9: warning: "Useage" is a misspelling of "Usage" (misspell)
    • Line 10: warning: "Useage" is a misspelling of "Usage" (misspell)
    • Line 17: warning: "useage" is a misspelling of "usage" (misspell)
    • Line 17: warning: "Useage" is a misspelling of "Usage" (misspell)
    • Line 19: warning: "useage" is a misspelling of "usage" (misspell)
    • Line 19: warning: "Useage" is a misspelling of "Usage" (misspell)
    • ratel/v2/sysinfo/disk/disk.go
    • Line 9: warning: "Useage" is a misspelling of "Usage" (misspell)
    • Line 10: warning: "Useage" is a misspelling of "Usage" (misspell)
    • Line 17: warning: "useage" is a misspelling of "usage" (misspell)
    • Line 17: warning: "Useage" is a misspelling of "Usage" (misspell)
    • ratel/v2/sysinfo/net/net.go
    • Line 5: warning: "Useage" is a misspelling of "Usage" (misspell)
    • Line 6: warning: "Useage" is a misspelling of "Usage" (misspell)
    • Line 13: warning: "Useage" is a misspelling of "Usage" (misspell)
    • Line 18: warning: "Useage" is a misspelling of "Usage" (misspell)
    • Line 20: warning: "useage" is a misspelling of "usage" (misspell)
    • Line 20: warning: "Useage" is a misspelling of "Usage" (misspell)
    • Line 21: warning: "useage" is a misspelling of "usage" (misspell)