Preparing report...

Report for github.com/go-eagle/eagle

A+    Excellent!    Found 43 issues across 246 files

Tweet

gofmt99%

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!


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.


golint82%

Golint is a linter for Go source code.

    • eagle/pkg/app/response.go
    • Line 11: warning: exported type Response should have comment or be unexported (golint)
    • Line 18: warning: exported function NewResponse should have comment or be unexported (golint)
    • Line 22: warning: exported method Response.Success should have comment or be unexported (golint)
    • eagle/pkg/queue/rabbitmq/channel.go
    • Line 5: warning: exported type Channel should have comment or be unexported (golint)
    • Line 9: warning: exported function NewChannel should have comment or be unexported (golint)
    • Line 13: warning: exported method Channel.Create should have comment or be unexported (golint)
    • eagle/pkg/queue/kafka/consumer.go
    • Line 12: warning: exported type Consumer should have comment or be unexported (golint)
    • Line 18: warning: exported function NewConsumer should have comment or be unexported (golint)
    • Line 45: warning: exported method Consumer.Consume should have comment or be unexported (golint)
    • Line 65: warning: exported method Consumer.CloseConnection should have comment or be unexported (golint)
    • eagle/pkg/app/app.go
    • Line 18: warning: exported type App should have comment or be unexported (golint)
    • Line 26: warning: exported function New should have comment or be unexported (golint)
    • eagle/pkg/transport/http/server.go
    • Line 13: warning: exported type Server should have comment or be unexported (golint)
    • Line 22: warning: exported function NewServer should have comment or be unexported (golint)
    • Line 44: warning: exported method Server.Start should have comment or be unexported (golint)
    • Line 57: warning: exported method Server.Stop should have comment or be unexported (golint)
    • eagle/internal/service/user_service.go
    • Line 121: warning: comment on exported method Service.GetUserStatByID should be of the form "GetUserStatByID ..." (golint)
    • Line 239: warning: exported method Service.GetUserByPhone should have comment or be unexported (golint)
    • Line 248: warning: exported method Service.GetUserByEmail should have comment or be unexported (golint)
    • eagle/pkg/errcode/errcode.go
    • Line 17: warning: exported function NewError should have comment or be unexported (golint)
    • Line 29: warning: exported method Error.Code should have comment or be unexported (golint)
    • Line 33: warning: exported method Error.Msg should have comment or be unexported (golint)
    • Line 37: warning: exported method Error.Msgf should have comment or be unexported (golint)
    • Line 41: warning: exported method Error.Details should have comment or be unexported (golint)
    • Line 45: warning: exported method Error.WithDetails should have comment or be unexported (golint)
    • eagle/pkg/queue/rabbitmq/consumer.go
    • Line 10: warning: exported type Consumer should have comment or be unexported (golint)
    • Line 25: warning: exported function NewConsumer should have comment or be unexported (golint)
    • Line 38: warning: exported method Consumer.Start should have comment or be unexported (golint)
    • Line 48: warning: exported method Consumer.Stop should have comment or be unexported (golint)
    • Line 63: warning: exported method Consumer.Run should have comment or be unexported (golint)
    • Line 104: warning: exported method Consumer.Handle should have comment or be unexported (golint)
    • Line 124: warning: exported method Consumer.ReConnect should have comment or be unexported (golint)
    • eagle/internal/ecode/user.go
    • Line 6: warning: comment on exported var ErrUserNotFound should be of the form "ErrUserNotFound ..." (golint)
    • Line 8: warning: exported var ErrPasswordIncorrect should have comment or be unexported (golint)
    • eagle/pkg/queue/kafka/producer.go
    • Line 12: warning: exported type Producer should have comment or be unexported (golint)
    • Line 18: warning: exported function NewProducer should have comment or be unexported (golint)
    • Line 35: warning: exported method Producer.Publish should have comment or be unexported (golint)
    • eagle/pkg/trace/config.go
    • Line 19: warning: exported type Config should have comment or be unexported (golint)
    • Line 29: warning: exported method Config.Check should have comment or be unexported (golint)
    • Line 42: warning: exported method Config.GetTraceConfig should have comment or be unexported (golint)
    • eagle/pkg/trace/trace.go
    • Line 19: warning: exported type Trace should have comment or be unexported (golint)
    • Line 26: warning: exported function Init should have comment or be unexported (golint)
    • eagle/pkg/log/logger.go
    • Line 20: warning: comment on exported type Config should be of the form "Config ..." (with optional leading article) (golint)
    • Line 80: warning: exported function GetLogger should have comment or be unexported (golint)
    • eagle/pkg/redis/lock.go
    • Line 29: warning: exported type Option should have comment or be unexported (golint)
    • Line 31: warning: exported function WithTimeout should have comment or be unexported (golint)
    • eagle/pkg/redis/redis_cmd.go
    • Line 1: warning: package comment should be of the form "Package redis ..." (golint)
    • Line 14: warning: exported function String should have comment or be unexported (golint)
    • Line 18: warning: exported function Bytes should have comment or be unexported (golint)
    • Line 22: warning: exported function CmdString should have comment or be unexported (golint)
    • Line 28: warning: exported function CmdsString should have comment or be unexported (golint)
    • Line 62: warning: exported function AppendCmd should have comment or be unexported (golint)
    • eagle/pkg/cache/getter.go
    • Line 3: warning: exported type Getter should have comment or be unexported (golint)
    • Line 7: warning: exported type GetFunc should have comment or be unexported (golint)
    • Line 9: warning: exported method GetFunc.Get should have comment or be unexported (golint)
    • eagle/pkg/queue/rabbitmq/queue.go
    • Line 5: warning: exported type Queue should have comment or be unexported (golint)
    • Line 10: warning: exported function NewQueue should have comment or be unexported (golint)
    • Line 14: warning: exported method Queue.Create should have comment or be unexported (golint)
    • eagle/pkg/app/form.go
    • Line 11: warning: exported type ValidError should have comment or be unexported (golint)
    • Line 16: warning: exported type ValidErrors should have comment or be unexported (golint)
    • Line 26: warning: exported method ValidErrors.Errors should have comment or be unexported (golint)
    • Line 35: warning: exported function BindAndValid should have comment or be unexported (golint)
    • eagle/pkg/app/options.go
    • Line 50: warning: comment on exported function WithContext should be of the form "WithContext ..." (golint)
    • Line 71: warning: exported function Server should have comment or be unexported (golint)
    • eagle/internal/dao/user_follow_dao.go
    • Line 14: warning: exported method Dao.CreateUserFollow should have comment or be unexported (golint)
    • Line 19: warning: exported method Dao.CreateUserFans should have comment or be unexported (golint)
    • Line 24: warning: exported method Dao.UpdateUserFollowStatus should have comment or be unexported (golint)
    • Line 30: warning: exported method Dao.UpdateUserFansStatus should have comment or be unexported (golint)
    • Line 36: warning: exported method Dao.GetFollowingUserList should have comment or be unexported (golint)
    • eagle/pkg/cache/cache.go
    • Line 19: warning: exported var ErrPlaceholder should have comment or be unexported (golint)
    • Line 61: warning: exported function SetCacheWithNotFound should have comment or be unexported (golint)
    • eagle/pkg/queue/rabbitmq/producer.go
    • Line 11: warning: exported type Producer should have comment or be unexported (golint)
    • Line 22: warning: exported function NewProducer should have comment or be unexported (golint)
    • Line 33: warning: exported method Producer.Start should have comment or be unexported (golint)
    • Line 42: warning: exported method Producer.Stop should have comment or be unexported (golint)
    • Line 52: warning: exported method Producer.Run should have comment or be unexported (golint)
    • Line 69: warning: exported method Producer.ReConnect should have comment or be unexported (golint)
    • Line 121: warning: exported method Producer.Publish 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!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!