Preparing report...

Report for github.com/iotaledger/autopeering-sim

A+    Excellent!    Found 8 issues across 11 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!


gocyclo100%

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.

No problems detected. Good job!


golint27%

Golint is a linter for Go source code.

    • autopeering-sim/simulation/node.go
    • Line 19: warning: exported type Node should have comment or be unexported (golint)
    • Line 27: warning: exported function NewNode should have comment or be unexported (golint)
    • Line 60: warning: exported method Node.ID should have comment or be unexported (golint)
    • Line 64: warning: exported method Node.Peer should have comment or be unexported (golint)
    • Line 68: warning: exported method Node.GetNeighbors should have comment or be unexported (golint)
    • Line 72: warning: exported method Node.GetOutgoingNeighbors should have comment or be unexported (golint)
    • autopeering-sim/simulation/results.go
    • Line 21: warning: exported function LinksToString should have comment or be unexported (golint)
    • Line 42: warning: exported function ConvergenceToString should have comment or be unexported (golint)
    • Line 55: warning: exported function MessagesToString should have comment or be unexported (golint)
    • autopeering-sim/simulation/sim_info.go
    • Line 12: warning: exported const ACCEPTED should have comment (or a comment on this block) or be unexported (golint)
    • Line 19: warning: exported var RecordConv should have comment or be unexported (golint)
    • Line 21: warning: exported type Status should have comment or be unexported (golint)
    • Line 27: warning: exported type StatusSum should have comment or be unexported (golint)
    • Line 35: warning: exported type Link should have comment or be unexported (golint)
    • Line 41: warning: exported type Convergence should have comment or be unexported (golint)
    • Line 47: warning: exported type ConvergenceList should have comment or be unexported (golint)
    • Line 52: warning: exported type StatusMap should have comment or be unexported (golint)
    • Line 57: warning: exported function NewConvergenceList should have comment or be unexported (golint)
    • Line 63: warning: exported method ConvergenceList.Append should have comment or be unexported (golint)
    • Line 69: warning: exported method ConvergenceList.GetConvergence should have comment or be unexported (golint)
    • Line 79: warning: exported method ConvergenceList.GetAvgNeighbors should have comment or be unexported (golint)
    • Line 89: warning: exported function NewStatusMap should have comment or be unexported (golint)
    • Line 95: warning: exported method StatusMap.Append should have comment or be unexported (golint)
    • Line 106: warning: exported method StatusMap.GetSummary should have comment or be unexported (golint)
    • Line 126: warning: exported function NewLink should have comment or be unexported (golint)
    • Line 134: warning: exported function DropLink should have comment or be unexported (golint)
    • autopeering-sim/simulation/config/config.go
    • Line 29: warning: exported function Load should have comment or be unexported (golint)
    • Line 42: warning: exported function PrintConfig should have comment or be unexported (golint)
    • Line 49: warning: exported function NumberNodes should have comment or be unexported (golint)
    • Line 53: warning: exported function Duration should have comment or be unexported (golint)
    • Line 57: warning: exported function SaltLifetime should have comment or be unexported (golint)
    • Line 61: warning: exported function DropOnUpdate should have comment or be unexported (golint)
    • Line 65: warning: exported function VisEnabled should have comment or be unexported (golint)
    • autopeering-sim/simulation/visualizer/api.go
    • Line 14: warning: exported function AddNode should have comment or be unexported (golint)
    • Line 23: warning: exported function RemoveNode should have comment or be unexported (golint)
    • Line 32: warning: exported function AddLink should have comment or be unexported (golint)
    • Line 41: warning: exported function RemoveLink should have comment or be unexported (golint)
    • Line 50: warning: exported function UpdateConvergence should have comment or be unexported (golint)
    • Line 58: warning: exported function UpdateAvgNeighbors should have comment or be unexported (golint)
    • autopeering-sim/simulation/visualizer/server.go
    • Line 16: warning: exported type Server should have comment or be unexported (golint)
    • Line 21: warning: exported type Event should have comment or be unexported (golint)
    • Line 38: warning: exported function NewServer should have comment or be unexported (golint)
    • Line 54: warning: exported method Server.Run should have comment or be unexported (golint)
    • Line 62: warning: exported method Server.Close should have comment or be unexported (golint)
    • Line 69: warning: exported function Writer 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!