Preparing report...

Report for k8s.io/release

A+    Excellent!    Found 58 issues across 254 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!


gocyclo96%

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.


golint77%

Golint is a linter for Go source code.

    • /k8s.io/release/pkg/gcp/auth/auth.go
    • Line 27: warning: exported function GetCurrentGCPUser should have comment or be unexported (golint)
    • Line 48: warning: exported function ConfigureDocker should have comment or be unexported (golint)
    • Line 60: warning: exported function NormalizeGCPUser should have comment or be unexported (golint)
    • /k8s.io/release/pkg/git/git.go
    • Line 48: warning: exported const DefaultGithubOrg should have comment (or a comment on this block) or be unexported (golint)
    • Line 218: warning: comment on exported type Repo should be of the form "Repo ..." (with optional leading article) (golint)
    • Line 258: warning: comment on exported method Repo.SetDry should be of the form "SetDry ..." (golint)
    • Line 281: warning: exported function LSRemoteExec should have comment or be unexported (golint)
    • Line 435: warning: exported method Repo.Cleanup should have comment or be unexported (golint)
    • Line 486: warning: comment on exported method Repo.RevParseShort should be of the form "RevParseShort ..." (golint)
    • Line 533: warning: exported method Repo.LatestNonPatchFinalToMinor should have comment or be unexported (golint)
    • Line 694: warning: exported method Repo.MergeBase should have comment or be unexported (golint)
    • /k8s.io/release/pkg/anago/stage.go
    • Line 258: warning: exported method DefaultStage.Submit should have comment or be unexported (golint)
    • Line 268: warning: exported method DefaultStage.InitLogFile should have comment or be unexported (golint)
    • Line 281: warning: exported method DefaultStage.InitState should have comment or be unexported (golint)
    • Line 285: warning: exported method DefaultStage.ValidateOptions should have comment or be unexported (golint)
    • Line 292: warning: exported method DefaultStage.CheckPrerequisites should have comment or be unexported (golint)
    • Line 296: warning: exported method DefaultStage.CheckReleaseBranchState should have comment or be unexported (golint)
    • Line 309: warning: exported method DefaultStage.GenerateReleaseVersion should have comment or be unexported (golint)
    • Line 324: warning: exported method DefaultStage.PrepareWorkspace should have comment or be unexported (golint)
    • Line 331: warning: exported method DefaultStage.TagRepository should have comment or be unexported (golint)
    • Line 466: warning: exported method DefaultStage.Build should have comment or be unexported (golint)
    • Line 481: warning: exported method DefaultStage.GenerateChangelog should have comment or be unexported (golint)
    • Line 503: warning: exported method DefaultStage.StageArtifacts should have comment or be unexported (golint)
    • /k8s.io/release/pkg/spdx/file.go
    • Line 64: warning: exported function NewFile should have comment or be unexported (golint)
    • Line 71: warning: exported method File.Options should have comment or be unexported (golint)
    • Line 75: warning: comment on exported type FileOptions should be of the form "FileOptions ..." (with optional leading article) (golint)
    • /k8s.io/release/pkg/object/gcs.go
    • Line 30: warning: exported type GCS should have comment or be unexported (golint)
    • Line 44: warning: exported function NewGCS should have comment or be unexported (golint)
    • Line 53: warning: exported method GCS.SetOptions should have comment or be unexported (golint)
    • Line 59: warning: exported method GCS.WithConcurrent should have comment or be unexported (golint)
    • Line 65: warning: exported method GCS.WithRecursive should have comment or be unexported (golint)
    • Line 71: warning: exported method GCS.WithNoClobber should have comment or be unexported (golint)
    • Line 77: warning: exported method GCS.WithAllowMissing should have comment or be unexported (golint)
    • Line 83: warning: exported method GCS.Concurrent should have comment or be unexported (golint)
    • Line 87: warning: exported method GCS.Recursive should have comment or be unexported (golint)
    • Line 91: warning: exported method GCS.NoClobber should have comment or be unexported (golint)
    • Line 95: warning: exported method GCS.AllowMissing should have comment or be unexported (golint)
    • Line 107: warning: comment on exported method GCS.CopyToRemote should be of the form "CopyToRemote ..." (golint)
    • Line 261: warning: comment on exported method GCS.NormalizePath should be of the form "NormalizePath ..." (golint)
    • /k8s.io/release/pkg/announce/options.go
    • Line 19: warning: exported type Options should have comment or be unexported (golint)
    • Line 43: warning: exported method Options.WithWorkDir should have comment or be unexported (golint)
    • Line 48: warning: exported method Options.WithTag should have comment or be unexported (golint)
    • Line 53: warning: exported method Options.WithBranch should have comment or be unexported (golint)
    • Line 58: warning: exported method Options.WithChangelogPath should have comment or be unexported (golint)
    • Line 63: warning: exported method Options.WithChangelogHTML should have comment or be unexported (golint)
    • Line 68: warning: exported method Options.WithChangelogFile should have comment or be unexported (golint)
    • /k8s.io/release/pkg/changelog/const.go
    • Line 20: warning: comment on exported const RepoChangelogDir should be of the form "RepoChangelogDir ..." (golint)
    • Line 25: warning: exported const TocEnd should have comment (or a comment on this block) or be unexported (golint)
    • /k8s.io/release/cmd/krel/cmd/testgrid.go
    • Line 45: warning: exported type TestGridOptions should have comment or be unexported (golint)
    • Line 57: warning: exported type TestgridJobInfo should have comment or be unexported (golint)
    • Line 62: warning: exported type TestGridJob should have comment or be unexported (golint)
    • Line 266: warning: exported method TestGridOptions.Validate should have comment or be unexported (golint)
    • /k8s.io/release/pkg/kubepkg/kubepkg.go
    • Line 39: warning: exported type ChannelType should have comment or be unexported (golint)
    • Line 42: warning: exported const ChannelRelease should have comment (or a comment on this block) or be unexported (golint)
    • Line 86: warning: exported type Client should have comment or be unexported (golint)
    • Line 91: warning: exported function New should have comment or be unexported (golint)
    • Line 98: warning: exported method Client.SetImpl should have comment or be unexported (golint)
    • Line 104: warning: comment on exported type Impl should be of the form "Impl ..." (with optional leading article) (golint)
    • Line 134: warning: exported type Build should have comment or be unexported (golint)
    • Line 141: warning: exported type PackageDefinition should have comment or be unexported (golint)
    • Line 170: warning: exported method Client.ConstructBuilds should have comment or be unexported (golint)
    • Line 215: warning: exported method Client.WalkBuilds should have comment or be unexported (golint)
    • Line 414: warning: exported method Client.GetPackageVersion should have comment or be unexported (golint)
    • Line 434: warning: exported method Client.GetKubernetesVersion should have comment or be unexported (golint)
    • Line 453: warning: exported function GetCNIVersion should have comment or be unexported (golint)
    • Line 482: warning: exported method Client.GetCRIToolsVersion should have comment or be unexported (golint)
    • Line 559: warning: exported method Client.GetDownloadLinkBase should have comment or be unexported (golint)
    • Line 571: warning: exported method Client.GetCIBuildsDownloadLinkBase should have comment or be unexported (golint)
    • Line 588: warning: exported function GetDefaultReleaseDownloadLinkBase should have comment or be unexported (golint)
    • Line 600: warning: exported function GetDependencies should have comment or be unexported (golint)
    • Line 624: warning: exported function GetCNIDownloadLink should have comment or be unexported (golint)
    • /k8s.io/release/pkg/release/release.go
    • Line 47: warning: exported const DefaultToolRepo should have comment (or a comment on this block) or be unexported (golint)
    • Line 50: warning: comment on exported const DefaultKubernetesStagingProject should be of the form "DefaultKubernetesStagingProject ..." (golint)
    • Line 64: warning: comment on exported const SourcesTar should be of the form "SourcesTar ..." (golint)
    • Line 67: warning: comment on exported const StagePath should be of the form "StagePath ..." (golint)
    • Line 70: warning: comment on exported const ImagesPath should be of the form "ImagesPath ..." (golint)
    • Line 107: warning: comment on exported const GCRIOPathProd should be of the form "GCRIOPathProd ..." (golint)
    • Line 110: warning: comment on exported const GCRIOPathStaging should be of the form "GCRIOPathStaging ..." (golint)
    • Line 113: warning: comment on exported const GCRIOPathMock should be of the form "GCRIOPathMock ..." (golint)
    • Line 119: warning: comment on exported const BazelBuildDir should be of the form "BazelBuildDir ..." (golint)
    • Line 122: warning: comment on exported const ArchivePath should be of the form "ArchivePath ..." (golint)
    • Line 125: warning: comment on exported const PubBotRepoOrg should be of the form "PubBotRepoOrg ..." (golint)
    • Line 134: warning: exported var ManifestImages should have comment or be unexported (golint)
    • Line 225: warning: exported function GetWorkspaceVersion should have comment or be unexported (golint)
    • Line 554: warning: comment on exported function DockerHubLogin should be of the form "DockerHubLogin ..." (golint)
    • /k8s.io/release/pkg/notes/dependencies.go
    • Line 28: warning: exported type Dependencies should have comment or be unexported (golint)
    • Line 32: warning: exported function NewDependencies should have comment or be unexported (golint)
    • Line 36: warning: comment on exported type MoDiff should be of the form "MoDiff ..." (with optional leading article) (golint)
    • Line 59: warning: comment on exported method Dependencies.ChangesForURL should be of the form "ChangesForURL ..." (golint)
    • /k8s.io/release/pkg/kubepkg/options/options.go
    • Line 29: warning: exported type Options should have comment or be unexported (golint)
    • Line 47: warning: exported type BuildType should have comment or be unexported (golint)
    • Line 50: warning: exported const BuildDeb should have comment (or a comment on this block) or be unexported (golint)
    • Line 73: warning: exported function New should have comment or be unexported (golint)
    • Line 84: warning: exported method Options.WithBuildType should have comment or be unexported (golint)
    • Line 89: warning: exported method Options.WithRevision should have comment or be unexported (golint)
    • Line 94: warning: exported method Options.WithKubeVersion should have comment or be unexported (golint)
    • Line 99: warning: exported method Options.WithCNIVersion should have comment or be unexported (golint)
    • Line 104: warning: exported method Options.WithCRIToolsVersion should have comment or be unexported (golint)
    • Line 109: warning: exported method Options.WithPackages should have comment or be unexported (golint)
    • Line 114: warning: exported method Options.WithChannels should have comment or be unexported (golint)
    • Line 119: warning: exported method Options.WithArchitectures should have comment or be unexported (golint)
    • Line 124: warning: exported method Options.WithReleaseDownloadLinkBase should have comment or be unexported (golint)
    • Line 129: warning: exported method Options.WithTemplateDir should have comment or be unexported (golint)
    • Line 134: warning: exported method Options.WithSpecOnly should have comment or be unexported (golint)
    • Line 139: warning: exported method Options.BuildType should have comment or be unexported (golint)
    • Line 143: warning: exported method Options.Revision should have comment or be unexported (golint)
    • Line 147: warning: exported method Options.KubeVersion should have comment or be unexported (golint)
    • Line 151: warning: exported method Options.CNIVersion should have comment or be unexported (golint)
    • Line 155: warning: exported method Options.CRIToolsVersion should have comment or be unexported (golint)
    • Line 159: warning: exported method Options.Packages should have comment or be unexported (golint)
    • Line 163: warning: exported method Options.Channels should have comment or be unexported (golint)
    • Line 167: warning: exported method Options.Architectures should have comment or be unexported (golint)
    • Line 171: warning: exported method Options.ReleaseDownloadLinkBase should have comment or be unexported (golint)
    • Line 175: warning: exported method Options.TemplateDir should have comment or be unexported (golint)
    • Line 179: warning: exported method Options.SpecOnly should have comment or be unexported (golint)
    • /k8s.io/release/pkg/gcp/gcb/gcb.go
    • Line 81: warning: exported type Options should have comment or be unexported (golint)
    • Line 104: warning: comment on exported type Repository should be of the form "Repository ..." (with optional leading article) (golint)
    • Line 111: warning: comment on exported type Version should be of the form "Version ..." (with optional leading article) (golint)
    • Line 116: warning: comment on exported type ListJobs should be of the form "ListJobs ..." (with optional leading article) (golint)
    • Line 127: warning: comment on exported type Release should be of the form "Release ..." (with optional leading article) (golint)
    • /k8s.io/release/pkg/notes/notes.go
    • Line 48: warning: exported const DefaultOrg should have comment (or a comment on this block) or be unexported (golint)
    • Line 57: warning: exported type Notes should have comment or be unexported (golint)
    • Line 58: warning: exported type Kind should have comment or be unexported (golint)
    • Line 62: warning: exported const KindAPIChange should have comment (or a comment on this block) or be unexported (golint)
    • Line 133: warning: exported type Documentation should have comment or be unexported (golint)
    • Line 144: warning: exported type DocType should have comment or be unexported (golint)
    • Line 147: warning: exported const DocTypeExternal should have comment (or a comment on this block) or be unexported (golint)
    • Line 165: warning: comment on exported type ReleaseNotesByPR should be of the form "ReleaseNotesByPR ..." (with optional leading article) (golint)
    • Line 195: warning: exported type Result should have comment or be unexported (golint)
    • Line 200: warning: exported type Gatherer should have comment or be unexported (golint)
    • Line 391: warning: exported function DocumentationFromString should have comment or be unexported (golint)
    • /k8s.io/release/pkg/spdx/builder.go
    • Line 30: warning: exported function NewDocBuilder should have comment or be unexported (golint)
    • Line 63: warning: exported type DocGenerateOptions should have comment or be unexported (golint)
    • Line 76: warning: exported method DocGenerateOptions.Validate should have comment or be unexported (golint)
    • Line 85: warning: exported type DocBuilderOptions should have comment or be unexported (golint)
    • Line 93: warning: exported type DocBuilderImplementation should have comment or be unexported (golint)
    • /k8s.io/release/pkg/gcp/build/build.go
    • Line 49: warning: exported const DefaultCloudbuildFile should have comment (or a comment on this block) or be unexported (golint)
    • Line 52: warning: comment on exported type Options should be of the form "Options ..." (with optional leading article) (golint)
    • Line 78: warning: exported function PrepareBuilds should have comment or be unexported (golint)
    • Line 121: warning: exported method Options.ValidateConfigDir should have comment or be unexported (golint)
    • Line 182: warning: exported function RunSingleJob should have comment or be unexported (golint)
    • Line 290: warning: exported function RunBuildJobs should have comment or be unexported (golint)
    • Line 364: warning: exported function ListJobs should have comment or be unexported (golint)
    • Line 389: warning: exported function GetJobsByTag should have comment or be unexported (golint)
    • /k8s.io/release/pkg/spdx/gomod.go
    • Line 34: warning: exported const GoModFileName should have comment (or a comment on this block) or be unexported (golint)
    • Line 37: warning: comment on exported function NewGoModuleFromPath should be of the form "NewGoModuleFromPath ..." (golint)
    • Line 47: warning: exported function NewGoModule should have comment or be unexported (golint)
    • Line 62: warning: exported type GoModuleOptions should have comment or be unexported (golint)
    • Line 74: warning: comment on exported method GoPackage.ToSPDXPackage should be of the form "ToSPDXPackage ..." (golint)
    • Line 88: warning: exported type GoModImplementation should have comment or be unexported (golint)
    • Line 97: warning: comment on exported method GoModule.Open should be of the form "Open ..." (golint)
    • Line 165: warning: exported type GoModDefaultImpl should have comment or be unexported (golint)
    • /k8s.io/release/pkg/notes/options/options.go
    • Line 126: warning: exported type RevisionDiscoveryMode should have comment or be unexported (golint)
    • Line 129: warning: exported const RevisionDiscoveryModeNONE should have comment (or a comment on this block) or be unexported (golint)
    • Line 137: warning: exported const FormatJSON should have comment (or a comment on this block) or be unexported (golint)
    • /k8s.io/release/pkg/anago/release.go
    • Line 227: warning: exported method DefaultRelease.Submit should have comment or be unexported (golint)
    • Line 238: warning: exported method DefaultRelease.InitState should have comment or be unexported (golint)
    • Line 242: warning: exported method DefaultRelease.InitLogFile should have comment or be unexported (golint)
    • Line 323: warning: exported method DefaultRelease.ValidateOptions should have comment or be unexported (golint)
    • Line 330: warning: exported method DefaultRelease.CheckPrerequisites should have comment or be unexported (golint)
    • Line 334: warning: exported method DefaultRelease.CheckReleaseBranchState should have comment or be unexported (golint)
    • Line 347: warning: exported method DefaultRelease.GenerateReleaseVersion should have comment or be unexported (golint)
    • Line 362: warning: exported method DefaultRelease.PrepareWorkspace should have comment or be unexported (golint)
    • Line 371: warning: exported method DefaultRelease.PushArtifacts should have comment or be unexported (golint)
    • /k8s.io/release/pkg/cip/cli/run.go
    • Line 31: warning: exported type RunOptions should have comment or be unexported (golint)
    • Line 51: warning: exported const PromoterDefaultThreads should have comment (or a comment on this block) or be unexported (golint)
    • Line 56: warning: comment on exported const PromoterManifestFlag should be of the form "PromoterManifestFlag ..." (golint)
    • Line 64: warning: exported var PromoterAllowedOutputFormats should have comment or be unexported (golint)
    • Line 69: warning: comment on exported function RunPromoteCmd should be of the form "RunPromoteCmd ..." (golint)
    • /k8s.io/release/pkg/spdx/package.go
    • Line 100: warning: exported function NewPackage should have comment or be unexported (golint)
    • Line 107: warning: exported type PackageOptions should have comment or be unexported (golint)
    • Line 111: warning: exported method Package.Options should have comment or be unexported (golint)
    • /k8s.io/release/pkg/spdx/spdx.go
    • Line 41: warning: exported type SPDX should have comment or be unexported (golint)
    • Line 46: warning: exported function NewSPDX should have comment or be unexported (golint)
    • Line 53: warning: exported method SPDX.SetImplementation should have comment or be unexported (golint)
    • Line 57: warning: exported type Options should have comment or be unexported (golint)
    • Line 65: warning: exported method SPDX.Options should have comment or be unexported (golint)
    • Line 76: warning: exported type ArchiveManifest should have comment or be unexported (golint)
    • Line 82: warning: comment on exported type TarballOptions should be of the form "TarballOptions ..." (with optional leading article) (golint)
    • Line 251: warning: comment on exported method SPDX.AnalyzeImageLayer should be of the form "AnalyzeImageLayer ..." (golint)
    • Line 263: warning: comment on exported method SPDX.PullImagesToArchive should be of the form "PullImagesToArchive ..." (golint)
    • /k8s.io/release/pkg/cve/client.go
    • Line 30: warning: exported const Bucket should have comment (or a comment on this block) or be unexported (golint)
    • Line 38: warning: comment on exported const CVEIDRegExp should be of the form "CVEIDRegExp ..." (golint)
    • Line 42: warning: exported type Client should have comment or be unexported (golint)
    • Line 47: warning: exported type ClientOptions should have comment or be unexported (golint)
    • Line 57: warning: exported function NewClient should have comment or be unexported (golint)
    • Line 117: warning: comment on exported method Client.EntryExists should be of the form "EntryExists ..." (golint)
    • /k8s.io/release/pkg/github/github.go
    • Line 63: warning: exported method Options.GetItemsPerPage should have comment or be unexported (golint)
    • Line 74: warning: comment on exported type Client should be of the form "Client ..." (with optional leading article) (golint)
    • Line 203: warning: exported function NewEnterprise should have comment or be unexported (golint)
    • Line 208: warning: exported function NewEnterpriseWithToken should have comment or be unexported (golint)
    • /k8s.io/release/pkg/mail/mail.go
    • Line 35: warning: exported const KubernetesAnnounceGoogleGroup should have comment (or a comment on this block) or be unexported (golint)
    • Line 40: warning: exported type Sender should have comment or be unexported (golint)
    • Line 48: warning: exported function NewSender should have comment or be unexported (golint)
    • Line 61: warning: comment on exported method Sender.SetAPIClient should be of the form "SetAPIClient ..." (golint)
    • Line 66: warning: comment on exported type SendClient should be of the form "SendClient ..." (with optional leading article) (golint)
    • Line 72: warning: comment on exported type APIClient should be of the form "APIClient ..." (with optional leading article) (golint)
    • Line 83: warning: exported method Sender.Send should have comment or be unexported (golint)
    • Line 112: warning: exported type SendError should have comment or be unexported (golint)
    • Line 122: warning: exported method Sender.SetDefaultSender should have comment or be unexported (golint)
    • Line 166: warning: exported method Sender.SetSender should have comment or be unexported (golint)
    • Line 175: warning: exported method Sender.SetRecipients should have comment or be unexported (golint)
    • Line 199: warning: comment on exported method Sender.SetGoogleGroupRecipients should be of the form "SetGoogleGroupRecipients ..." (golint)
    • /k8s.io/release/pkg/object/store.go
    • Line 21: warning: comment on exported type Store should be of the form "Store ..." (with optional leading article) (golint)
    • Line 44: warning: exported type OptFn should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign98%

IneffAssign detects ineffectual assignments in Go code.


misspell99%

Misspell Finds commonly misspelled English words