Preparing report...

Report for github.com/google/shenzhen-go

A+    Excellent!    Found 17 issues across 108 files

Tweet

gofmt97%

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!


gocyclo97%

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.

    • shenzhen-go/source/type.go
    • Line 709: warning: cyclomatic complexity 34 of function isEqual() is high (> 15) (gocyclo)
    • Line 159: warning: cyclomatic complexity 30 of function (cloneWalker).Visit() is high (> 15) (gocyclo)
    • Line 804: warning: cyclomatic complexity 17 of function shallowCopy() is high (> 15) (gocyclo)
    • Line 598: warning: cyclomatic complexity 17 of function (modIdent).refine() is high (> 15) (gocyclo)

golint90%

Golint is a linter for Go source code.

    • shenzhen-go/examples/cache/generated.go
    • Line 14: warning: exported function Cache should have comment or be unexported (golint)
    • Line 133: warning: exported function Get_random_items should have comment or be unexported (golint)
    • Line 133: warning: don't use underscores in Go names; func Get_random_items should be GetRandomItems (golint)
    • Line 152: warning: exported function Print_hits should have comment or be unexported (golint)
    • Line 152: warning: don't use underscores in Go names; func Print_hits should be PrintHits (golint)
    • Line 164: warning: exported function Print_misses should have comment or be unexported (golint)
    • Line 164: warning: don't use underscores in Go names; func Print_misses should be PrintMisses (golint)
    • Line 175: warning: exported function Put_random_sizes should have comment or be unexported (golint)
    • Line 175: warning: don't use underscores in Go names; func Put_random_sizes should be PutRandomSizes (golint)
    • shenzhen-go/examples/http_hammer/generated.go
    • Line 19: warning: exported function Aggregate_and_print should have comment or be unexported (golint)
    • Line 19: warning: don't use underscores in Go names; func Aggregate_and_print should be AggregateAndPrint (golint)
    • Line 42: warning: exported function HTTP_GET_requests should have comment or be unexported (golint)
    • Line 42: warning: don't use underscores in Go names; func HTTP_GET_requests should be HTTPGETRequests (golint)
    • Line 86: warning: exported function Wait_for_C should have comment or be unexported (golint)
    • Line 86: warning: don't use underscores in Go names; func Wait_for_C should be WaitForC (golint)
    • shenzhen-go/examples/http_server/generated.go
    • Line 154: warning: exported function Cache should have comment or be unexported (golint)
    • Line 316: warning: exported function Duration should have comment or be unexported (golint)
    • Line 350: warning: exported function Error should have comment or be unexported (golint)
    • Line 375: warning: exported function Extract_parameters should have comment or be unexported (golint)
    • Line 375: warning: don't use underscores in Go names; func Extract_parameters should be ExtractParameters (golint)
    • Line 430: warning: exported function Generate_a_Mandelbrot should have comment or be unexported (golint)
    • Line 430: warning: don't use underscores in Go names; func Generate_a_Mandelbrot should be GenerateAMandelbrot (golint)
    • Line 521: warning: exported function HTTP_Server should have comment or be unexported (golint)
    • Line 521: warning: don't use underscores in Go names; func HTTP_Server should be HTTPServer (golint)
    • Line 550: warning: exported function Handle_ should have comment or be unexported (golint)
    • Line 550: warning: don't use underscores in Go names; func Handle_ should be Handle (golint)
    • Line 624: warning: exported function Log_errors should have comment or be unexported (golint)
    • Line 624: warning: don't use underscores in Go names; func Log_errors should be LogErrors (golint)
    • Line 632: warning: exported function Mandelbrot_duration should have comment or be unexported (golint)
    • Line 632: warning: don't use underscores in Go names; func Mandelbrot_duration should be MandelbrotDuration (golint)
    • Line 666: warning: exported function Metrics should have comment or be unexported (golint)
    • Line 685: warning: exported function Mux should have comment or be unexported (golint)
    • Line 743: warning: exported function Queue should have comment or be unexported (golint)
    • Line 789: warning: exported function Serve_from_cache should have comment or be unexported (golint)
    • Line 789: warning: don't use underscores in Go names; func Serve_from_cache should be ServeFromCache (golint)
    • Line 827: warning: exported function Server_manager should have comment or be unexported (golint)
    • Line 827: warning: don't use underscores in Go names; func Server_manager should be ServerManager (golint)
    • shenzhen-go/examples/demo/generated.go
    • Line 12: warning: comment on exported function Node_1 should be of the form "Node_1 ..." (golint)
    • Line 13: warning: don't use underscores in Go names; func Node_1 should be Node1 (golint)
    • Line 25: warning: comment on exported function Node_2 should be of the form "Node_2 ..." (golint)
    • Line 26: warning: don't use underscores in Go names; func Node_2 should be Node2 (golint)
    • shenzhen-go/examples/broadcast_gather/generated.go
    • Line 2: warning: don't use an underscore in package name (golint)
    • Line 12: warning: exported function Broadcast should have comment or be unexported (golint)
    • Line 26: warning: exported function Gather should have comment or be unexported (golint)
    • Line 54: warning: exported function Print_every_input should have comment or be unexported (golint)
    • Line 54: warning: don't use underscores in Go names; func Print_every_input should be PrintEveryInput (golint)
    • Line 69: warning: exported function Send_42_once_and_close should have comment or be unexported (golint)
    • Line 69: warning: don't use underscores in Go names; func Send_42_once_and_close should be Send42OnceAndClose (golint)
    • shenzhen-go/examples/queue/generated.go
    • Line 13: warning: exported function Generate_numbers should have comment or be unexported (golint)
    • Line 13: warning: don't use underscores in Go names; func Generate_numbers should be GenerateNumbers (golint)
    • Line 22: warning: exported function Print_survivors should have comment or be unexported (golint)
    • Line 22: warning: don't use underscores in Go names; func Print_survivors should be PrintSurvivors (golint)
    • Line 33: warning: exported function Queue should have comment or be unexported (golint)
    • shenzhen-go/examples/transform/generated.go
    • Line 12: warning: exported function Generate_some_numbers should have comment or be unexported (golint)
    • Line 12: warning: don't use underscores in Go names; func Generate_some_numbers should be GenerateSomeNumbers (golint)
    • Line 23: warning: exported function Multiply_numbers_by_3 should have comment or be unexported (golint)
    • Line 23: warning: don't use underscores in Go names; func Multiply_numbers_by_3 should be MultiplyNumbersBy3 (golint)
    • Line 41: warning: exported function Print_numbers should have comment or be unexported (golint)
    • Line 41: warning: don't use underscores in Go names; func Print_numbers should be PrintNumbers (golint)
    • shenzhen-go/examples/keycount/generated.go
    • Line 15: warning: exported function Count_words should have comment or be unexported (golint)
    • Line 15: warning: don't use underscores in Go names; func Count_words should be CountWords (golint)
    • Line 34: warning: exported function Get_words should have comment or be unexported (golint)
    • Line 34: warning: don't use underscores in Go names; func Get_words should be GetWords (golint)
    • Line 47: warning: exported function Print_summary should have comment or be unexported (golint)
    • Line 47: warning: don't use underscores in Go names; func Print_summary should be PrintSummary (golint)

ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


misspell98%

Misspell Finds commonly misspelled English words