Preparing report...

Report for github.com/gokit/rpkit

A    Great!    Found 21 issues across 25 files

Tweet

gofmt84%

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!


gocyclo92%

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.

    • rpkit/rp/rp.go
    • Line 19: warning: cyclomatic complexity 88 of function InterfaceRP() is high (> 15) (gocyclo)
    • rpkit/examples/users/userservicerp/userservice.rp.go
    • Line 642: warning: cyclomatic complexity 26 of function (implPokeHandler).ServeHTTP() is high (> 15) (gocyclo)
    • Line 1009: warning: cyclomatic complexity 26 of function (implPokeAgainHandler).ServeHTTP() is high (> 15) (gocyclo)
    • Line 2213: warning: cyclomatic complexity 26 of function (implCreateHandler).ServeHTTP() is high (> 15) (gocyclo)
    • Line 3052: warning: cyclomatic complexity 26 of function (implCreateUserHandler).ServeHTTP() is high (> 15) (gocyclo)
    • Line 1792: warning: cyclomatic complexity 26 of function (implGetUsersHandler).ServeHTTP() is high (> 15) (gocyclo)
    • Line 2633: warning: cyclomatic complexity 26 of function (implGetByHandler).ServeHTTP() is high (> 15) (gocyclo)
    • Line 1403: warning: cyclomatic complexity 26 of function (implGetHandler).ServeHTTP() is high (> 15) (gocyclo)
    • Line 3471: warning: cyclomatic complexity 26 of function (implGetUserHandler).ServeHTTP() is high (> 15) (gocyclo)
    • Line 2939: warning: cyclomatic complexity 16 of function (implCreateUserClient).CreateUser() is high (> 15) (gocyclo)
    • Line 2099: warning: cyclomatic complexity 16 of function (implCreateClient).Create() is high (> 15) (gocyclo)
    • Line 3358: warning: cyclomatic complexity 16 of function (implGetUserClient).GetUser() is high (> 15) (gocyclo)
    • Line 2519: warning: cyclomatic complexity 16 of function (implGetByClient).GetBy() is high (> 15) (gocyclo)

golint68%

Golint is a linter for Go source code.

    • rpkit/codecs/helpers/tests/tests.go
    • Line 19: warning: comment on exported type UnmarshalDecoder should be of the form "UnmarshalDecoder ..." (with optional leading article) (golint)
    • Line 25: warning: exported function VerifyCodecsWithMaps should have comment or be unexported (golint)
    • Line 46: warning: exported function VerifyCodecsWithStructs should have comment or be unexported (golint)
    • rpkit/examples/users/users.go
    • Line 5: warning: exported type NewUser should have comment or be unexported (golint)
    • Line 9: warning: exported type User should have comment or be unexported (golint)
    • Line 16: warning: comment on exported type UserService should be of the form "UserService ..." (with optional leading article) (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign36%

IneffAssign detects ineffectual assignments in Go code.

    • rpkit/rp/rp.go
    • Line 9: warning: cannot find package "." in: (ineffassign)
    • Line 13: warning: cannot find package "." in: (ineffassign)
    • Line 14: warning: cannot find package "." in: (ineffassign)
    • Line 9: warning: could not import github.com/gokit/rpkit/static (invalid package name: "") (ineffassign)
    • Line 13: warning: could not import github.com/influx6/moz/ast (invalid package name: "") (ineffassign)
    • Line 14: warning: could not import github.com/influx6/moz/gen (invalid package name: "") (ineffassign)
    • rpkit/codecs/json/json_test.go
    • Line 6: warning: cannot find package "." in: (ineffassign)
    • Line 7: warning: cannot find package "." in: (ineffassign)
    • Line 6: warning: could not import github.com/gokit/rpkit/codecs/helpers/tests (invalid package name: "") (ineffassign)
    • Line 7: warning: could not import github.com/gokit/rpkit/codecs/json (invalid package name: "") (ineffassign)
    • rpkit/main.go
    • Line 7: warning: cannot find package "." in: (ineffassign)
    • Line 9: warning: cannot find package "." in: (ineffassign)
    • Line 10: warning: cannot find package "." in: (ineffassign)
    • Line 11: warning: cannot find package "." in: (ineffassign)
    • Line 12: warning: cannot find package "." in: (ineffassign)
    • Line 7: warning: could not import github.com/gokit/rpkit/rp (invalid package name: "") (ineffassign)
    • Line 9: warning: could not import github.com/influx6/faux/flags (invalid package name: "") (ineffassign)
    • Line 10: warning: could not import github.com/influx6/faux/metrics (invalid package name: "") (ineffassign)
    • Line 11: warning: could not import github.com/influx6/faux/metrics/custom (invalid package name: "") (ineffassign)
    • Line 12: warning: could not import github.com/influx6/moz/ast (invalid package name: "") (ineffassign)
    • rpkit/codecs/msgpack/msgpack_test.go
    • Line 6: warning: cannot find package "." in: (ineffassign)
    • Line 7: warning: cannot find package "." in: (ineffassign)
    • Line 6: warning: could not import github.com/gokit/rpkit/codecs/helpers/tests (invalid package name: "") (ineffassign)
    • Line 7: warning: could not import github.com/gokit/rpkit/codecs/msgpack (invalid package name: "") (ineffassign)
    • rpkit/codecs/gobs/gobs_test.go
    • Line 6: warning: cannot find package "." in: (ineffassign)
    • Line 7: warning: cannot find package "." in: (ineffassign)
    • Line 6: warning: could not import github.com/gokit/rpkit/codecs/gobs (invalid package name: "") (ineffassign)
    • Line 7: warning: could not import github.com/gokit/rpkit/codecs/helpers/tests (invalid package name: "") (ineffassign)
    • rpkit/codecs/fn/fn_test.go
    • Line 12: warning: cannot find package "." in: (ineffassign)
    • Line 13: warning: cannot find package "." in: (ineffassign)
    • Line 12: warning: could not import github.com/gokit/rpkit/codecs/fn (invalid package name: "") (ineffassign)
    • Line 13: warning: could not import github.com/stretchr/testify/assert (invalid package name: "") (ineffassign)
    • rpkit/examples/users/tests/goside/userservicerp_test.go
    • Line 16: warning: cannot find package "." in: (ineffassign)
    • Line 17: warning: cannot find package "." in: (ineffassign)
    • Line 18: warning: cannot find package "." in: (ineffassign)
    • Line 19: warning: cannot find package "." in: (ineffassign)
    • Line 16: warning: could not import github.com/gokit/rpkit/examples/users (invalid package name: "") (ineffassign)
    • Line 17: warning: could not import github.com/gokit/rpkit/examples/users/mocks (invalid package name: "") (ineffassign)
    • Line 18: warning: could not import github.com/gokit/rpkit/examples/users/userservicerp (invalid package name: "") (ineffassign)
    • Line 19: warning: could not import github.com/stretchr/testify/assert (invalid package name: "") (ineffassign)
    • rpkit/examples/users/tests/gojs/main.go
    • Line 12: warning: cannot find package "." in: (ineffassign)
    • Line 13: warning: cannot find package "." in: (ineffassign)
    • Line 14: warning: cannot find package "." in: (ineffassign)
    • Line 12: warning: could not import github.com/gokit/rpkit/examples/users (invalid package name: "") (ineffassign)
    • Line 13: warning: could not import github.com/gokit/rpkit/examples/users/mocks (invalid package name: "") (ineffassign)
    • Line 14: warning: could not import github.com/gokit/rpkit/examples/users/userservicerp (invalid package name: "") (ineffassign)
    • rpkit/codecs/sereal/sereal_test.go
    • Line 6: warning: cannot find package "." in: (ineffassign)
    • Line 7: warning: cannot find package "." in: (ineffassign)
    • Line 6: warning: could not import github.com/gokit/rpkit/codecs/helpers/tests (invalid package name: "") (ineffassign)
    • Line 7: warning: could not import github.com/gokit/rpkit/codecs/sereal (invalid package name: "") (ineffassign)
    • rpkit/codecs/protobufs/protobufs_test.go
    • Line 10: warning: cannot find package "." in: (ineffassign)
    • Line 11: warning: cannot find package "." in: (ineffassign)
    • Line 12: warning: cannot find package "." in: (ineffassign)
    • Line 13: warning: cannot find package "." in: (ineffassign)
    • Line 10: warning: could not import github.com/gokit/rpkit/codecs/helpers/tests (invalid package name: "") (ineffassign)
    • Line 11: warning: could not import github.com/gokit/rpkit/codecs/protobufs (invalid package name: "") (ineffassign)
    • Line 12: warning: could not import github.com/gokit/rpkit/codecs/protobufs/rails (invalid package name: "") (ineffassign)
    • Line 13: warning: could not import github.com/stretchr/testify/assert (invalid package name: "") (ineffassign)

misspell92%

Misspell Finds commonly misspelled English words

    • rpkit/examples/users/userservicerp/userservice.rp.go
    • Line 778: warning: "occured" is a misspelling of "occurred" (misspell)
    • Line 1146: warning: "occured" is a misspelling of "occurred" (misspell)
    • Line 1540: warning: "occured" is a misspelling of "occurred" (misspell)
    • Line 1929: warning: "occured" is a misspelling of "occurred" (misspell)
    • Line 2352: warning: "occured" is a misspelling of "occurred" (misspell)
    • Line 2772: warning: "occured" is a misspelling of "occurred" (misspell)
    • Line 3191: warning: "occured" is a misspelling of "occurred" (misspell)
    • Line 3610: warning: "occured" is a misspelling of "occurred" (misspell)
    • Line 3691: warning: "occured" is a misspelling of "occurred" (misspell)