Preparing report...

Report for github.com/arnaucube/gogame

A+    Excellent!    Found 14 issues across 19 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!


gocyclo94%

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.


golint26%

Golint is a linter for Go source code.

    • gogame/config/config.go
    • Line 10: warning: exported type Config should have comment or be unexported (golint)
    • Line 22: warning: exported var C should have comment or be unexported (golint)
    • Line 24: warning: exported function MustRead should have comment or be unexported (golint)
    • gogame/models/planet.go
    • Line 12: warning: exported type Process should have comment or be unexported (golint)
    • Line 20: warning: exported type Resources should have comment or be unexported (golint)
    • Line 27: warning: exported type Planet should have comment or be unexported (golint)
    • Line 51: warning: exported function NewPlanet should have comment or be unexported (golint)
    • Line 87: warning: exported method Planet.GetFromDb should have comment or be unexported (golint)
    • Line 98: warning: exported method Planet.StoreInDb should have comment or be unexported (golint)
    • Line 176: warning: exported method Planet.GetBuildingCost should have comment or be unexported (golint)
    • Line 266: warning: exported method Planet.UpgradeBuilding should have comment or be unexported (golint)
    • Line 302: warning: exported function ResourcesToPoints should have comment or be unexported (golint)
    • gogame/services/usersrv/usersrv.go
    • Line 15: warning: exported type Service should have comment or be unexported (golint)
    • Line 20: warning: exported function New should have comment or be unexported (golint)
    • Line 36: warning: exported method Service.Register should have comment or be unexported (golint)
    • Line 65: warning: exported method Service.Login should have comment or be unexported (golint)
    • Line 91: warning: exported method Service.GetUserById should have comment or be unexported (golint)
    • Line 101: warning: exported method Service.GetUserPlanetsById should have comment or be unexported (golint)
    • gogame/models/calc.go
    • Line 13: warning: comment on exported function MetalGrowth should be of the form "MetalGrowth ..." (golint)
    • Line 23: warning: exported function CrystalGrowth should have comment or be unexported (golint)
    • Line 32: warning: exported function DeuteriumGrowth should have comment or be unexported (golint)
    • Line 42: warning: exported function SolarGrowth should have comment or be unexported (golint)
    • Line 48: warning: exported function FusionGrowth should have comment or be unexported (golint)
    • Line 59: warning: exported function MetalMineEnergyConsumption should have comment or be unexported (golint)
    • Line 65: warning: exported function CrystalMineEnergyConsumption should have comment or be unexported (golint)
    • Line 71: warning: exported function DeuteriumMineEnergyConsumption should have comment or be unexported (golint)
    • Line 80: warning: comment on exported function MetalMineCost should be of the form "MetalMineCost ..." (golint)
    • Line 98: warning: comment on exported function CrystalMineCost should be of the form "CrystalMineCost ..." (golint)
    • Line 116: warning: comment on exported function DeuteriumMineCost should be of the form "DeuteriumMineCost ..." (golint)
    • Line 134: warning: exported function EnergyMineCost should have comment or be unexported (golint)
    • Line 151: warning: exported function FussionReactorCost should have comment or be unexported (golint)
    • Line 167: warning: exported function RoboticsFactoryCost should have comment or be unexported (golint)
    • Line 183: warning: exported function ShipyardCost should have comment or be unexported (golint)
    • Line 199: warning: exported function MetalStorageCost should have comment or be unexported (golint)
    • Line 215: warning: exported function CrystalStorageCost should have comment or be unexported (golint)
    • Line 231: warning: exported function DeuteriumStorageCost should have comment or be unexported (golint)
    • Line 248: warning: exported function RessearchLabCost should have comment or be unexported (golint)
    • Line 264: warning: exported function AllianceDepotCost should have comment or be unexported (golint)
    • Line 280: warning: exported function MissileSiloCost should have comment or be unexported (golint)
    • Line 296: warning: exported function SpaceDockCost should have comment or be unexported (golint)
    • Line 313: warning: comment on exported function ConstructionTime should be of the form "ConstructionTime ..." (golint)
    • Line 321: warning: exported function RessearchTime should have comment or be unexported (golint)
    • gogame/queue/queue.go
    • Line 31: warning: exported method PriorityQueue.Push should have comment or be unexported (golint)
    • Line 38: warning: exported method PriorityQueue.Pop should have comment or be unexported (golint)
    • Line 47: warning: exported method PriorityQueue.Look should have comment or be unexported (golint)
    • gogame/constants/constants.go
    • Line 5: warning: exported const GALAXYSIZE should have comment or be unexported (golint)
    • Line 6: warning: exported const SOLARSYSTEMSIZE should have comment or be unexported (golint)
    • Line 8: warning: exported const UniverseAcceleration should have comment or be unexported (golint)
    • Line 9: warning: exported const MineVelocity should have comment or be unexported (golint)
    • Line 11: warning: comment on exported const JWTIdKey should be of the form "JWTIdKey ..." (golint)
    • gogame/services/gamesrv/gamesrv.go
    • Line 13: warning: exported type Service should have comment or be unexported (golint)
    • Line 17: warning: exported function New should have comment or be unexported (golint)
    • Line 42: warning: exported method Service.PutPlanetInSolarSystem should have comment or be unexported (golint)
    • Line 78: warning: exported method Service.GetPlanet should have comment or be unexported (golint)
    • Line 93: warning: exported method Service.UpgradeBuilding should have comment or be unexported (golint)
    • gogame/endpoint/handlers.go
    • Line 29: warning: exported type RegisterMsg should have comment or be unexported (golint)
    • Line 52: warning: exported type LoginMsg should have comment or be unexported (golint)
    • Line 142: warning: exported type BuildMsg should have comment or be unexported (golint)
    • gogame/models/user.go
    • Line 31: warning: exported function NewUser should have comment or be unexported (golint)
    • Line 48: warning: exported function UserDbToUser should have comment or be unexported (golint)
    • Line 59: warning: exported method User.StoreInDb should have comment or be unexported (golint)
    • Line 68: warning: exported method User.GetFromDb should have comment or be unexported (golint)
    • Line 78: warning: exported method User.GetPlanets should have comment or be unexported (golint)
    • Line 87: warning: exported function AddPoints 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!