Preparing report...

Report for github.com/FlameInTheDark/dtbot

A    Great!    Found 19 issues across 50 files

Tweet

gofmt78%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command


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!


gocyclo92%

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.

    • dtbot/cmd/botcommand.go
    • Line 174: warning: cyclomatic complexity 38 of function botGuild() is high (> 15) (gocyclo)
    • Line 23: warning: cyclomatic complexity 18 of function BotCommand() is high (> 15) (gocyclo)
    • Line 111: warning: cyclomatic complexity 16 of function botSetConf() is high (> 15) (gocyclo)

golint70%

Golint is a linter for Go source code.

    • dtbot/bot/role.go
    • Line 19: warning: exported method Context.IsServerAdmin should have comment or be unexported (golint)
    • dtbot/bot/session.go
    • Line 99: warning: exported method SessionManager.GetAll should have comment or be unexported (golint)
    • Line 103: warning: exported method Session.IsOk should have comment or be unexported (golint)
    • Line 103: warning: receiver name s should be consistent with previous receiver name sess for Session (golint)
    • Line 153: warning: exported method SessionManager.GetChannels should have comment or be unexported (golint)
    • Line 161: warning: exported method SessionManager.GetGuilds should have comment or be unexported (golint)
    • dtbot/bot/blacklist.go
    • Line 3: warning: comment on exported type BlackListStruct should be of the form "BlackListStruct ..." (with optional leading article) (golint)
    • dtbot/bot/database.go
    • Line 51: warning: exported type TwitchDBConfig should have comment or be unexported (golint)
    • Line 57: warning: exported type BlackListElement should have comment or be unexported (golint)
    • Line 146: warning: exported method DBWorker.GetTwitchToken should have comment or be unexported (golint)
    • Line 156: warning: exported method DBWorker.UpdateTwitchToken should have comment or be unexported (golint)
    • Line 280: warning: comment on exported method DBWorker.GetBlacklist should be of the form "GetBlacklist ..." (golint)
    • dtbot/bot/radio.go
    • Line 25: warning: exported method Connection.EncodeOpusAndSend should have comment or be unexported (golint)
    • dtbot/main.go
    • Line 214: warning: comment on exported function BotUpdater should be of the form "BotUpdater ..." (golint)
    • dtbot/bot/albion.go
    • Line 13: warning: comment on exported type AlbionSearchResult should be of the form "AlbionSearchResult ..." (with optional leading article) (golint)
    • Line 19: warning: comment on exported type AlbionGuildSearch should be of the form "AlbionGuildSearch ..." (with optional leading article) (golint)
    • Line 29: warning: comment on exported type AlbionPlayerSearch should be of the form "AlbionPlayerSearch ..." (with optional leading article) (golint)
    • Line 45: warning: comment on exported type AlbionPlayer should be of the form "AlbionPlayer ..." (with optional leading article) (golint)
    • Line 65: warning: comment on exported type AlbionEquipment should be of the form "AlbionEquipment ..." (with optional leading article) (golint)
    • Line 79: warning: comment on exported type AlbionItem should be of the form "AlbionItem ..." (with optional leading article) (golint)
    • Line 86: warning: comment on exported type AlbionKill should be of the form "AlbionKill ..." (with optional leading article) (golint)
    • Line 103: warning: exported type AlbionUpdater should have comment or be unexported (golint)
    • Line 107: warning: exported type AlbionPlayerUpdater should have comment or be unexported (golint)
    • Line 115: warning: comment on exported function AlbionSearchPlayers should be of the form "AlbionSearchPlayers ..." (golint)
    • Line 135: warning: comment on exported function AlbionGetPlayerKills should be of the form "AlbionGetPlayerKills ..." (golint)
    • Line 175: warning: comment on exported method Context.AlbionShowKills should be of the form "AlbionShowKills ..." (golint)
    • Line 288: warning: comment on exported function GetPlayerByName should be of the form "GetPlayerByName ..." (golint)
    • Line 318: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 353: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • dtbot/bot/command.go
    • Line 41: warning: comment on exported type NodeTree should be of the form "NodeTree ..." (with optional leading article) (golint)
    • Line 46: warning: exported type NodeElement should have comment or be unexported (golint)
    • Line 65: warning: comment on exported function NewTree should be of the form "NewTree ..." (golint)
    • Line 70: warning: exported method NodeElement.AddElement should have comment or be unexported (golint)
    • Line 77: warning: exported method NodeElement.GetElement should have comment or be unexported (golint)
    • Line 84: warning: exported method NodeTree.Execute should have comment or be unexported (golint)
    • Line 88: warning: exported method NodeTree.GetElement should have comment or be unexported (golint)
    • Line 95: warning: exported method NodeTree.AddCommand should have comment or be unexported (golint)
    • Line 108: warning: exported method NodeWorker.CheckMiddlewares should have comment or be unexported (golint)
    • dtbot/bot/reply.go
    • Line 234: warning: comment on exported method Context.ReplyEmbedAttachmentImageURL should be of the form "ReplyEmbedAttachmentImageURL ..." (golint)
    • dtbot/api/darksky/darksky.go
    • Line 114: warning: exported method DarkSkyData.GetTime should have comment or be unexported (golint)
    • Line 123: warning: exported method DarkSkyDayData.GetTime should have comment or be unexported (golint)
    • Line 137: warning: exported method DarkSkyDayData.TZTime should have comment or be unexported (golint)
    • Line 288: warning: comment on exported function GetWeatherWeekImage should be of the form "GetWeatherWeekImage ..." (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!