Preparing report...

Report for github.com/cage1016/gokit-todo

A+    Excellent!    Found 15 issues across 28 files

Tweet

gofmt96%

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.


golint53%

Golint is a linter for Go source code.

    • gokit-todo/internal/app/todo/service/service.go
    • Line 15: warning: exported var ErrMalformedEntity should have comment or be unexported (golint)
    • Line 23: warning: exported const ALL should have comment (or a comment on this block) or be unexported (golint)
    • Line 31: warning: comment on exported type TodoService should be of the form "TodoService ..." (with optional leading article) (golint)
    • gokit-todo/internal/app/todo/transports/http/http.go
    • Line 28: warning: comment on exported function AddHandler should be of the form "AddHandler ..." (golint)
    • Line 44: warning: comment on exported function DeleteHandler should be of the form "DeleteHandler ..." (golint)
    • Line 60: warning: comment on exported function UpdateHandler should be of the form "UpdateHandler ..." (golint)
    • Line 76: warning: comment on exported function ListHandler should be of the form "ListHandler ..." (golint)
    • Line 147: warning: exported function CustomErrorEncoder should have comment or be unexported (golint)
    • gokit-todo/internal/app/todo/endpoints/responses.go
    • Line 37: warning: exported method AddResponse.StatusCode should have comment or be unexported (golint)
    • Line 41: warning: exported method AddResponse.Headers should have comment or be unexported (golint)
    • Line 45: warning: exported method AddResponse.Response should have comment or be unexported (golint)
    • Line 54: warning: exported method DeleteResponse.StatusCode should have comment or be unexported (golint)
    • Line 58: warning: exported method DeleteResponse.Headers should have comment or be unexported (golint)
    • Line 62: warning: exported method DeleteResponse.Response should have comment or be unexported (golint)
    • Line 72: warning: exported method UpdateResponse.StatusCode should have comment or be unexported (golint)
    • Line 76: warning: exported method UpdateResponse.Headers should have comment or be unexported (golint)
    • Line 80: warning: exported method UpdateResponse.Response should have comment or be unexported (golint)
    • Line 90: warning: exported method ListResponse.StatusCode should have comment or be unexported (golint)
    • Line 94: warning: exported method ListResponse.Headers should have comment or be unexported (golint)
    • Line 98: warning: exported method ListResponse.Response should have comment or be unexported (golint)
    • gokit-todo/internal/pkg/errors/errors.go
    • Line 8: warning: exported type Errors should have comment or be unexported (golint)
    • Line 16: warning: exported function FromError should have comment or be unexported (golint)
    • Line 111: warning: exported function Cast should have comment or be unexported (golint)
    • gokit-todo/internal/app/todo/transports/grpc/transfer.go
    • Line 11: warning: exported function ModelReqToPB should have comment or be unexported (golint)
    • Line 18: warning: exported function PBtoModelReq should have comment or be unexported (golint)
    • Line 25: warning: exported function ModelResToPB should have comment or be unexported (golint)
    • Line 35: warning: exported function PBtoModelRes should have comment or be unexported (golint)
    • gokit-todo/internal/pkg/responses/decode.go
    • Line 21: warning: exported function JSONErrorDecoder should have comment or be unexported (golint)
    • Line 33: warning: exported function EncodeJSONResponse should have comment or be unexported (golint)
    • Line 58: warning: exported function ErrorEncodeJSONResponse should have comment or be unexported (golint)
    • gokit-todo/internal/pkg/responses/responses.go
    • Line 3: warning: exported type DataRes should have comment or be unexported (golint)
    • Line 8: warning: exported type Responser should have comment or be unexported (golint)
    • Line 12: warning: exported type BinaryResponser should have comment or be unexported (golint)
    • Line 16: warning: exported type Paging should have comment or be unexported (golint)
    • gokit-todo/internal/app/todo/model/todo.go
    • Line 9: warning: exported type Todo should have comment or be unexported (golint)
    • Line 17: warning: exported method Todo.MarshalJSON should have comment or be unexported (golint)
    • Line 30: warning: exported method Todo.UnmarshalJSON should have comment or be unexported (golint)
    • Line 30: warning: receiver name t should be consistent with previous receiver name p for Todo (golint)
    • Line 51: warning: comment on exported type TodoRepository should be of the form "TodoRepository ..." (with optional leading article) (golint)
    • Line 60: warning: exported type TodoReq should have comment or be unexported (golint)
    • Line 65: warning: exported type TodoRes should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign96%

IneffAssign detects ineffectual assignments in Go code.


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!