Preparing report...

Report for github.com/nanovms/ops

(v0.0.0-20241216160039-7d729b03c8a7)

A+    Excellent!    Found 43 issues across 251 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!


gofmt100%

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

No problems detected. Good job!


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.

    • cmd/cmd_image.go
    • Line 224: warning: cyclomatic complexity 29 of function imageDeleteCommandHandler() is high (> 15) (gocyclo)
    • cmd/flags_build_image.go
    • Line 35: warning: cyclomatic complexity 26 of function (*BuildImageCommandFlags).MergeToConfig() is high (> 15) (gocyclo)
    • Line 135: warning: cyclomatic complexity 16 of function NewBuildImageCommandFlags() is high (> 15) (gocyclo)
    • provider/onprem/onprem_instance.go
    • Line 34: warning: cyclomatic complexity 22 of function (*OnPrem).createInstance() is high (> 15) (gocyclo)
    • Line 421: warning: cyclomatic complexity 17 of function (*OnPrem).GetInstances() is high (> 15) (gocyclo)
    • cmd/flags_pkg.go
    • Line 161: warning: cyclomatic complexity 16 of function (*PkgCommandFlags).MergeToConfig() is high (> 15) (gocyclo)
    • lepton/utils.go
    • Line 22: warning: cyclomatic complexity 23 of function isDomainValid() is high (> 15) (gocyclo)
    • fs/tfs.go
    • Line 856: warning: cyclomatic complexity 32 of function (*tfsFileReader).Read() is high (> 15) (gocyclo)
    • Line 117: warning: cyclomatic complexity 30 of function (*tfs).readLogExt() is high (> 15) (gocyclo)
    • lepton/image.go
    • Line 257: warning: cyclomatic complexity 26 of function setManifestFromConfig() is high (> 15) (gocyclo)
    • lepton/package.go
    • Line 89: warning: cyclomatic complexity 22 of function DownloadPackage() is high (> 15) (gocyclo)
    • Line 363: warning: cyclomatic complexity 20 of function ExtractPackage() is high (> 15) (gocyclo)
    • crossbuild/env.go
    • Line 213: warning: cyclomatic complexity 20 of function (*Environment).GetFiles() is high (> 15) (gocyclo)
    • cmd/cmd_pkg.go
    • Line 102: warning: cyclomatic complexity 18 of function cmdListPackages() is high (> 15) (gocyclo)
    • cmd/flags_run_local_instance.go
    • Line 45: warning: cyclomatic complexity 31 of function (*RunLocalInstanceCommandFlags).MergeToConfig() is high (> 15) (gocyclo)
    • Line 176: warning: cyclomatic complexity 20 of function NewRunLocalInstanceCommandFlags() is high (> 15) (gocyclo)
    • fs/mkfs.go
    • Line 330: warning: cyclomatic complexity 25 of function writeUefiPart() is high (> 15) (gocyclo)
    • Line 220: warning: cyclomatic complexity 24 of function (*MkfsCommand).Execute() is high (> 15) (gocyclo)
    • lepton/volume.go
    • Line 31: warning: cyclomatic complexity 20 of function (NanosVolume).MatchedByQueries() is high (> 15) (gocyclo)
    • lepton/push.go
    • Line 77: warning: cyclomatic complexity 16 of function CreateTarGz() is high (> 15) (gocyclo)
    • cmd/cmd_deploy.go
    • Line 36: warning: cyclomatic complexity 18 of function deployCommandHandler() is high (> 15) (gocyclo)
    • cmd/cmd_env.go
    • Line 81: warning: cyclomatic complexity 17 of function envBuild() is high (> 15) (gocyclo)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


misspell91%

Misspell Finds commonly misspelled English words

    • cmd/cmd_env.go
    • Line 73: warning: "Enviroment" is a misspelling of "Environment" (misspell)
    • Line 196: warning: "Enviroment" is a misspelling of "Environment" (misspell)