Report for github.com/newrelic/tutone

A+    Excellent!    Found 21 issues across 36 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!


gocyclo91%

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.


golint44%

Golint is a linter for Go source code.

    • tutone/pkg/fetch/http.go
    • Line 18: warning: exported const DefaultHTTPTimeout should have comment (or a comment on this block) or be unexported (golint)
    • Line 22: warning: exported type GraphqlQuery should have comment or be unexported (golint)
    • Line 27: warning: exported type Endpoint should have comment or be unexported (golint)
    • Line 33: warning: exported type AuthConfig should have comment or be unexported (golint)
    • Line 39: warning: exported type HTTPConfig should have comment or be unexported (golint)
    • Line 43: warning: exported function NewEndpoint should have comment or be unexported (golint)
    • Line 106: warning: comment on exported method Endpoint.FetchSchemaTypes should be of the form "FetchSchemaTypes ..." (golint)
    • Line 121: warning: exported method Endpoint.FetchType should have comment or be unexported (golint)
    • tutone/internal/schema/field.go
    • Line 85: warning: exported method Field.IsPrimitiveType should have comment or be unexported (golint)
    • Line 104: warning: comment on exported method Field.IsScalarID should be of the form "IsScalarID ..." (golint)
    • Line 109: warning: comment on exported method Field.IsRequired should be of the form "IsRequired ..." (golint)
    • Line 114: warning: exported method Field.IsEnum should have comment or be unexported (golint)
    • Line 122: warning: exported method Field.HasRequiredArg should have comment or be unexported (golint)
    • tutone/pkg/lang/golang.go
    • Line 26: warning: exported type GoStruct should have comment or be unexported (golint)
    • Line 35: warning: exported type GoStructField should have comment or be unexported (golint)
    • Line 46: warning: exported type GoEnum should have comment or be unexported (golint)
    • Line 52: warning: exported type GoEnumValue should have comment or be unexported (golint)
    • Line 57: warning: exported type GoScalar should have comment or be unexported (golint)
    • Line 63: warning: exported type GoInterface should have comment or be unexported (golint)
    • Line 71: warning: exported type GoInterfacePossibleType should have comment or be unexported (golint)
    • Line 76: warning: exported type GoMethod should have comment or be unexported (golint)
    • Line 86: warning: exported type GoMethodSignature should have comment or be unexported (golint)
    • Line 95: warning: exported type GoMethodInputType should have comment or be unexported (golint)
    • Line 100: warning: exported type QueryVar should have comment or be unexported (golint)
    • Line 193: warning: exported function GenerateGoTypesForPackage should have comment or be unexported (golint)
    • tutone/generators/command/generator.go
    • Line 15: warning: exported type Generator should have comment or be unexported (golint)
    • Line 19: warning: exported method Generator.Generate should have comment or be unexported (golint)
    • Line 35: warning: exported method Generator.Execute should have comment or be unexported (golint)
    • tutone/pkg/fetch/command.go
    • Line 14: warning: exported const DefaultAPIKeyEnv should have comment (or a comment on this block) or be unexported (golint)
    • Line 20: warning: exported var Command should have comment or be unexported (golint)
    • Line 40: warning: exported function Fetch should have comment or be unexported (golint)
    • tutone/internal/schema/query.go
    • Line 41: warning: comment on exported type QueryTypeVars should be of the form "QueryTypeVars ..." (with optional leading article) (golint)
    • Line 46: warning: exported type QueryResponse should have comment or be unexported (golint)
    • tutone/internal/schema/type.go
    • Line 79: warning: exported method Type.GetQueryStringFields should have comment or be unexported (golint)
    • Line 192: warning: exported method Type.GetField should have comment or be unexported (golint)
    • tutone/internal/schema/kind.go
    • Line 3: warning: exported type Kind should have comment or be unexported (golint)
    • Line 6: warning: exported const KindENUM should have comment (or a comment on this block) or be unexported (golint)
    • tutone/pkg/lang/command.go
    • Line 3: warning: comment on exported type CommandGenerator should be of the form "CommandGenerator ..." (with optional leading article) (golint)
    • Line 10: warning: exported type InputObject should have comment or be unexported (golint)
    • Line 15: warning: exported type Command should have comment or be unexported (golint)
    • Line 31: warning: exported type CommandFlag should have comment or be unexported (golint)
    • Line 45: warning: exported type CommandExampleData should have comment or be unexported (golint)
    • tutone/internal/config/config.go
    • Line 75: warning: exported type Command should have comment or be unexported (golint)
    • Line 89: warning: exported type CommandFlag should have comment or be unexported (golint)
    • Line 121: warning: exported type EndpointConfig should have comment or be unexported (golint)
    • Line 147: warning: exported const DefaultCacheEnable should have comment (or a comment on this block) or be unexported (golint)
    • Line 178: warning: exported method PackageConfig.GetDestinationPath should have comment or be unexported (golint)
    • tutone/internal/codegen/codegen.go
    • Line 17: warning: exported type CodeGen should have comment or be unexported (golint)
    • Line 26: warning: exported type Path should have comment or be unexported (golint)
    • Line 85: warning: exported method CodeGen.WriteFileFromTemplateString should have comment or be unexported (golint)
    • tutone/pkg/generate/command.go
    • Line 13: warning: exported const DefaultGenerateOutputFile should have comment (or a comment on this block) or be unexported (golint)
    • Line 21: warning: exported var Command should have comment or be unexported (golint)
    • tutone/internal/schema/schema.go
    • Line 52: warning: exported function ParseResponse should have comment or be unexported (golint)
    • Line 132: warning: exported method Schema.LookupRootMutationTypeFieldByName should have comment or be unexported (golint)
    • Line 142: warning: exported method Schema.LookupRootQueryTypeFieldByName should have comment or be unexported (golint)
    • Line 165: warning: exported method Schema.LookupMutationByName should have comment or be unexported (golint)
    • tutone/internal/schema/typeref.go
    • Line 93: warning: exported method TypeRef.IsInputObject should have comment or be unexported (golint)
    • Line 106: warning: exported method TypeRef.IsScalarID should have comment or be unexported (golint)
    • Line 159: warning: comment on exported method TypeRef.IsInterface should be of the form "IsInterface ..." (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!