Preparing report...

Report for github.com/openshift/gcp-project-operator

A+    Excellent!    Found 18 issues across 47 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!


gocyclo100%

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.

No problems detected. Good job!


golint61%

Golint is a linter for Go source code.

    • gcp-project-operator/pkg/controller/projectclaim/projectclaimadapter.go
    • Line 26: warning: exported type ProjectClaimAdapter should have comment or be unexported (golint)
    • Line 34: warning: exported type ObjectState should have comment or be unexported (golint)
    • Line 37: warning: exported const ObjectModified should have comment (or a comment on this block) or be unexported (golint)
    • Line 41: warning: exported const ProjectClaimFinalizer should have comment or be unexported (golint)
    • Line 42: warning: exported const CCSSecretFinalizer should have comment or be unexported (golint)
    • Line 43: warning: exported const RegionCheckFailed should have comment or be unexported (golint)
    • Line 45: warning: exported function NewProjectClaimAdapter should have comment or be unexported (golint)
    • Line 74: warning: exported method ProjectClaimAdapter.ProjectReferenceExists should have comment or be unexported (golint)
    • Line 86: warning: exported method ProjectClaimAdapter.EnsureProjectClaimDeletionProcessed should have comment or be unexported (golint)
    • Line 86: warning: receiver name adapter should be consistent with previous receiver name c for ProjectClaimAdapter (golint)
    • Line 97: warning: exported method ProjectClaimAdapter.IsProjectClaimDeletion should have comment or be unexported (golint)
    • Line 101: warning: exported method ProjectClaimAdapter.IsProjectReferenceDeletion should have comment or be unexported (golint)
    • Line 105: warning: exported method ProjectClaimAdapter.EnsureProjectClaimFinalizerDeleted should have comment or be unexported (golint)
    • Line 110: warning: exported method ProjectClaimAdapter.EnsureCCSSecretFinalizerDeleted should have comment or be unexported (golint)
    • Line 141: warning: exported method ProjectClaimAdapter.FinalizeProjectClaim should have comment or be unexported (golint)
    • Line 172: warning: exported method ProjectClaimAdapter.EnsureProjectClaimInitialized should have comment or be unexported (golint)
    • Line 184: warning: exported method ProjectClaimAdapter.EnsureProjectReferenceLink should have comment or be unexported (golint)
    • Line 200: warning: exported method ProjectClaimAdapter.EnsureFinalizer should have comment or be unexported (golint)
    • Line 209: warning: exported method ProjectClaimAdapter.EnsureCCSSecretFinalizer should have comment or be unexported (golint)
    • Line 248: warning: exported method ProjectClaimAdapter.EnsureProjectReferenceExists should have comment or be unexported (golint)
    • Line 260: warning: exported method ProjectClaimAdapter.EnsureProjectClaimStatePending should have comment or be unexported (golint)
    • Line 264: warning: exported method ProjectClaimAdapter.EnsureProjectClaimStatePendingProject should have comment or be unexported (golint)
    • Line 268: warning: exported method ProjectClaimAdapter.EnsureProjectClaimState should have comment or be unexported (golint)
    • gcp-project-operator/pkg/util/mocks/structs/projectclaim.go
    • Line 14: warning: exported const TestProjectClaimName should have comment (or a comment on this block) or be unexported (golint)
    • Line 26: warning: exported function NewProjectClaimBuilder should have comment or be unexported (golint)
    • Line 60: warning: exported type ProjectClaimMatcher should have comment or be unexported (golint)
    • Line 65: warning: exported function NewProjectClaimMatcher should have comment or be unexported (golint)
    • Line 69: warning: exported method ProjectClaimMatcher.Matches should have comment or be unexported (golint)
    • gcp-project-operator/pkg/util/mocks/structs/projectreference.go
    • Line 22: warning: exported function NewProjectReferenceBuilder should have comment or be unexported (golint)
    • Line 52: warning: exported type ProjectReferenceMatcher should have comment or be unexported (golint)
    • Line 57: warning: exported function NewProjectReferenceMatcher should have comment or be unexported (golint)
    • Line 61: warning: exported method ProjectReferenceMatcher.Matches should have comment or be unexported (golint)
    • gcp-project-operator/pkg/controller/projectreference/projectreference_adapter.go
    • Line 33: warning: exported type ObjectState should have comment or be unexported (golint)
    • Line 36: warning: exported const ObjectModified should have comment (or a comment on this block) or be unexported (golint)
    • Line 42: warning: exported const FinalizerName should have comment (or a comment on this block) or be unexported (golint)
    • Line 128: warning: exported function EnsureProjectClaimReady should have comment or be unexported (golint)
    • Line 161: warning: exported function VerifyProjectClaimPending should have comment or be unexported (golint)
    • Line 168: warning: exported function EnsureProjectReferenceStatusCreating should have comment or be unexported (golint)
    • Line 195: warning: exported function EnsureServiceAccountName should have comment or be unexported (golint)
    • Line 211: warning: exported function EnsureProjectID should have comment or be unexported (golint)
    • Line 224: warning: exported function EnsureProjectCreated should have comment or be unexported (golint)
    • Line 256: warning: exported function EnsureProjectConfigured should have comment or be unexported (golint)
    • Line 301: warning: exported function EnsureStateReady should have comment or be unexported (golint)
    • Line 330: warning: exported method ReferenceAdapter.UpdateServiceAccountName should have comment or be unexported (golint)
    • Line 339: warning: exported function EnsureDeletionProcessed should have comment or be unexported (golint)
    • Line 406: warning: exported function GenerateProjectID should have comment or be unexported (golint)
    • Line 561: warning: exported method ReferenceAdapter.ConfigureProjectLabel should have comment or be unexported (golint)
    • Line 732: warning: exported function EnsureProjectReferenceInitialized should have comment or be unexported (golint)
    • gcp-project-operator/pkg/util/reconclile_operation.go
    • Line 5: warning: exported type OperationResult should have comment or be unexported (golint)
    • Line 11: warning: exported method OperationResult.RequeueOrCancel should have comment or be unexported (golint)
    • Line 15: warning: exported function ContinueOperationResult should have comment or be unexported (golint)
    • Line 22: warning: exported function StopOperationResult should have comment or be unexported (golint)
    • Line 30: warning: exported function StopProcessing should have comment or be unexported (golint)
    • Line 35: warning: exported function Requeue should have comment or be unexported (golint)
    • Line 44: warning: exported function RequeueWithError should have comment or be unexported (golint)
    • Line 54: warning: exported function RequeueOnErrorOrStop should have comment or be unexported (golint)
    • Line 64: warning: exported function RequeueOnErrorOrContinue should have comment or be unexported (golint)
    • Line 74: warning: exported function RequeueAfter should have comment or be unexported (golint)
    • Line 84: warning: exported function ContinueProcessing should have comment or be unexported (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!


misspell89%

Misspell Finds commonly misspelled English words