Preparing report...

Report for github.com/AnchorFree/prometheus-ha-proxy

A    Great!    Found 2 issues across 3 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!


gocyclo66%

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.


golint33%

Golint is a linter for Go source code.

    • prometheus-ha-proxy/merger/merge.go
    • Line 10: warning: exported type Output should have comment or be unexported (golint)
    • Line 15: warning: exported type Data should have comment or be unexported (golint)
    • Line 20: warning: exported type Result should have comment or be unexported (golint)
    • Line 26: warning: exported type Values should have comment or be unexported (golint)
    • Line 32: warning: receiver name s should be consistent with previous receiver name v for Values (golint)
    • Line 35: warning: receiver name s should be consistent with previous receiver name v for Values (golint)
    • Line 39: warning: comment on exported function MergeNaively should be of the form "MergeNaively ..." (golint)
    • Line 44: warning: don't use underscores in Go names; var msg_type should be msgType (golint)
    • Line 45: warning: don't use underscores in Go names; var data_msg should be dataMsg (golint)
    • Line 47: warning: don't use underscores in Go names; var meta_data should be metaData (golint)
    • Line 57: warning: don't use underscores in Go names; var tmp_result should be tmpResult (golint)
    • Line 136: warning: don't use underscores in Go names; func parameter data_msg should be dataMsg (golint)
    • prometheus-ha-proxy/main.go
    • Line 30: warning: exported type BackendOutput should have comment or be unexported (golint)
    • Line 35: warning: exported type PromData should have comment or be unexported (golint)
    • Line 40: warning: exported type Endpoint should have comment or be unexported (golint)
    • Line 46: warning: exported method Endpoint.Set should have comment or be unexported (golint)
    • Line 53: warning: exported method Endpoint.Disable should have comment or be unexported (golint)
    • Line 59: warning: exported method Endpoint.Enable should have comment or be unexported (golint)
    • Line 76: warning: don't use underscores in Go names; var my_url should be myURL (golint)
    • Line 96: warning: exported method PromData.EndpointsProbe should have comment or be unexported (golint)
    • Line 120: warning: exported method PromData.PrometheusProxy should have comment or be unexported (golint)
    • Line 155: warning: exported function PromGet 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.


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!