Preparing report...

Report for github.com/sonm-io/marketplace

A+    Excellent!    Found 15 issues across 72 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!


golint79%

Golint is a linter for Go source code.

    • marketplace/service/storage.go
    • Line 14: warning: exported function InsertOrderStmt should have comment or be unexported (golint)
    • Line 25: warning: exported function CancelOrderStmt should have comment or be unexported (golint)
    • Line 31: warning: exported function TouchOrdersStmt should have comment or be unexported (golint)
    • Line 38: warning: exported function OrderByIDStmt should have comment or be unexported (golint)
    • Line 51: warning: exported function MatchOrdersStmt should have comment or be unexported (golint)
    • Line 74: warning: exported function ToSQL should have comment or be unexported (golint)
    • marketplace/infra/accounts/keys.go
    • Line 78: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 158: warning: exported function NewStaticPassPhraser should have comment or be unexported (golint)
    • Line 188: warning: exported function NewFmtPrinter should have comment or be unexported (golint)
    • Line 239: warning: exported function LoadKeys should have comment or be unexported (golint)
    • Line 254: warning: exported type EthConfig should have comment or be unexported (golint)
    • Line 259: warning: exported method EthConfig.LoadKey should have comment or be unexported (golint)
    • marketplace/infra/util/util.go
    • Line 37: warning: exported function GetUserHomeDir should have comment or be unexported (golint)
    • Line 45: warning: exported function ParseEndpointPort should have comment or be unexported (golint)
    • Line 63: warning: exported function GetPlatformName should have comment or be unexported (golint)
    • Line 67: warning: exported function PubKeyToString should have comment or be unexported (golint)
    • Line 71: warning: exported function PubKeyToAddr should have comment or be unexported (golint)
    • Line 75: warning: exported function LoadYamlFile should have comment or be unexported (golint)
    • Line 108: warning: exported function GetAvailableIPs should have comment or be unexported (golint)
    • marketplace/service/filter/filters.go
    • Line 35: warning: exported method Operator.Condition should have comment or be unexported (golint)
    • Line 69: warning: exported function MatchOrder should have comment or be unexported (golint)
    • Line 80: warning: exported function MatchBid should have comment or be unexported (golint)
    • Line 123: warning: exported function MatchAsk should have comment or be unexported (golint)
    • Line 151: warning: exported function IsAskOrder should have comment or be unexported (golint)
    • Line 155: warning: exported function IsBidOrder should have comment or be unexported (golint)
    • Line 159: warning: exported function BuyerID should have comment or be unexported (golint)
    • Line 163: warning: exported function SupplierID should have comment or be unexported (golint)
    • Line 167: warning: exported function CPUCores should have comment or be unexported (golint)
    • Line 171: warning: exported function GPUCount should have comment or be unexported (golint)
    • Line 175: warning: exported function RamBytes should have comment or be unexported (golint)
    • Line 179: warning: exported function Storage should have comment or be unexported (golint)
    • Line 183: warning: exported function NetType should have comment or be unexported (golint)
    • Line 187: warning: exported function NetTrafficIn should have comment or be unexported (golint)
    • Line 191: warning: exported function NetTrafficOut should have comment or be unexported (golint)
    • marketplace/infra/util/certs.go
    • Line 49: warning: exported function NewHitlessCertRotator should have comment or be unexported (golint)
    • Line 189: warning: exported function CheckCert should have comment or be unexported (golint)
    • marketplace/infra/util/grpcsecure.go
    • Line 100: warning: exported type WalletAuthenticator should have comment or be unexported (golint)
    • Line 105: warning: exported method WalletAuthenticator.ServerHandshake should have comment or be unexported (golint)
    • Line 123: warning: exported method WalletAuthenticator.ClientHandshake should have comment or be unexported (golint)
    • Line 149: warning: exported function NewWalletAuthenticator should have comment or be unexported (golint)
    • Line 153: warning: exported function ParseEndpoint should have comment or be unexported (golint)
    • Line 169: warning: exported function MakeWalletAuthenticatedClient should have comment or be unexported (golint)
    • Line 191: warning: exported type SelfSignedWallet should have comment or be unexported (golint)
    • Line 195: warning: exported function NewSelfSignedWallet should have comment or be unexported (golint)
    • Line 225: warning: exported method WalletAccess.GetRequestMetadata should have comment or be unexported (golint)
    • Line 231: warning: exported method WalletAccess.RequireTransportSecurity should have comment or be unexported (golint)
    • Line 235: warning: exported function VerifySelfSignedWallet 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!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!