Preparing report...

Report for github.com/BytemarkHosting/bytemark-client

A+    Excellent!    Found 28 issues across 398 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.


golint98%

Golint is a linter for Go source code.

    • bytemark-client/mocks/client.go
    • Line 16: warning: exported type Client should have comment or be unexported (golint)
    • Line 21: warning: exported method Client.AllowInsecureRequests should have comment or be unexported (golint)
    • Line 24: warning: exported method Client.BuildRequestNoAuth should have comment or be unexported (golint)
    • Line 29: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 33: warning: exported method Client.BuildRequest should have comment or be unexported (golint)
    • Line 38: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 43: warning: exported method Client.Impersonate should have comment or be unexported (golint)
    • Line 48: warning: exported method Client.GetEndpoint should have comment or be unexported (golint)
    • Line 52: warning: exported method Client.GetSessionToken should have comment or be unexported (golint)
    • Line 56: warning: exported method Client.GetSessionUser should have comment or be unexported (golint)
    • Line 60: warning: exported method Client.GetSessionFactors should have comment or be unexported (golint)
    • Line 65: warning: exported method Client.GetSPPToken should have comment or be unexported (golint)
    • Line 69: warning: exported method Client.SetDebugLevel should have comment or be unexported (golint)
    • Line 72: warning: exported method Client.AuthWithToken should have comment or be unexported (golint)
    • Line 76: warning: exported method Client.AuthWithCredentials should have comment or be unexported (golint)
    • Line 80: warning: exported method Client.RequestAndUnmarshal should have comment or be unexported (golint)
    • Line 84: warning: exported method Client.RequestAndRead should have comment or be unexported (golint)
    • Line 89: warning: exported method Client.Request should have comment or be unexported (golint)
    • Line 102: warning: exported method Client.ReadDefinitions should have comment or be unexported (golint)
    • Line 108: warning: exported method Client.AddIP should have comment or be unexported (golint)
    • Line 114: warning: exported method Client.AddUserAuthorizedKey should have comment or be unexported (golint)
    • Line 119: warning: exported method Client.DeleteUserAuthorizedKey should have comment or be unexported (golint)
    • Line 124: warning: exported method Client.GetUser should have comment or be unexported (golint)
    • Line 130: warning: exported method Client.CreateCreditCard should have comment or be unexported (golint)
    • Line 134: warning: exported method Client.CreateCreditCardWithToken should have comment or be unexported (golint)
    • Line 138: warning: exported method Client.CreateAccount should have comment or be unexported (golint)
    • Line 144: warning: exported method Client.RegisterNewAccount should have comment or be unexported (golint)
    • Line 150: warning: exported method Client.GetAccount should have comment or be unexported (golint)
    • Line 156: warning: exported method Client.GetDefaultAccount should have comment or be unexported (golint)
    • Line 162: warning: exported method Client.GetAccounts should have comment or be unexported (golint)
    • Line 168: warning: exported method Client.CreateDisc should have comment or be unexported (golint)
    • Line 173: warning: exported method Client.GetDisc should have comment or be unexported (golint)
    • Line 179: warning: exported method Client.GetDiscByID should have comment or be unexported (golint)
    • Line 185: warning: exported method Client.CreateGroup should have comment or be unexported (golint)
    • Line 190: warning: exported method Client.GetGroup should have comment or be unexported (golint)
    • Line 196: warning: exported method Client.DeleteDisc should have comment or be unexported (golint)
    • Line 201: warning: exported method Client.DeleteGroup should have comment or be unexported (golint)
    • Line 206: warning: exported method Client.DeleteVirtualMachine should have comment or be unexported (golint)
    • Line 211: warning: exported method Client.CreateVirtualMachine should have comment or be unexported (golint)
    • Line 217: warning: exported method Client.GetVirtualMachine should have comment or be unexported (golint)
    • Line 223: warning: exported method Client.MoveVirtualMachine should have comment or be unexported (golint)
    • Line 228: warning: exported method Client.ParseVirtualMachineName should have comment or be unexported (golint)
    • Line 234: warning: exported method Client.ParseGroupName should have comment or be unexported (golint)
    • Line 240: warning: exported method Client.ParseAccountName should have comment or be unexported (golint)
    • Line 245: warning: exported method Client.ReimageVirtualMachine should have comment or be unexported (golint)
    • Line 250: warning: exported method Client.ResetVirtualMachine should have comment or be unexported (golint)
    • Line 255: warning: exported method Client.ResizeDisc should have comment or be unexported (golint)
    • Line 260: warning: exported method Client.SetDiscIopsLimit should have comment or be unexported (golint)
    • Line 265: warning: exported method Client.RestartVirtualMachine should have comment or be unexported (golint)
    • Line 269: warning: exported method Client.SetVirtualMachineCDROM should have comment or be unexported (golint)
    • Line 273: warning: exported method Client.SetVirtualMachineCores should have comment or be unexported (golint)
    • Line 277: warning: exported method Client.SetVirtualMachineHardwareProfile should have comment or be unexported (golint)
    • Line 281: warning: exported method Client.SetVirtualMachineHardwareProfileLock should have comment or be unexported (golint)
    • Line 285: warning: exported method Client.SetVirtualMachineMemory should have comment or be unexported (golint)
    • Line 289: warning: exported method Client.StartVirtualMachine should have comment or be unexported (golint)
    • Line 293: warning: exported method Client.StopVirtualMachine should have comment or be unexported (golint)
    • Line 297: warning: exported method Client.ShutdownVirtualMachine should have comment or be unexported (golint)
    • Line 302: warning: exported method Client.UndeleteVirtualMachine should have comment or be unexported (golint)
    • Line 307: warning: exported method Client.CreateBackup should have comment or be unexported (golint)
    • Line 312: warning: exported method Client.DeleteBackup should have comment or be unexported (golint)
    • Line 316: warning: exported method Client.CreateBackupSchedule should have comment or be unexported (golint)
    • Line 321: warning: exported method Client.DeleteBackupSchedule should have comment or be unexported (golint)
    • Line 325: warning: exported method Client.GetBackups should have comment or be unexported (golint)
    • Line 330: warning: exported method Client.RestoreBackup should have comment or be unexported (golint)
    • Line 337: warning: exported method Client.GetPrivileges should have comment or be unexported (golint)
    • Line 342: warning: exported method Client.GetPrivilegesForAccount should have comment or be unexported (golint)
    • Line 347: warning: exported method Client.GetPrivilegesForGroup should have comment or be unexported (golint)
    • Line 352: warning: exported method Client.GetPrivilegesForVirtualMachine should have comment or be unexported (golint)
    • Line 357: warning: exported method Client.GrantPrivilege should have comment or be unexported (golint)
    • Line 361: warning: exported method Client.RevokePrivilege should have comment or be unexported (golint)
    • Line 365: warning: exported method Client.GetVLANs should have comment or be unexported (golint)
    • Line 370: warning: exported method Client.GetVLAN should have comment or be unexported (golint)
    • Line 375: warning: exported method Client.GetIPRanges should have comment or be unexported (golint)
    • Line 380: warning: exported method Client.GetIPRange should have comment or be unexported (golint)
    • Line 385: warning: exported method Client.GetHeads should have comment or be unexported (golint)
    • Line 390: warning: exported method Client.GetHead should have comment or be unexported (golint)
    • Line 395: warning: exported method Client.GetTails should have comment or be unexported (golint)
    • Line 400: warning: exported method Client.GetTail should have comment or be unexported (golint)
    • Line 405: warning: exported method Client.GetStoragePools should have comment or be unexported (golint)
    • Line 410: warning: exported method Client.GetStoragePool should have comment or be unexported (golint)
    • Line 415: warning: exported method Client.GetMigratingVMs should have comment or be unexported (golint)
    • Line 420: warning: exported method Client.GetStoppedEligibleVMs should have comment or be unexported (golint)
    • Line 425: warning: exported method Client.GetRecentVMs should have comment or be unexported (golint)
    • Line 430: warning: exported method Client.MigrateDisc should have comment or be unexported (golint)
    • Line 434: warning: exported method Client.MigrateVirtualMachine should have comment or be unexported (golint)
    • Line 438: warning: exported method Client.ReapVMs should have comment or be unexported (golint)
    • Line 442: warning: exported method Client.DeleteVLAN should have comment or be unexported (golint)
    • Line 446: warning: exported method Client.AdminCreateGroup should have comment or be unexported (golint)
    • Line 450: warning: exported method Client.CreateIPRange should have comment or be unexported (golint)
    • Line 454: warning: exported method Client.CancelDiscMigration should have comment or be unexported (golint)
    • Line 458: warning: exported method Client.CancelVMMigration should have comment or be unexported (golint)
    • Line 462: warning: exported method Client.EmptyStoragePool should have comment or be unexported (golint)
    • Line 466: warning: exported method Client.EmptyHead should have comment or be unexported (golint)
    • Line 470: warning: exported method Client.ReifyDisc should have comment or be unexported (golint)
    • Line 474: warning: exported method Client.ApproveVM should have comment or be unexported (golint)
    • Line 478: warning: exported method Client.RejectVM should have comment or be unexported (golint)
    • Line 482: warning: exported method Client.RegradeDisc should have comment or be unexported (golint)
    • Line 486: warning: exported method Client.UpdateVMMigration should have comment or be unexported (golint)
    • Line 490: warning: exported method Client.CreateUser should have comment or be unexported (golint)
    • Line 494: warning: exported method Client.UpdateHead should have comment or be unexported (golint)
    • Line 498: warning: exported method Client.UpdateTail should have comment or be unexported (golint)
    • Line 502: warning: exported method Client.UpdateStoragePool should have comment or be unexported (golint)
    • Line 507: warning: exported method Client.GetMigratingDiscs should have comment or be unexported (golint)
    • Line 513: warning: exported method Client.EnsureAccountName should have comment or be unexported (golint)
    • Line 518: warning: exported method Client.EnsureGroupName should have comment or be unexported (golint)
    • Line 528: warning: exported method Client.EnsureVirtualMachineName should have comment or be unexported (golint)
    • bytemark-client/mocks/config.go
    • Line 13: warning: exported type Config should have comment or be unexported (golint)
    • Line 17: warning: exported method Config.EndpointName should have comment or be unexported (golint)
    • Line 21: warning: exported method Config.ConfigDir should have comment or be unexported (golint)
    • Line 25: warning: exported method Config.Force should have comment or be unexported (golint)
    • Line 30: warning: exported method Config.Get should have comment or be unexported (golint)
    • Line 34: warning: exported method Config.GetIgnoreErr should have comment or be unexported (golint)
    • Line 39: warning: exported method Config.GetBool should have comment or be unexported (golint)
    • Line 44: warning: exported method Config.GetSessionValidity should have comment or be unexported (golint)
    • Line 49: warning: exported method Config.GetV should have comment or be unexported (golint)
    • Line 54: warning: exported method Config.GetVirtualMachine should have comment or be unexported (golint)
    • Line 59: warning: exported method Config.GetGroup should have comment or be unexported (golint)
    • Line 64: warning: exported method Config.GetAll should have comment or be unexported (golint)
    • Line 69: warning: exported method Config.PanelURL should have comment or be unexported (golint)
    • Line 74: warning: exported method Config.Set should have comment or be unexported (golint)
    • Line 79: warning: exported method Config.SetPersistent should have comment or be unexported (golint)
    • Line 84: warning: exported method Config.Unset should have comment or be unexported (golint)
    • Line 89: warning: exported method Config.GetDebugLevel should have comment or be unexported (golint)
    • Line 94: warning: exported method Config.ImportFlags should have comment or be unexported (golint)
    • bytemark-client/mocks/context.go
    • Line 10: warning: exported type CliContext should have comment or be unexported (golint)
    • Line 14: warning: exported method CliContext.Args should have comment or be unexported (golint)
    • Line 18: warning: exported method CliContext.Bool should have comment or be unexported (golint)
    • Line 22: warning: exported method CliContext.BoolT should have comment or be unexported (golint)
    • Line 26: warning: exported method CliContext.Duration should have comment or be unexported (golint)
    • Line 30: warning: exported method CliContext.FlagNames should have comment or be unexported (golint)
    • Line 34: warning: exported method CliContext.Float64 should have comment or be unexported (golint)
    • Line 38: warning: exported method CliContext.Generic should have comment or be unexported (golint)
    • Line 42: warning: exported method CliContext.GlobalBool should have comment or be unexported (golint)
    • Line 46: warning: exported method CliContext.GlobalBoolT should have comment or be unexported (golint)
    • Line 50: warning: exported method CliContext.GlobalDuration should have comment or be unexported (golint)
    • Line 54: warning: exported method CliContext.GlobalFlagNames should have comment or be unexported (golint)
    • Line 58: warning: exported method CliContext.GlobalFloat64 should have comment or be unexported (golint)
    • Line 62: warning: exported method CliContext.GlobalGeneric should have comment or be unexported (golint)
    • Line 66: warning: exported method CliContext.GlobalInt should have comment or be unexported (golint)
    • Line 70: warning: exported method CliContext.GlobalInt64 should have comment or be unexported (golint)
    • Line 74: warning: exported method CliContext.GlobalInt64Slice should have comment or be unexported (golint)
    • Line 78: warning: exported method CliContext.GlobalIntSlice should have comment or be unexported (golint)
    • Line 82: warning: exported method CliContext.GlobalIsSet should have comment or be unexported (golint)
    • Line 86: warning: exported method CliContext.GlobalSet should have comment or be unexported (golint)
    • Line 90: warning: exported method CliContext.GlobalString should have comment or be unexported (golint)
    • Line 94: warning: exported method CliContext.GlobalStringSlice should have comment or be unexported (golint)
    • Line 98: warning: exported method CliContext.GlobalUint should have comment or be unexported (golint)
    • Line 102: warning: exported method CliContext.GlobalUint64 should have comment or be unexported (golint)
    • Line 106: warning: exported method CliContext.Int should have comment or be unexported (golint)
    • Line 110: warning: exported method CliContext.Int64 should have comment or be unexported (golint)
    • Line 114: warning: exported method CliContext.Int64Slice should have comment or be unexported (golint)
    • Line 118: warning: exported method CliContext.IntSlice should have comment or be unexported (golint)
    • Line 122: warning: exported method CliContext.IsSet should have comment or be unexported (golint)
    • Line 126: warning: exported method CliContext.NArg should have comment or be unexported (golint)
    • Line 130: warning: exported method CliContext.NumFlags should have comment or be unexported (golint)
    • Line 134: warning: exported method CliContext.Parent should have comment or be unexported (golint)
    • Line 138: warning: exported method CliContext.Set should have comment or be unexported (golint)
    • Line 146: warning: exported method CliContext.StringSlice should have comment or be unexported (golint)
    • Line 150: warning: exported method CliContext.Uint should have comment or be unexported (golint)
    • Line 154: warning: exported method CliContext.Uint64 should have comment or be unexported (golint)
    • Line 159: warning: exported method CliContext.App should have comment or be unexported (golint)
    • Line 163: warning: exported method CliContext.Command should have comment or be unexported (golint)
    • bytemark-client/mocks/request.go
    • Line 14: warning: exported type Request should have comment or be unexported (golint)
    • Line 36: warning: exported method Request.AssertRequestBodyEqual should have comment or be unexported (golint)
    • Line 52: warning: exported method Request.AssertRequestObjectEqual should have comment or be unexported (golint)
    • Line 65: warning: exported method Request.GetURL should have comment or be unexported (golint)
    • Line 73: warning: exported method Request.AllowInsecure should have comment or be unexported (golint)
    • Line 92: warning: exported method Request.MarshalAndRun should have comment or be unexported (golint)
    • Line 97: warning: exported method Request.Run 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!


misspell0%

Misspell Finds commonly misspelled English words

An error occurred while running this test (exit status 3)