Preparing report...

Report for github.com/rkt/rkt

(v1.30.0)

A    Great!    Found 175 issues across 376 files

Tweet

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!


gofmt61%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


gocyclo86%

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.

    • rkt/fetch_test.go
    • Line 454: warning: cyclomatic complexity 29 of function TestFetchImageCache() is high (> 15) (gocyclo)
    • Line 159: warning: cyclomatic complexity 19 of function TestDownloading() is high (> 15) (gocyclo)
    • store/imagestore/store.go
    • Line 168: warning: cyclomatic complexity 21 of function NewStore() is high (> 15) (gocyclo)
    • Line 619: warning: cyclomatic complexity 18 of function (*Store).GetACI() is high (> 15) (gocyclo)
    • store/imagestore/store_test.go
    • Line 347: warning: cyclomatic complexity 16 of function TestRemoveACI() is high (> 15) (gocyclo)
    • Line 60: warning: cyclomatic complexity 16 of function TestResolveKey() is high (> 15) (gocyclo)
    • rkt/prepare.go
    • Line 85: warning: cyclomatic complexity 37 of function runPrepare() is high (> 15) (gocyclo)
    • pkg/keystore/keystore_test.go
    • Line 104: warning: cyclomatic complexity 16 of function TestCheckSignature() is high (> 15) (gocyclo)
    • Line 41: warning: cyclomatic complexity 16 of function TestStoreTrustedKey() is high (> 15) (gocyclo)
    • pkg/tar/tar.go
    • Line 140: warning: cyclomatic complexity 33 of function extractFile() is high (> 15) (gocyclo)
    • rkt/list.go
    • Line 57: warning: cyclomatic complexity 27 of function runList() is high (> 15) (gocyclo)
    • stage1/iottymux/iottymux.go
    • Line 321: warning: cyclomatic complexity 20 of function actionIOMux() is high (> 15) (gocyclo)
    • Line 137: warning: cyclomatic complexity 20 of function actionAttach() is high (> 15) (gocyclo)
    • stage1/init/common/units.go
    • Line 512: warning: cyclomatic complexity 38 of function (*UnitWriter).appSystemdUnit() is high (> 15) (gocyclo)
    • Line 206: warning: cyclomatic complexity 33 of function (*UnitWriter).SetupAppIO() is high (> 15) (gocyclo)
    • pkg/pod/pods.go
    • Line 195: warning: cyclomatic complexity 20 of function getPod() is high (> 15) (gocyclo)
    • Line 886: warning: cyclomatic complexity 19 of function WalkPods() is high (> 15) (gocyclo)
    • stage0/common.go
    • Line 113: warning: cyclomatic complexity 20 of function generateRuntimeApp() is high (> 15) (gocyclo)
    • stage1/gc/gc.go
    • Line 140: warning: cyclomatic complexity 16 of function cleanupV1Cgroups() is high (> 15) (gocyclo)
    • stage1/init/init.go
    • Line 533: warning: cyclomatic complexity 56 of function stage1() is high (> 15) (gocyclo)
    • Line 266: warning: cyclomatic complexity 43 of function getArgsEnv() is high (> 15) (gocyclo)
    • rkt/api_service.go
    • Line 210: warning: cyclomatic complexity 25 of function satisfiesPodFilter() is high (> 15) (gocyclo)
    • Line 518: warning: cyclomatic complexity 25 of function fillPodDetails() is high (> 15) (gocyclo)
    • Line 716: warning: cyclomatic complexity 19 of function satisfiesImageFilter() is high (> 15) (gocyclo)
    • rkt/status.go
    • Line 171: warning: cyclomatic complexity 22 of function printStatus() is high (> 15) (gocyclo)
    • rkt/export.go
    • Line 57: warning: cyclomatic complexity 19 of function runExport() is high (> 15) (gocyclo)
    • rkt/run.go
    • Line 178: warning: cyclomatic complexity 50 of function runRun() is high (> 15) (gocyclo)
    • Line 597: warning: cyclomatic complexity 18 of function parseDNSFlags() is high (> 15) (gocyclo)
    • rkt/gc.go
    • Line 251: warning: cyclomatic complexity 18 of function deletePod() is high (> 15) (gocyclo)
    • tests/rkt_api_service_test.go
    • Line 540: warning: cyclomatic complexity 21 of function NewAPIServiceCgroupTest() is high (> 15) (gocyclo)
    • Line 318: warning: cyclomatic complexity 19 of function NewAPIServiceListInspectPodsTest() is high (> 15) (gocyclo)
    • tests/rkt_app_sandbox_test.go
    • Line 233: warning: cyclomatic complexity 18 of function TestAppSandboxRestart() is high (> 15) (gocyclo)
    • Line 100: warning: cyclomatic complexity 16 of function TestAppSandboxMultipleApps() is high (> 15) (gocyclo)
    • stage1_fly/run/main.go
    • Line 247: warning: cyclomatic complexity 49 of function stage1() is high (> 15) (gocyclo)
    • Line 124: warning: cyclomatic complexity 24 of function evaluateMounts() is high (> 15) (gocyclo)
    • rkt/attach.go
    • Line 119: warning: cyclomatic complexity 21 of function createStage1AttachFlags() is high (> 15) (gocyclo)
    • stage0/run.go
    • Line 553: warning: cyclomatic complexity 33 of function Run() is high (> 15) (gocyclo)
    • Line 281: warning: cyclomatic complexity 23 of function prepareIsolators() is high (> 15) (gocyclo)
    • Line 183: warning: cyclomatic complexity 17 of function generatePodManifest() is high (> 15) (gocyclo)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!