Preparing report...

Report for github.com/appscode/go-jsonpatch

A+    Excellent!    Found 6 issues across 12 files

Tweet

gofmt100%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command

No problems detected. Good job!


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!


gocyclo100%

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.

No problems detected. Good job!


golint83%

Golint is a linter for Go source code.

    • go-jsonpatch/operation.go
    • Line 14: warning: comment on exported type OperationType should be of the form "OperationType ..." (with optional leading article) (golint)
    • Line 27: warning: exported type PatchOperation should have comment or be unexported (golint)
    • Line 67: warning: exported method PatchOperation.Apply should have comment or be unexported (golint)
    • Line 67: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
    • go-jsonpatch/patch.go
    • Line 1: warning: package comment should be of the form "Package jsonpatch ..." (golint)
    • Line 17: warning: exported type ByPath should have comment or be unexported (golint)
    • Line 26: warning: exported method Patch.Apply should have comment or be unexported (golint)
    • Line 41: warning: exported function FromString should have comment or be unexported (golint)
    • Line 74: warning: exported function MakeDiff should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign66%

IneffAssign detects ineffectual assignments in Go code.

    • go-jsonpatch/patch.go
    • Line 12: warning: cannot find package "." in: (ineffassign)
    • Line 12: warning: could not import github.com/json-iterator/go (invalid package name: "") (ineffassign)
    • Line 15: warning: undeclared name: jsoniter (ineffassign)
    • Line 12: warning: "github.com/json-iterator/go" imported but not used (ineffassign)
    • Line 12: warning: could not import github.com/json-iterator/go (invalid package name: "") (ineffassign)
    • Line 15: warning: undeclared name: jsoniter (ineffassign)
    • Line 12: warning: "github.com/json-iterator/go" imported but not used (ineffassign)
    • go-jsonpatch/operation.go
    • Line 11: warning: cannot find package "." in: (ineffassign)
    • Line 11: warning: could not import github.com/xeipuuv/gojsonpointer (invalid package name: "") (ineffassign)
    • Line 11: warning: could not import github.com/xeipuuv/gojsonpointer (invalid package name: "") (ineffassign)
    • go-jsonpatch/array_test.go
    • Line 7: warning: cannot find package "." in: (ineffassign)
    • Line 7: warning: could not import github.com/stretchr/testify/assert (invalid package name: "") (ineffassign)
    • go-jsonpatch/example_test.go
    • Line 7: warning: cannot find package "." in: (ineffassign)
    • Line 7: warning: could not import github.com/appscode/go-jsonpatch (invalid package name: "") (ineffassign)
    • Line 8: warning: could not import github.com/json-iterator/go (invalid package name: "") (ineffassign)
    • Line 11: warning: undeclared name: jsoniter (ineffassign)
    • Line 14: warning: undeclared name: jsonpatch (ineffassign)
    • Line 15: warning: missing type in composite literal (ineffassign)
    • Line 16: warning: missing type in composite literal (ineffassign)
    • Line 17: warning: missing type in composite literal (ineffassign)
    • Line 18: warning: missing type in composite literal (ineffassign)
    • Line 19: warning: missing type in composite literal (ineffassign)
    • Line 20: warning: missing type in composite literal (ineffassign)
    • Line 53: warning: undeclared name: jsonpatch (ineffassign)
    • Line 7: warning: "github.com/appscode/go-jsonpatch" imported but not used (ineffassign)
    • Line 8: warning: "github.com/json-iterator/go" imported but not used (ineffassign)

misspell83%

Misspell Finds commonly misspelled English words

    • go-jsonpatch/patch_test.go
    • Line 80: warning: "ommitted" is a misspelling of "omitted" (misspell)
    • Line 84: warning: "ommitted" is a misspelling of "omitted" (misspell)
    • Line 88: warning: "ommitted" is a misspelling of "omitted" (misspell)