Preparing report...

Report for github.com/asyncapi/parser

A+    Excellent!    Found 12 issues across 25 files

Tweet

gofmt88%

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!


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!


golint56%

Golint is a linter for Go source code.

    • parser/pkg/jsonpath/loader.go
    • Line 11: warning: exported type HttpClient should have comment or be unexported (golint)
    • Line 15: warning: exported type RefLoader should have comment or be unexported (golint)
    • Line 36: warning: exported function NewRefLoader should have comment or be unexported (golint)
    • Line 40: warning: exported method RefLoader.Load should have comment or be unexported (golint)
    • parser/pkg/error/error.go
    • Line 5: warning: exported type Error should have comment or be unexported (golint)
    • Line 11: warning: exported function New should have comment or be unexported (golint)
    • Line 20: warning: exported function Join should have comment or be unexported (golint)
    • parser/pkg/schema/asyncapi/v2/message_processor.go
    • Line 11: warning: exported var ErrInvalidValue should have comment or be unexported (golint)
    • Line 21: warning: exported type Dispatcher should have comment or be unexported (golint)
    • Line 39: warning: exported method Dispatcher.Add should have comment or be unexported (golint)
    • Line 46: warning: exported function BuildMessageProcessor should have comment or be unexported (golint)
    • parser/pkg/parser/parser.go
    • Line 13: warning: exported type Parse should have comment or be unexported (golint)
    • Line 15: warning: exported type MessageProcessor should have comment or be unexported (golint)
    • Line 17: warning: exported type EncoderOpts should have comment or be unexported (golint)
    • Line 19: warning: exported method MessageProcessor.BuildParse should have comment or be unexported (golint)
    • parser/pkg/parser/v2/hlsp.go
    • Line 11: warning: exported type Parser should have comment or be unexported (golint)
    • Line 19: warning: exported var ErrCircularDependency should have comment or be unexported (golint)
    • Line 21: warning: exported method Parser.Parse should have comment or be unexported (golint)
    • Line 117: warning: exported function NewParser should have comment or be unexported (golint)
    • parser/pkg/schema/parser.go
    • Line 10: warning: exported type ParseMessage should have comment or be unexported (golint)
    • Line 14: warning: exported type Parser should have comment or be unexported (golint)
    • Line 18: warning: exported function NewParser should have comment or be unexported (golint)
    • Line 24: warning: exported method Parser.Parse should have comment or be unexported (golint)
    • parser/pkg/decode/decode.go
    • Line 10: warning: exported var ErrUnableToDecodeDocument should have comment or be unexported (golint)
    • Line 12: warning: exported function ToMap should have comment or be unexported (golint)
    • parser/pkg/jsonpath/reference.go
    • Line 11: warning: exported var ErrInvalidPath should have comment or be unexported (golint)
    • Line 22: warning: exported type Ref should have comment or be unexported (golint)
    • Line 28: warning: exported function NewRef should have comment or be unexported (golint)
    • Line 45: warning: exported method Ref.URI should have comment or be unexported (golint)
    • Line 49: warning: exported method Ref.Path should have comment or be unexported (golint)
    • Line 53: warning: exported method Ref.NewChild should have comment or be unexported (golint)
    • Line 58: warning: exported function DecodeEntryKey should have comment or be unexported (golint)
    • Line 84: warning: exported function EncodeEntryKey should have comment or be unexported (golint)
    • Line 111: warning: exported function GetRefObject should have comment or be unexported (golint)
    • Line 132: warning: exported function ParseRefStr should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!