Preparing report...

Report for github.com/adolli/grafana-sdk

A+    Excellent!    Found 15 issues across 49 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!


gocyclo95%

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.


golint75%

Golint is a linter for Go source code.

    • grafana-sdk/datasource.go
    • Line 42: warning: comment on exported type DatasourceType should be of the form "DatasourceType ..." (with optional leading article) (golint)
    • grafana-sdk/org.go
    • Line 21: warning: exported type Org should have comment or be unexported (golint)
    • Line 27: warning: exported type OrgUser should have comment or be unexported (golint)
    • grafana-sdk/panel.go
    • Line 43: warning: exported const MixedSource should have comment or be unexported (golint)
    • Line 65: warning: exported type CommonPanel should have comment or be unexported (golint)
    • Line 98: warning: exported type AlertEvaluator should have comment or be unexported (golint)
    • Line 102: warning: exported type AlertOperator should have comment or be unexported (golint)
    • Line 105: warning: exported type AlertQuery should have comment or be unexported (golint)
    • Line 108: warning: exported type AlertReducer should have comment or be unexported (golint)
    • Line 112: warning: exported type AlertCondition should have comment or be unexported (golint)
    • Line 119: warning: exported type Alert should have comment or be unexported (golint)
    • Line 131: warning: exported type GraphPanel should have comment or be unexported (golint)
    • Line 165: warning: exported type FieldConfig should have comment or be unexported (golint)
    • Line 177: warning: exported type Options should have comment or be unexported (golint)
    • Line 192: warning: exported type Threshold should have comment or be unexported (golint)
    • Line 210: warning: exported type Tooltip should have comment or be unexported (golint)
    • Line 216: warning: exported type TablePanel should have comment or be unexported (golint)
    • Line 224: warning: exported type TextPanel should have comment or be unexported (golint)
    • Line 238: warning: exported type SinglestatPanel should have comment or be unexported (golint)
    • Line 261: warning: exported type StatPanel should have comment or be unexported (golint)
    • Line 285: warning: exported type DashlistPanel should have comment or be unexported (golint)
    • Line 296: warning: exported type PluginlistPanel should have comment or be unexported (golint)
    • Line 299: warning: exported type AlertlistPanel should have comment or be unexported (golint)
    • Line 308: warning: exported type BarGaugePanel should have comment or be unexported (golint)
    • Line 313: warning: exported type RowPanel should have comment or be unexported (golint)
    • Line 317: warning: exported type HeatmapPanel should have comment or be unexported (golint)
    • Line 362: warning: exported type CustomPanel should have comment or be unexported (golint)
    • Line 364: warning: exported type TimeRegion should have comment or be unexported (golint)
    • Line 378: warning: comment on exported type Axis should be of the form "Axis ..." (with optional leading article) (golint)
    • Line 378: warning: comment on exported type Legend should be of the form "Legend ..." (with optional leading article) (golint)
    • Line 378: warning: comment on exported type SeriesOverride should be of the form "SeriesOverride ..." (with optional leading article) (golint)
    • Line 378: warning: comment on exported type Sort should be of the form "Sort ..." (with optional leading article) (golint)
    • Line 446: warning: comment on exported type Column should be of the form "Column ..." (with optional leading article) (golint)
    • Line 446: warning: comment on exported type ColumnStyle should be of the form "ColumnStyle ..." (with optional leading article) (golint)
    • Line 471: warning: comment on exported type Gauge should be of the form "Gauge ..." (with optional leading article) (golint)
    • Line 471: warning: comment on exported type SparkLine should be of the form "SparkLine ..." (with optional leading article) (golint)
    • Line 471: warning: comment on exported type ValueMap should be of the form "ValueMap ..." (with optional leading article) (golint)
    • Line 495: warning: comment on exported type Target should be of the form "Target ..." (with optional leading article) (golint)
    • Line 527: warning: exported type MapType should have comment or be unexported (golint)
    • Line 532: warning: exported type RangeMap should have comment or be unexported (golint)
    • Line 656: warning: exported function NewAlertlist should have comment or be unexported (golint)
    • Line 671: warning: exported function NewHeatmap should have comment or be unexported (golint)
    • Line 766: warning: comment on exported method Panel.RepeatDatasourcesForEachTarget should be of the form "RepeatDatasourcesForEachTarget ..." (golint)
    • Line 857: warning: exported method Panel.UnmarshalJSON should have comment or be unexported (golint)
    • Line 927: warning: exported method Panel.MarshalJSON should have comment or be unexported (golint)
    • grafana-sdk/rest-team.go
    • Line 30: warning: exported method Client.SearchTeamsWithPaging should have comment or be unexported (golint)
    • Line 69: warning: exported method Client.GetTeam should have comment or be unexported (golint)
    • Line 96: warning: exported method Client.GetAllTeam should have comment or be unexported (golint)
    • Line 107: warning: exported method Client.GetUserTeams should have comment or be unexported (golint)
    • Line 111: warning: exported method Client.CreateTeam should have comment or be unexported (golint)
    • Line 129: warning: exported method Client.DeleteTeam should have comment or be unexported (golint)
    • Line 144: warning: exported method Client.AddTeamMember should have comment or be unexported (golint)
    • Line 164: warning: exported method Client.GetTeamMembers should have comment or be unexported (golint)
    • grafana-sdk/row.go
    • Line 35: warning: exported method Row.Add should have comment or be unexported (golint)
    • Line 41: warning: exported method Row.AddDashlist should have comment or be unexported (golint)
    • Line 49: warning: exported method Row.AddGraph should have comment or be unexported (golint)
    • Line 57: warning: exported method Row.AddTable should have comment or be unexported (golint)
    • Line 65: warning: exported method Row.AddText should have comment or be unexported (golint)
    • Line 73: warning: exported method Row.AddStat should have comment or be unexported (golint)
    • Line 81: warning: exported method Row.AddSinglestat should have comment or be unexported (golint)
    • Line 89: warning: exported method Row.AddCustom should have comment or be unexported (golint)
    • grafana-sdk/target.go
    • Line 7: warning: exported type TargetCommonInfo should have comment or be unexported (golint)
    • Line 13: warning: exported type OpentsdbTargetInfo should have comment or be unexported (golint)
    • Line 30: warning: exported type CloudwatchTargetInfo should have comment or be unexported (golint)
    • Line 39: warning: exported type PrometheusTargetInfo should have comment or be unexported (golint)
    • Line 49: warning: exported type MixedTargetInfo should have comment or be unexported (golint)
    • Line 115: warning: exported type OpentsdbFilter should have comment or be unexported (golint)
    • Line 122: warning: exported method Target.UnmarshalJSON should have comment or be unexported (golint)
    • Line 165: warning: exported method Target.MarshalJSON should have comment or be unexported (golint)
    • grafana-sdk/board.go
    • Line 69: warning: exported type Time should have comment or be unexported (golint)
    • Line 73: warning: exported type Timepicker should have comment or be unexported (golint)
    • Line 78: warning: exported type Templating should have comment or be unexported (golint)
    • Line 81: warning: exported type TemplateVar should have comment or be unexported (golint)
    • Line 101: warning: exported type TemplateVarQuery should have comment or be unexported (golint)
    • Line 112: warning: comment on exported type Option should be of the form "Option ..." (with optional leading article) (golint)
    • Line 118: warning: comment on exported type Current should be of the form "Current ..." (with optional leading article) (golint)
    • Line 124: warning: exported type Annotation should have comment or be unexported (golint)
    • Line 165: warning: exported method Height.UnmarshalJSON should have comment or be unexported (golint)
    • Line 180: warning: exported method TemplateVarQuery.MarshalJSON should have comment or be unexported (golint)
    • Line 183: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 192: warning: exported method TemplateVarQuery.UnmarshalJSON should have comment or be unexported (golint)
    • Line 215: warning: exported function NewBoard should have comment or be unexported (golint)
    • Line 228: warning: exported method Board.AddLink should have comment or be unexported (golint)
    • Line 232: warning: exported method Board.RemoveTags should have comment or be unexported (golint)
    • Line 246: warning: exported method Board.AddTags should have comment or be unexported (golint)
    • Line 260: warning: exported method Board.HasTag should have comment or be unexported (golint)
    • Line 269: warning: exported method Board.AddRow should have comment or be unexported (golint)
    • Line 283: warning: exported method Board.UpdateSlug should have comment or be unexported (golint)
    • grafana-sdk/custom-types.go
    • Line 30: warning: exported type BoolString should have comment or be unexported (golint)
    • Line 35: warning: exported method BoolString.UnmarshalJSON should have comment or be unexported (golint)
    • Line 60: warning: exported method BoolString.MarshalJSON should have comment or be unexported (golint)
    • Line 71: warning: exported type BoolInt should have comment or be unexported (golint)
    • Line 76: warning: exported method BoolInt.UnmarshalJSON should have comment or be unexported (golint)
    • Line 98: warning: exported method BoolInt.MarshalJSON should have comment or be unexported (golint)
    • Line 105: warning: exported function NewIntString should have comment or be unexported (golint)
    • Line 150: warning: exported function NewFloatString should have comment or be unexported (golint)
    • grafana-sdk/team.go
    • Line 22: warning: exported type Team should have comment or be unexported (golint)
    • Line 31: warning: exported type TeamMsg should have comment or be unexported (golint)
    • Line 36: warning: exported type PageTeams should have comment or be unexported (golint)
    • grafana-sdk/user.go
    • Line 22: warning: exported type User should have comment or be unexported (golint)
    • Line 33: warning: exported type UserRole should have comment or be unexported (golint)
    • Line 38: warning: exported type UserPermissions should have comment or be unexported (golint)
    • Line 42: warning: exported type PageUsers 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!


misspell95%

Misspell Finds commonly misspelled English words