Preparing report...

Report for github.com/geo-data/lurch

A    Great!    Found 9 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!


gocyclo80%

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.

    • lurch/main.go
    • Line 81: warning: cyclomatic complexity 17 of function run() is high (> 15) (gocyclo)

golint10%

Golint is a linter for Go source code.

    • lurch/run_state.go
    • Line 5: warning: exported type RunState should have comment or be unexported (golint)
    • Line 10: warning: exported function NewRunState should have comment or be unexported (golint)
    • Line 16: warning: exported method RunState.Set should have comment or be unexported (golint)
    • Line 27: warning: exported method RunState.Unset should have comment or be unexported (golint)
    • lurch/slack.go
    • Line 7: warning: exported function BroadcastMessage should have comment or be unexported (golint)
    • lurch/toggle.go
    • Line 5: warning: exported type Toggle should have comment or be unexported (golint)
    • Line 10: warning: exported method Toggle.IsOn should have comment or be unexported (golint)
    • Line 16: warning: exported method Toggle.On should have comment or be unexported (golint)
    • Line 23: warning: exported method Toggle.Off should have comment or be unexported (golint)
    • lurch/process.go
    • Line 102: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 113: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 423: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 445: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • lurch/main.go
    • Line 60: warning: exported function UpdateChannels should have comment or be unexported (golint)
    • Line 94: warning: should replace errors.New(fmt.Sprintf(...)) with fmt.Errorf(...) (golint)
    • Line 262: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • lurch/message.go
    • Line 10: warning: exported type Message should have comment or be unexported (golint)
    • Line 16: warning: exported function NewMessage should have comment or be unexported (golint)
    • Line 74: warning: exported method Message.Reply should have comment or be unexported (golint)
    • Line 84: warning: exported type Conversation should have comment or be unexported (golint)
    • Line 88: warning: exported type ChannelMessage should have comment or be unexported (golint)
    • Line 93: warning: exported function NewChannelMessage should have comment or be unexported (golint)
    • Line 106: warning: exported type Broadcast should have comment or be unexported (golint)
    • Line 111: warning: exported function NewBroadcast should have comment or be unexported (golint)
    • Line 115: warning: exported method Broadcast.Send should have comment or be unexported (golint)
    • lurch/playbook.go
    • Line 5: warning: exported type Results should have comment or be unexported (golint)
    • Line 19: warning: exported type Stats should have comment or be unexported (golint)
    • Line 27: warning: exported type Play should have comment or be unexported (golint)
    • Line 32: warning: exported type Task should have comment or be unexported (golint)
    • Line 37: warning: exported type Name should have comment or be unexported (golint)
    • Line 45: warning: exported type Host should have comment or be unexported (golint)
    • lurch/user.go
    • Line 9: warning: exported type User should have comment or be unexported (golint)
    • Line 15: warning: exported function NewUser should have comment or be unexported (golint)
    • lurch/config.go
    • Line 10: warning: exported type Config should have comment or be unexported (golint)
    • Line 33: warning: exported type ChannelType should have comment or be unexported (golint)
    • Line 36: warning: exported const None should have comment (or a comment on this block) or be unexported (golint)
    • Line 41: warning: exported type Channels should have comment or be unexported (golint)
    • Line 46: warning: exported function NewChannels should have comment or be unexported (golint)
    • Line 52: warning: exported method Channels.RemoveChannel should have comment or be unexported (golint)
    • Line 58: warning: exported method Channels.AddChannel should have comment or be unexported (golint)
    • Line 64: warning: exported method Channels.HasChannel should have comment or be unexported (golint)
    • Line 71: warning: exported method Channels.GetType should have comment or be unexported (golint)
    • Line 78: warning: exported method Channels.GetChannels should have comment or be unexported (golint)
    • Line 85: warning: exported type Stack should have comment or be unexported (golint)
    • Line 98: warning: exported type Playbook should have comment or be unexported (golint)
    • Line 113: warning: exported type Action 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!