Preparing report...

Report for github.com/hidevopsio/hiboot

A    Great!    Found 96 issues across 301 files

Tweet

gofmt73%

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!


gocyclo96%

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.

    • hiboot/pkg/app/web/handler.go
    • Line 273: warning: cyclomatic complexity 21 of function (*handler).responseData() is high (> 15) (gocyclo)
    • Line 132: warning: cyclomatic complexity 20 of function (*handler).parseMethod() is high (> 15) (gocyclo)
    • Line 365: warning: cyclomatic complexity 17 of function (*handler).call() is high (> 15) (gocyclo)

golint85%

Golint is a linter for Go source code.

    • hiboot/pkg/app/web/server/property.go
    • Line 7: warning: comment on exported const Host should be of the form "Host ..." (golint)
    • Line 10: warning: comment on exported const Port should be of the form "Port ..." (golint)
    • Line 13: warning: comment on exported const Schemes should be of the form "Schemes ..." (golint)
    • hiboot/pkg/at/application.go
    • Line 3: warning: comment on exported type HiBootApplication should be of the form "HiBootApplication ..." (with optional leading article) (golint)
    • hiboot/pkg/inject/annotation/annotation.go
    • Line 1: warning: package comment should be of the form "Package annotation ..." (golint)
    • Line 30: warning: comment on exported type Field should be of the form "Field ..." (with optional leading article) (golint)
    • Line 36: warning: exported type Annotation should have comment or be unexported (golint)
    • Line 41: warning: exported type Annotations should have comment or be unexported (golint)
    • Line 46: warning: exported function IsAnnotation should have comment or be unexported (golint)
    • Line 167: warning: comment on exported function FilterIn should be of the form "FilterIn ..." (golint)
    • Line 208: warning: comment on exported function FindAll should be of the form "FindAll ..." (golint)
    • hiboot/pkg/starter/swagger/info_builder.go
    • Line 23: warning: exported type ApiInfoBuilderInterface should have comment or be unexported (golint)
    • Line 40: warning: exported type Contact should have comment or be unexported (golint)
    • Line 46: warning: exported type License should have comment or be unexported (golint)
    • Line 59: warning: exported function ApiInfoBuilder should have comment or be unexported (golint)
    • hiboot/pkg/utils/crypto/rsa/rsa.go
    • Line 34: warning: error var publicKeyError should have name of the form errFoo (golint)
    • Line 35: warning: error var privateKeyError should have name of the form errFoo (golint)
    • Line 36: warning: error var parametersError should have name of the form errFoo (golint)
    • hiboot/examples/web/router/main.go
    • Line 42: warning: comment on exported type UserVO should be of the form "UserVO ..." (with optional leading article) (golint)
    • Line 50: warning: comment on exported type User should be of the form "User ..." (with optional leading article) (golint)
    • Line 57: warning: comment on exported type UserRequest should be of the form "UserRequest ..." (with optional leading article) (golint)
    • Line 63: warning: comment on exported type UserResponse should be of the form "UserResponse ..." (with optional leading article) (golint)
    • Line 73: warning: comment on exported method UserController.CreateUser should be of the form "CreateUser ..." (golint)
    • Line 90: warning: comment on exported method UserController.GetUserByPathVariable should be of the form "GetUserByPathVariable ..." (golint)
    • Line 107: warning: comment on exported method UserController.Patch should be of the form "Patch ..." (golint)
    • Line 116: warning: comment on exported method UserController.DeleteUser should be of the form "DeleteUser ..." (golint)
    • Line 124: warning: comment on exported method UserController.ListUser should be of the form "ListUser ..." (golint)
    • hiboot/pkg/app/web/dispatcher.go
    • Line 51: warning: exported const Any should have comment (or a comment on this block) or be unexported (golint)
    • Line 57: warning: exported type Dispatcher should have comment or be unexported (golint)
    • Line 93: warning: exported type Annotations should have comment or be unexported (golint)
    • hiboot/pkg/model/response.go
    • Line 19: warning: comment on exported type ResponseInfo should be of the form "ResponseInfo ..." (with optional leading article) (golint)
    • Line 31: warning: exported type Response should have comment or be unexported (golint)
    • hiboot/pkg/at/swagger.go
    • Line 32: warning: comment on exported type Tags should be of the form "Tags ..." (with optional leading article) (golint)
    • Line 41: warning: comment on exported type ExternalDocs should be of the form "ExternalDocs ..." (with optional leading article) (golint)
    • Line 51: warning: comment on exported type Parameter should be of the form "Parameter ..." (with optional leading article) (golint)
    • hiboot/pkg/starter/jaeger/span.go
    • Line 19: warning: comment on exported type ChildSpan should be of the form "ChildSpan ..." (with optional leading article) (golint)
    • Line 23: warning: exported method Span.Inject should have comment or be unexported (golint)
    • Line 40: warning: exported method ChildSpan.Inject should have comment or be unexported (golint)
    • hiboot/pkg/utils/mapstruct/mapstruct.go
    • Line 27: warning: exported function WithAnnotation should have comment or be unexported (golint)
    • Line 31: warning: exported function WithSquash should have comment or be unexported (golint)
    • Line 35: warning: exported function WithWeaklyTypedInput should have comment or be unexported (golint)
    • Line 63: warning: comment on exported function DecodeStructToMap should be of the form "DecodeStructToMap ..." (golint)
    • hiboot/examples/web/middleware/controller/controller.go
    • Line 10: warning: exported type UserController should have comment or be unexported (golint)
    • Line 24: warning: exported type User should have comment or be unexported (golint)
    • Line 30: warning: exported type UserResponse should have comment or be unexported (golint)
    • Line 36: warning: comment on exported method UserController.GetUser should be of the form "GetUser ..." (golint)
    • Line 47: warning: comment on exported method UserController.DeleteUser should be of the form "DeleteUser ..." (golint)
    • hiboot/pkg/starter/grpc/health.go
    • Line 10: warning: comment on exported type HealthCheckService should be of the form "HealthCheckService ..." (with optional leading article) (golint)
    • Line 24: warning: comment on exported method HealthCheckService.Name should be of the form "Name ..." (golint)
    • hiboot/examples/web/swagger/simple-server/main.go
    • Line 18: warning: exported type Asset should have comment or be unexported (golint)
    • Line 26: warning: exported type Manager should have comment or be unexported (golint)
    • Line 31: warning: exported type Employee should have comment or be unexported (golint)
    • Line 39: warning: exported type ResponseInfo should have comment or be unexported (golint)
    • Line 45: warning: exported type UpdateEmployeeRequest should have comment or be unexported (golint)
    • Line 51: warning: exported type CreateEmployeeRequest should have comment or be unexported (golint)
    • Line 57: warning: exported type EmployeeResponse should have comment or be unexported (golint)
    • Line 65: warning: exported type ListEmployeeResponse should have comment or be unexported (golint)
    • Line 99: warning: context.Context should be the first parameter of a function (golint)
    • Line 106: warning: exported type Foo should have comment or be unexported (golint)
    • Line 116: warning: exported type Bar should have comment or be unexported (golint)
    • Line 355: warning: context.Context should be the first parameter of a function (golint)
    • Line 381: warning: context.Context should be the first parameter of a function (golint)
    • hiboot/pkg/app/application.go
    • Line 37: warning: exported const ContextPathFormat should have comment (or a comment on this block) or be unexported (golint)
    • Line 137: warning: comment on exported method BaseApplication.Build should be of the form "Build ..." (golint)
    • hiboot/pkg/at/restcontroller.go
    • Line 33: warning: exported type HttpMethodSubscriber should have comment or be unexported (golint)
    • Line 145: warning: comment on exported type FileServer should be of the form "FileServer ..." (with optional leading article) (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign99%

IneffAssign detects ineffectual assignments in Go code.


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!