Preparing report...

Report for github.com/grokify/go-simplekpi

A    Great!    Found 22 issues across 24 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!


gocyclo79%

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.


golint8%

Golint is a linter for Go source code.

    • go-simplekpi/simplekpiutil/client.go
    • Line 16: warning: exported const ApiDateFormat should have comment (or a comment on this block) or be unexported (golint)
    • Line 25: warning: exported function NewApiClient should have comment or be unexported (golint)
    • Line 42: warning: exported type Config should have comment or be unexported (golint)
    • Line 48: warning: exported function NewApiClientConfig should have comment or be unexported (golint)
    • Line 52: warning: exported function NewApiClientEnv should have comment or be unexported (golint)
    • Line 59: warning: exported function GetUserIDEnv should have comment or be unexported (golint)
    • go-simplekpi/simplekpi/api_users.go
    • Line 24: warning: exported type UsersApiService should have comment or be unexported (golint)
    • Line 26: warning: comment on exported method UsersApiService.GetAllUsers should be of the form "GetAllUsers ..." (golint)
    • go-simplekpi/simplekpi/api_kp_is.go
    • Line 26: warning: exported type KPIsApiService should have comment or be unexported (golint)
    • Line 28: warning: comment on exported method KPIsApiService.GetAllKPIs should be of the form "GetAllKPIs ..." (golint)
    • Line 114: warning: comment on exported method KPIsApiService.GetKPI should be of the form "GetKPI ..." (golint)
    • go-simplekpi/simplekpi/api_kpi_entries.go
    • Line 27: warning: exported type KPIEntriesApiService should have comment or be unexported (golint)
    • Line 29: warning: comment on exported method KPIEntriesApiService.AddKPIEntry should be of the form "AddKPIEntry ..." (golint)
    • Line 118: warning: comment on exported method KPIEntriesApiService.DeleteKPIEntry should be of the form "DeleteKPIEntry ..." (golint)
    • Line 198: warning: exported type GetAllKPIEntriesOpts should have comment or be unexported (golint)
    • Line 205: warning: exported method KPIEntriesApiService.GetAllKPIEntries should have comment or be unexported (golint)
    • Line 299: warning: comment on exported method KPIEntriesApiService.GetKPIEntry should be of the form "GetKPIEntry ..." (golint)
    • Line 386: warning: comment on exported method KPIEntriesApiService.UpdateKPIEntry should be of the form "UpdateKPIEntry ..." (golint)
    • go-simplekpi/simplekpi/configuration.go
    • Line 52: warning: exported type Configuration should have comment or be unexported (golint)
    • Line 61: warning: exported function NewConfiguration should have comment or be unexported (golint)
    • Line 70: warning: exported method Configuration.AddDefaultHeader should have comment or be unexported (golint)
    • go-simplekpi/charts/data_series.go
    • Line 15: warning: exported function GetKpiAsDataSeries should have comment or be unexported (golint)
    • Line 29: warning: exported function KpiAndEntriesToDataSeries should have comment or be unexported (golint)
    • go-simplekpi/charts/google_slides.go
    • Line 22: warning: exported const DefaultXAxisTimeFormat should have comment or be unexported (golint)
    • Line 24: warning: exported type KpiSlideOpts should have comment or be unexported (golint)
    • Line 40: warning: exported function KpiTypeAbbrIsDollars should have comment or be unexported (golint)
    • Line 48: warning: exported function KpiSlideOptsDefaultify should have comment or be unexported (golint)
    • Line 63: warning: exported function KpiSlideOptsSize2Col should have comment or be unexported (golint)
    • Line 71: warning: exported function CreateKPISlide should have comment or be unexported (golint)
    • go-simplekpi/simplekpi/response.go
    • Line 16: warning: exported type APIResponse should have comment or be unexported (golint)
    • Line 33: warning: exported function NewAPIResponse should have comment or be unexported (golint)
    • Line 39: warning: exported function NewAPIResponseWithError should have comment or be unexported (golint)
    • go-simplekpi/charts/data_series_set.go
    • Line 14: warning: exported type SimplekpiDataSeriesSet should have comment or be unexported (golint)
    • Line 22: warning: exported function NewSimplekpiDataSeriesSet should have comment or be unexported (golint)
    • Line 29: warning: exported method SimplekpiDataSeriesSet.LoadData should have comment or be unexported (golint)
    • go-simplekpi/simplekpi/client.go
    • Line 168: warning: comment on exported method APIClient.ChangeBasePath should be of the form "ChangeBasePath ..." (golint)
    • Line 506: warning: exported method APIClient.HTTPClient should have comment or be unexported (golint)
    • Line 506: warning: receiver name apiClient should be consistent with previous receiver name c for APIClient (golint)
    • go-simplekpi/charts/google_slides_set.go
    • Line 8: warning: exported type SlidesInfoSet should have comment or be unexported (golint)
    • Line 14: warning: exported function NewSlidesInfoSet should have comment or be unexported (golint)
    • Line 18: warning: exported method SlidesInfoSet.Inflate should have comment or be unexported (golint)
    • Line 25: warning: exported function CreateKPISlides should have comment or be unexported (golint)
    • Line 36: warning: exported method SlidesInfoSet.Count should have comment or be unexported (golint)
    • Line 40: warning: exported method SlidesInfoSet.Filter should have comment or be unexported (golint)
    • go-simplekpi/simplekpiutil/client_util.go
    • Line 16: warning: exported type ClientUtil should have comment or be unexported (golint)
    • Line 20: warning: exported method ClientUtil.GetKPI should have comment or be unexported (golint)
    • Line 26: warning: should replace errors.New(fmt.Sprintf(...)) with fmt.Errorf(...) (golint)
    • Line 32: warning: exported method ClientUtil.GetAllKPIEntries should have comment or be unexported (golint)
    • Line 46: warning: should replace errors.New(fmt.Sprintf(...)) with fmt.Errorf(...) (golint)
    • Line 52: warning: exported method ClientUtil.GetKPIEntriesAsDataSeries should have comment or be unexported (golint)
    • Line 71: warning: exported function DataSeriesAddKPIEntries should have comment or be unexported (golint)
    • Line 84: warning: exported function KPIEntriesToDataSeries should have comment or be unexported (golint)
    • Line 89: warning: exported function FrequencyIDToInterval should have comment or be unexported (golint)
    • go-simplekpi/simplekpiutil/kpientries_client.go
    • Line 12: warning: exported type KpiEntriesClient should have comment or be unexported (golint)
    • Line 17: warning: exported function NewKpiEntriesClientEnv should have comment or be unexported (golint)
    • Line 32: warning: exported method KpiEntriesClient.UpsertKpiEntriesDataSeries should have comment or be unexported (golint)
    • Line 37: warning: exported method KpiEntriesClient.UpsertKpiEntriesDataSeriesSetSimple should have comment or be unexported (golint)
    • Line 58: warning: exported function WriteKpisXlsx 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!