Preparing report...

Report for github.com/weworksandbox/lingo

A+    Excellent!    Found 54 issues across 113 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!


golint53%

Golint is a linter for Go source code.

    • lingo/dsl.go
    • Line 7: warning: exported type Name should have comment or be unexported (golint)
    • Line 11: warning: exported type Alias should have comment or be unexported (golint)
    • Line 15: warning: exported type Table should have comment or be unexported (golint)
    • Line 23: warning: exported type Column should have comment or be unexported (golint)
    • Line 30: warning: exported type Expression should have comment or be unexported (golint)
    • Line 34: warning: exported type Set should have comment or be unexported (golint)
    • Line 38: warning: exported type OrderBy should have comment or be unexported (golint)
    • Line 42: warning: exported type ComboExpression should have comment or be unexported (golint)
    • Line 48: warning: exported type Dialect should have comment or be unexported (golint)
    • lingo/expr/operator/unary.go
    • Line 12: warning: exported function NewUnary should have comment or be unexported (golint)
    • Line 19: warning: exported type Unary should have comment or be unexported (golint)
    • Line 24: warning: exported method Unary.ToSQL should have comment or be unexported (golint)
    • lingo/dialect/default.go
    • Line 33: warning: exported method Default.GetName should have comment or be unexported (golint)
    • Line 37: warning: exported method Default.ValueFormat should have comment or be unexported (golint)
    • Line 59: warning: exported method Default.SetValueFormat should have comment or be unexported (golint)
    • Line 63: warning: exported method Default.ExpandTable should have comment or be unexported (golint)
    • Line 70: warning: exported method Default.ExpandColumn should have comment or be unexported (golint)
    • Line 74: warning: exported method Default.UnaryOperator should have comment or be unexported (golint)
    • Line 78: warning: exported method Default.BinaryOperator should have comment or be unexported (golint)
    • Line 82: warning: exported method Default.VariadicOperator should have comment or be unexported (golint)
    • Line 86: warning: exported method Default.Value should have comment or be unexported (golint)
    • Line 90: warning: exported method Default.Join should have comment or be unexported (golint)
    • Line 94: warning: exported method Default.OrderBy should have comment or be unexported (golint)
    • Line 98: warning: exported method Default.Set should have comment or be unexported (golint)
    • lingo/expr/operator/variadic.go
    • Line 12: warning: exported function NewVariadic should have comment or be unexported (golint)
    • Line 20: warning: exported type Variadic should have comment or be unexported (golint)
    • Line 26: warning: exported method Variadic.And should have comment or be unexported (golint)
    • Line 30: warning: exported method Variadic.Or should have comment or be unexported (golint)
    • Line 34: warning: exported method Variadic.ToSQL should have comment or be unexported (golint)
    • lingo/expr/value.go
    • Line 16: warning: exported type ValueDialect should have comment or be unexported (golint)
    • Line 20: warning: exported function NewValue should have comment or be unexported (golint)
    • lingo/internal/generator/schema.go
    • Line 8: warning: exported type SchemaInfo should have comment or be unexported (golint)
    • Line 15: warning: exported function NewSchemaInfo should have comment or be unexported (golint)
    • Line 26: warning: exported method SchemaInfo.Generate should have comment or be unexported (golint)
    • lingo/internal/generator/naming.go
    • Line 11: warning: exported function ToTableStruct should have comment or be unexported (golint)
    • Line 15: warning: exported function ToPackageName should have comment or be unexported (golint)
    • Line 19: warning: exported function ToExported should have comment or be unexported (golint)
    • Line 22: warning: exported function ToNonExported should have comment or be unexported (golint)
    • Line 25: warning: exported function LittlePrefix should have comment or be unexported (golint)
    • Line 28: warning: exported function BigPrefix should have comment or be unexported (golint)
    • lingo/internal/parse/schema.go
    • Line 7: warning: exported type Column should have comment or be unexported (golint)
    • Line 12: warning: exported method Column.Name should have comment or be unexported (golint)
    • Line 13: warning: exported method Column.Table should have comment or be unexported (golint)
    • Line 14: warning: exported method Column.Type should have comment or be unexported (golint)
    • Line 16: warning: exported type ForeignKey should have comment or be unexported (golint)
    • Line 20: warning: exported method ForeignKey.Name should have comment or be unexported (golint)
    • lingo/internal/test/matchers/ptrmatcher.go
    • Line 16: warning: exported method PtrMatcher.Match should have comment or be unexported (golint)
    • Line 31: warning: exported method PtrMatcher.FailureMessage should have comment or be unexported (golint)
    • Line 35: warning: exported method PtrMatcher.NegatedFailureMessage should have comment or be unexported (golint)
    • lingo/query/insert.go
    • Line 13: warning: exported function InsertInto should have comment or be unexported (golint)
    • Line 19: warning: exported type InsertQuery should have comment or be unexported (golint)
    • Line 26: warning: exported method InsertQuery.Columns should have comment or be unexported (golint)
    • Line 64: warning: exported method InsertQuery.ToSQL should have comment or be unexported (golint)
    • lingo/expr/path/column.go
    • Line 10: warning: exported type ExpandColumnDialect should have comment or be unexported (golint)
    • Line 14: warning: exported function ExpandColumnWithDialect should have comment or be unexported (golint)
    • lingo/internal/test/matchers/eachelement.go
    • Line 16: warning: exported method MatchEachElement.Match should have comment or be unexported (golint)
    • Line 57: warning: exported method MatchEachElement.FailureMessage should have comment or be unexported (golint)
    • Line 61: warning: exported method MatchEachElement.NegatedFailureMessage should have comment or be unexported (golint)
    • lingo/query/update.go
    • Line 11: warning: exported function Update should have comment or be unexported (golint)
    • Line 18: warning: exported type UpdateQuery should have comment or be unexported (golint)
    • Line 24: warning: exported method UpdateQuery.Where should have comment or be unexported (golint)
    • Line 29: warning: exported method UpdateQuery.Set should have comment or be unexported (golint)
    • Line 34: warning: exported method UpdateQuery.ToSQL should have comment or be unexported (golint)
    • lingo/internal/parse/mysql.go
    • Line 15: warning: exported function NewMySQL should have comment or be unexported (golint)
    • Line 26: warning: exported type MySQL should have comment or be unexported (golint)
    • Line 31: warning: exported method MySQL.DBTypesToPaths should have comment or be unexported (golint)
    • Line 57: warning: exported method MySQL.Tables should have comment or be unexported (golint)
    • Line 92: warning: exported method MySQL.Columns should have comment or be unexported (golint)
    • lingo/internal/test/matchers/sqlvaluesmatcher.go
    • Line 18: warning: exported method SQLValuesMatcher.Match should have comment or be unexported (golint)
    • Line 43: warning: exported method SQLValuesMatcher.FailureMessage should have comment or be unexported (golint)
    • Line 47: warning: exported method SQLValuesMatcher.NegatedFailureMessage should have comment or be unexported (golint)
    • lingo/internal/generator/table.go
    • Line 9: warning: exported const HeaderCommentPrefix should have comment or be unexported (golint)
    • Line 13: warning: exported const PkgLingo should have comment or be unexported (golint)
    • Line 14: warning: exported const PkgExp should have comment or be unexported (golint)
    • Line 15: warning: exported const PkgOperator should have comment or be unexported (golint)
    • Line 16: warning: exported const PkgSet should have comment or be unexported (golint)
    • Line 17: warning: exported const PkgPath should have comment or be unexported (golint)
    • Line 18: warning: exported const PkgSQL should have comment or be unexported (golint)
    • Line 20: warning: exported type TableInfo should have comment or be unexported (golint)
    • Line 28: warning: exported type TableGenerator should have comment or be unexported (golint)
    • Line 39: warning: exported function NewTable should have comment or be unexported (golint)
    • Line 52: warning: exported method TableGenerator.GenerateTable should have comment or be unexported (golint)
    • Line 61: warning: exported method TableGenerator.GenerateExported should have comment or be unexported (golint)
    • lingo/expr/sort/order.go
    • Line 11: warning: exported type Dialect should have comment or be unexported (golint)
    • Line 15: warning: exported function NewOrderBy should have comment or be unexported (golint)
    • Line 22: warning: exported type By should have comment or be unexported (golint)
    • Line 27: warning: exported method By.ToSQL should have comment or be unexported (golint)
    • Line 43: warning: exported function Asc should have comment or be unexported (golint)
    • Line 47: warning: exported function Desc should have comment or be unexported (golint)
    • lingo/expr/join/joinon.go
    • Line 13: warning: exported type Dialect should have comment or be unexported (golint)
    • Line 17: warning: exported function NewJoinOn should have comment or be unexported (golint)
    • Line 25: warning: exported type On should have comment or be unexported (golint)
    • Line 31: warning: exported method On.And should have comment or be unexported (golint)
    • Line 35: warning: exported method On.Or should have comment or be unexported (golint)
    • Line 39: warning: exported method On.ToSQL should have comment or be unexported (golint)
    • lingo/dialect/generic.go
    • Line 24: warning: exported function ExpandTable should have comment or be unexported (golint)
    • Line 32: warning: exported function ExpandTableWithSchema should have comment or be unexported (golint)
    • Line 40: warning: exported function ExpandColumn should have comment or be unexported (golint)
    • Line 48: warning: exported function ExpandColumnWithParent should have comment or be unexported (golint)
    • Line 58: warning: exported type ValueFormatter should have comment or be unexported (golint)
    • Line 62: warning: exported function Value should have comment or be unexported (golint)
    • Line 85: warning: exported function UnaryOperator should have comment or be unexported (golint)
    • Line 99: warning: exported function BinaryOperator should have comment or be unexported (golint)
    • Line 118: warning: exported function VariadicOperator should have comment or be unexported (golint)
    • Line 142: warning: exported function Join should have comment or be unexported (golint)
    • Line 154: warning: exported type SetFormatter should have comment or be unexported (golint)
    • Line 158: warning: exported function Set should have comment or be unexported (golint)
    • Line 170: warning: exported function OrderBy should have comment or be unexported (golint)
    • lingo/expr/parens.go
    • Line 18: warning: exported type Parens should have comment or be unexported (golint)
    • Line 22: warning: exported method Parens.ToSQL should have comment or be unexported (golint)
    • lingo/internal/test/matchers/sqlstringmatcher.go
    • Line 17: warning: exported method SQLStringMatcher.Match should have comment or be unexported (golint)
    • Line 45: warning: exported method SQLStringMatcher.FailureMessage should have comment or be unexported (golint)
    • Line 49: warning: exported method SQLStringMatcher.NegatedFailureMessage should have comment or be unexported (golint)
    • lingo/expr/path/table.go
    • Line 10: warning: exported type ExpandTableDialect should have comment or be unexported (golint)
    • Line 14: warning: exported function ExpandTableWithDialect should have comment or be unexported (golint)
    • lingo/expr/set/set.go
    • Line 13: warning: exported type Dialect should have comment or be unexported (golint)
    • Line 17: warning: exported function NewSet should have comment or be unexported (golint)
    • Line 24: warning: exported type Set should have comment or be unexported (golint)
    • Line 29: warning: exported method Set.And should have comment or be unexported (golint)
    • Line 33: warning: exported method Set.Or should have comment or be unexported (golint)
    • Line 37: warning: exported method Set.ToSQL should have comment or be unexported (golint)
    • lingo/internal/generator/path.go
    • Line 8: warning: exported const GenPathFileHeader should have comment (or a comment on this block) or be unexported (golint)
    • Line 11: warning: exported type Ops should have comment or be unexported (golint)
    • Line 15: warning: exported type Path should have comment or be unexported (golint)
    • Line 23: warning: exported method Path.Generate should have comment or be unexported (golint)
    • lingo/execute/sqlexpexec.go
    • Line 11: warning: exported type ExecSQLExpInTx should have comment or be unexported (golint)
    • Line 13: warning: exported type SQLExp should have comment or be unexported (golint)
    • Line 19: warning: exported type TxSQLExp should have comment or be unexported (golint)
    • Line 25: warning: exported type ExpQuery should have comment or be unexported (golint)
    • Line 31: warning: exported function NewSQLExp should have comment or be unexported (golint)
    • Line 92: warning: exported function NewTxSQLExp should have comment or be unexported (golint)
    • lingo/expr/operator/binary.go
    • Line 12: warning: exported function NewBinary should have comment or be unexported (golint)
    • Line 20: warning: exported type Binary should have comment or be unexported (golint)
    • Line 26: warning: exported method Binary.And should have comment or be unexported (golint)
    • Line 30: warning: exported method Binary.Or should have comment or be unexported (golint)
    • Line 34: warning: exported method Binary.ToSQL should have comment or be unexported (golint)
    • lingo/sql/data.go
    • Line 8: warning: exported type Data should have comment or be unexported (golint)
    • Line 22: warning: exported function New should have comment or be unexported (golint)
    • Line 38: warning: exported function Newf should have comment or be unexported (golint)
    • Line 42: warning: exported function String should have comment or be unexported (golint)
    • Line 49: warning: exported function Format should have comment or be unexported (golint)
    • Line 53: warning: exported function Values should have comment or be unexported (golint)
    • Line 60: warning: exported function Surround should have comment or be unexported (golint)
    • lingo/expr/list.go
    • Line 19: warning: exported type List should have comment or be unexported (golint)
    • Line 23: warning: exported method List.ToSQL should have comment or be unexported (golint)
    • lingo/expr/path/unsupported.go
    • Line 8: warning: exported function NewUnsupportedWithAlias should have comment or be unexported (golint)
    • Line 16: warning: exported function NewUnsupported should have comment or be unexported (golint)
    • Line 20: warning: exported type Unsupported should have comment or be unexported (golint)
    • Line 26: warning: exported method Unsupported.GetParent should have comment or be unexported (golint)
    • Line 30: warning: exported method Unsupported.GetName should have comment or be unexported (golint)
    • Line 34: warning: exported method Unsupported.GetAlias should have comment or be unexported (golint)
    • Line 38: warning: exported method Unsupported.ToSQL should have comment or be unexported (golint)
    • lingo/query/error.go
    • Line 9: warning: exported function NewErrAroundSQL should have comment or be unexported (golint)
    • Line 16: warning: exported type ErrAroundSQL should have comment or be unexported (golint)
    • Line 25: warning: exported method ErrAroundSQL.SQL should have comment or be unexported (golint)
    • lingo/query/delete.go
    • Line 19: warning: exported type DeleteQuery should have comment or be unexported (golint)
    • Line 25: warning: exported method DeleteQuery.Where should have comment or be unexported (golint)
    • Line 30: warning: comment on exported method DeleteQuery.Join should be of the form "Join ..." (golint)
    • Line 40: warning: exported method DeleteQuery.ToSQL should have comment or be unexported (golint)
    • lingo/internal/generator/column.go
    • Line 15: warning: exported method PathPackageToType.ShortPkg should have comment or be unexported (golint)
    • Line 22: warning: exported method PathPackageToType.Pkg should have comment or be unexported (golint)
    • Line 23: warning: exported method PathPackageToType.Type should have comment or be unexported (golint)
    • lingo/execute/db.go
    • Line 8: warning: exported type DBQuery should have comment or be unexported (golint)
    • Line 14: warning: exported type TxDBQuery should have comment or be unexported (golint)
    • lingo/internal/test/matchers/allinslicematcher.go
    • Line 17: warning: exported method AllInSliceMatcher.Match should have comment or be unexported (golint)
    • Line 59: warning: exported method AllInSliceMatcher.FailureMessage should have comment or be unexported (golint)
    • Line 64: warning: exported method AllInSliceMatcher.NegatedFailureMessage should have comment or be unexported (golint)
    • lingo/query/select.go
    • Line 14: warning: exported function Select should have comment or be unexported (golint)
    • Line 20: warning: exported function SelectFrom should have comment or be unexported (golint)
    • Line 24: warning: exported type SelectQuery should have comment or be unexported (golint)
    • Line 33: warning: exported method SelectQuery.From should have comment or be unexported (golint)
    • Line 38: warning: exported method SelectQuery.Where should have comment or be unexported (golint)
    • Line 43: warning: exported method SelectQuery.OrderBy should have comment or be unexported (golint)
    • Line 60: warning: exported method SelectQuery.ToSQL should have comment or be unexported (golint)
    • lingo/check/checkers.go
    • Line 7: warning: exported function IsValueNilOrEmpty should have comment or be unexported (golint)
    • Line 21: warning: exported function IsValueNilOrBlank should have comment or be unexported (golint)
    • Line 35: warning: exported function AreValuesNilOrBlank should have comment or be unexported (golint)
    • lingo/execute/sql.go
    • Line 10: warning: exported type ExecSQLInTx should have comment or be unexported (golint)
    • Line 12: warning: exported type SQL should have comment or be unexported (golint)
    • Line 18: warning: exported type TxSQL should have comment or be unexported (golint)
    • Line 24: warning: exported type SQLQuery should have comment or be unexported (golint)
    • Line 30: warning: exported function NewSQL should have comment or be unexported (golint)
    • Line 89: warning: exported type ActiveDBTx should have comment or be unexported (golint)
    • Line 94: warning: exported function NewSQLTx should have comment or be unexported (golint)
    • lingo/internal/generator/generator.go
    • Line 12: warning: exported type Settings should have comment or be unexported (golint)
    • Line 21: warning: exported type Parser should have comment or be unexported (golint)
    • Line 27: warning: exported type ForeignKey should have comment or be unexported (golint)
    • Line 31: warning: exported type Column should have comment or be unexported (golint)
    • Line 37: warning: exported function Generate 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!


misspell99%

Misspell Finds commonly misspelled English words