Preparing report...

Report for github.com/urld/ttt

(v0.0.0-20220219224929-47602013a94e)

A+    Excellent!    Found 3 issues across 10 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!


gocyclo90%

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.

    • ttt.go
    • Line 64: warning: cyclomatic complexity 16 of function (*TimeTrackingDb).loadConfig() is high (> 15) (gocyclo)

golint70%

Golint is a linter for Go source code.

    • record.go
    • Line 13: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 17: warning: error var ActiveRecordExistsError should have name of the form ErrFoo (golint)
    • Line 17: warning: exported var ActiveRecordExistsError should have comment or be unexported (golint)
    • Line 18: warning: error var NoActiveRecordError should have name of the form ErrFoo (golint)
    • Line 21: warning: exported type Record should have comment or be unexported (golint)
    • Line 27: warning: exported method Record.Active should have comment or be unexported (golint)
    • Line 31: warning: exported method TimeTrackingDb.StartRecord should have comment or be unexported (golint)
    • Line 38: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 46: warning: exported method TimeTrackingDb.EndRecord should have comment or be unexported (golint)
    • Line 56: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 61: warning: exported method TimeTrackingDb.GetCurrentRecord should have comment or be unexported (golint)
    • report.go
    • Line 10: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 13: warning: exported method TimeTrackingDb.GetBusinessDays should have comment or be unexported (golint)
    • Line 42: warning: exported type BusinessDay should have comment or be unexported (golint)
    • ttt.go
    • Line 15: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 18: warning: exported type TimeTrackingDb should have comment or be unexported (golint)
    • Line 32: warning: exported function LoadDb should have comment or be unexported (golint)
    • Line 46: warning: exported function CreateDb should have comment or be unexported (golint)
    • Line 121: warning: exported method TimeTrackingDb.Close 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!