Report for github.com/go-x-pkg/servers

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


golint16%

Golint is a linter for Go source code.

    • servers/args.go
    • Line 24: warning: exported type Arg should have comment or be unexported (golint)
    • Line 26: warning: exported function FnShutdownTimeout should have comment or be unexported (golint)
    • Line 30: warning: exported function FnLog should have comment or be unexported (golint)
    • Line 34: warning: exported function Context should have comment or be unexported (golint)
    • servers/servers.go
    • Line 147: warning: exported type Servers should have comment or be unexported (golint)
    • Line 149: warning: exported method Servers.IntoIter should have comment or be unexported (golint)
    • Line 151: warning: exported method Servers.ForEach should have comment or be unexported (golint)
    • Line 161: warning: exported method Servers.Defaultize should have comment or be unexported (golint)
    • Line 165: warning: exported method Servers.Dump should have comment or be unexported (golint)
    • Line 167: warning: exported method Servers.Validate should have comment or be unexported (golint)
    • Line 169: warning: exported method Servers.PushINETIfNotExists should have comment or be unexported (golint)
    • Line 188: warning: exported method Servers.PushUnixIfNotExists should have comment or be unexported (golint)
    • Line 206: warning: exported method Servers.SetPortToFirstINET should have comment or be unexported (golint)
    • Line 214: warning: exported method Servers.Listen should have comment or be unexported (golint)
    • Line 226: warning: exported method Servers.ServeGRPC should have comment or be unexported (golint)
    • Line 234: warning: exported method Servers.Close should have comment or be unexported (golint)
    • servers/listen-serve.go
    • Line 20: warning: exported type ServerListener should have comment or be unexported (golint)
    • Line 25: warning: exported method ServerListener.Addr should have comment or be unexported (golint)
    • servers/server-base.go
    • Line 3: warning: exported type WithKind should have comment or be unexported (golint)
    • Line 7: warning: exported method WithKind.Kind should have comment or be unexported (golint)
    • Line 28: warning: exported type WithNetwork should have comment or be unexported (golint)
    • Line 32: warning: exported type ServerBase should have comment or be unexported (golint)
    • Line 37: warning: exported method ServerBase.Network should have comment or be unexported (golint)
    • servers/server-inet.go
    • Line 13: warning: exported type ServerINET should have comment or be unexported (golint)
    • Line 32: warning: exported method ServerINET.Addr should have comment or be unexported (golint)
    • Line 66: warning: exported method ServerINET.Dump should have comment or be unexported (golint)
    • servers/server-unix.go
    • Line 13: warning: exported type ServerUNIX should have comment or be unexported (golint)
    • Line 20: warning: exported method ServerUNIX.Addr should have comment or be unexported (golint)
    • Line 53: warning: exported method ServerUNIX.Dump should have comment or be unexported (golint)
    • servers/server-wrapped.go
    • Line 10: warning: comment on exported type ServerWrapped should be of the form "ServerWrapped ..." (with optional leading article) (golint)
    • Line 38: warning: exported method ServerWrapped.MarshalJSON should have comment or be unexported (golint)
    • Line 42: warning: exported method ServerWrapped.MarshalYAML should have comment or be unexported (golint)
    • Line 46: warning: exported method ServerWrapped.UnmarshalJSON should have comment or be unexported (golint)
    • Line 50: warning: exported method ServerWrapped.UnmarshalYAML should have comment or be unexported (golint)
    • servers/errors.go
    • Line 6: warning: exported var ErrUnmarshalUnknownKind should have comment or be unexported (golint)
    • servers/kind.go
    • Line 10: warning: exported var ErrKindINETAndUNIX should have comment or be unexported (golint)
    • Line 12: warning: exported type Kind should have comment or be unexported (golint)
    • Line 15: warning: exported const KindEmpty should have comment (or a comment on this block) or be unexported (golint)
    • Line 34: warning: comment on exported method Kind.IsSingle should be of the form "IsSingle ..." (golint)
    • Line 39: warning: exported method Kind.IsEmpty should have comment or be unexported (golint)
    • Line 40: warning: exported method Kind.Has should have comment or be unexported (golint)
    • Line 41: warning: exported method Kind.Set should have comment or be unexported (golint)
    • Line 42: warning: exported method Kind.UnSet should have comment or be unexported (golint)
    • Line 52: warning: exported method Kind.StringTrySingle should have comment or be unexported (golint)
    • Line 87: warning: exported method Kind.MarshalJSON should have comment or be unexported (golint)
    • Line 89: warning: exported method Kind.MarshalYAML should have comment or be unexported (golint)
    • Line 91: warning: exported method Kind.UnmarshalJSON should have comment or be unexported (golint)
    • Line 95: warning: exported method Kind.UnmarshalYAML should have comment or be unexported (golint)
    • Line 99: warning: exported method Kind.ToStringSlice should have comment or be unexported (golint)
    • Line 116: warning: exported method Kind.NewServer should have comment or be unexported (golint)
    • Line 124: warning: exported function NewKindFromStringSlice should have comment or be unexported (golint)
    • Line 134: warning: exported function NewKindFromString 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!