Gofmt formats Go programs. We run gofmt -s
on your code, where -s
is for the "simplify" command
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!
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.
Golint is a linter for Go source code.
-
alpaca-trade-api-go/v2/stream/datav2.go
- Line 360: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
- Line 418: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
-
alpaca-trade-api-go/polygon/stream.go
- Line 19: warning: exported const MinuteAggs should have comment (or a comment on this block) or be unexported (golint)
- Line 26: warning: exported const MaxConnectionAttempts should have comment (or a comment on this block) or be unexported (golint)
- Line 34: warning: exported type Stream should have comment or be unexported (golint)
-
alpaca-trade-api-go/alpaca/entities.go
- Line 10: warning: exported type Account should have comment or be unexported (golint)
- Line 40: warning: exported type Order should have comment or be unexported (golint)
- Line 74: warning: exported type Position should have comment or be unexported (golint)
- Line 92: warning: exported type Asset should have comment or be unexported (golint)
- Line 105: warning: exported type Fundamental should have comment or be unexported (golint)
- Line 131: warning: exported type Bar should have comment or be unexported (golint)
- Line 140: warning: exported type ListBarParams should have comment or be unexported (golint)
- Line 147: warning: exported type LastQuote should have comment or be unexported (golint)
- Line 157: warning: exported method LastQuote.Time should have comment or be unexported (golint)
- Line 161: warning: exported type LastQuoteResponse should have comment or be unexported (golint)
- Line 167: warning: exported type LastTrade should have comment or be unexported (golint)
- Line 178: warning: exported method LastTrade.Time should have comment or be unexported (golint)
- Line 182: warning: exported type LastTradeResponse should have comment or be unexported (golint)
- Line 188: warning: exported type AggV2 should have comment or be unexported (golint)
- Line 199: warning: exported type Aggregates should have comment or be unexported (golint)
- Line 236: warning: exported type CalendarDay should have comment or be unexported (golint)
- Line 242: warning: exported type Clock should have comment or be unexported (golint)
- Line 249: warning: exported type AccountConfigurations should have comment or be unexported (golint)
- Line 256: warning: exported type AccountActivity should have comment or be unexported (golint)
- Line 273: warning: exported type PortfolioHistory should have comment or be unexported (golint)
- Line 282: warning: exported type PlaceOrderRequest should have comment or be unexported (golint)
- Line 301: warning: exported type TakeProfit should have comment or be unexported (golint)
- Line 305: warning: exported type StopLoss should have comment or be unexported (golint)
- Line 310: warning: exported type OrderAttributes should have comment or be unexported (golint)
- Line 316: warning: exported type ReplaceOrderRequest should have comment or be unexported (golint)
- Line 325: warning: exported type AccountConfigurationsRequest should have comment or be unexported (golint)
- Line 332: warning: exported type AccountActivitiesRequest should have comment or be unexported (golint)
- Line 341: warning: exported type Side should have comment or be unexported (golint)
- Line 344: warning: exported const Buy should have comment (or a comment on this block) or be unexported (golint)
- Line 348: warning: exported type OrderType should have comment or be unexported (golint)
- Line 351: warning: exported const Market should have comment (or a comment on this block) or be unexported (golint)
- Line 358: warning: exported type OrderClass should have comment or be unexported (golint)
- Line 361: warning: exported const Bracket should have comment (or a comment on this block) or be unexported (golint)
- Line 367: warning: exported type TimeInForce should have comment or be unexported (golint)
- Line 370: warning: exported const Day should have comment (or a comment on this block) or be unexported (golint)
- Line 380: warning: exported type DtbpCheck should have comment or be unexported (golint)
- Line 383: warning: exported const Entry should have comment (or a comment on this block) or be unexported (golint)
- Line 388: warning: exported type TradeConfirmEmail should have comment or be unexported (golint)
- Line 391: warning: exported const None should have comment (or a comment on this block) or be unexported (golint)
- Line 395: warning: exported type RangeFreq should have comment or be unexported (golint)
- Line 398: warning: exported const Min1 should have comment (or a comment on this block) or be unexported (golint)
- Line 420: warning: exported type TradeUpdate should have comment or be unexported (golint)
- Line 425: warning: exported type StreamAgg should have comment or be unexported (golint)
- Line 440: warning: exported method StreamAgg.Time should have comment or be unexported (golint)
- Line 445: warning: exported type StreamQuote should have comment or be unexported (golint)
- Line 457: warning: exported method StreamQuote.Time should have comment or be unexported (golint)
- Line 462: warning: exported type StreamTrade should have comment or be unexported (golint)
- Line 474: warning: exported method StreamTrade.Time should have comment or be unexported (golint)
-
alpaca-trade-api-go/polygon/entities.go
- Line 52: warning: exported type MapItem should have comment or be unexported (golint)
- Line 173: warning: exported type GetHistoricTradesParams should have comment or be unexported (golint)
- Line 178: warning: exported type HistoricTicksV2Params should have comment or be unexported (golint)
- Line 215: warning: exported type PolygonAuthMsg should have comment or be unexported (golint)
- Line 221: warning: comment on exported type PolgyonServerMsg should be of the form "PolgyonServerMsg ..." (with optional leading article) (golint)
- Line 270: warning: comment on exported type StockExchange should be of the form "StockExchange ..." (with optional leading article) (golint)
-
alpaca-trade-api-go/alpaca/rest.go
- Line 117: warning: exported function SetBaseUrl should have comment or be unexported (golint)
- Line 148: warning: comment on exported method Client.GetAccountConfigurations should be of the form "GetAccountConfigurations ..." (golint)
- Line 169: warning: comment on exported method Client.UpdateAccountConfigurations should be of the form "UpdateAccountConfigurations ..." (golint)
- Line 190: warning: exported method Client.GetAccountActivities should have comment or be unexported (golint)
- Line 239: warning: exported method Client.GetPortfolioHistory should have comment or be unexported (golint)
- Line 1049: warning: exported function GetAccountActivities should have comment or be unexported (golint)
- Line 1053: warning: exported function GetPortfolioHistory should have comment or be unexported (golint)
- Line 1105: warning: comment on exported function GetLatestQuote should be of the form "GetLatestQuote ..." (golint)
- Line 1247: warning: exported method Bar.GetTime should have comment or be unexported (golint)
- Line 1289: warning: exported method PlaceOrderRequest.MarshalJSON should have comment or be unexported (golint)
-
alpaca-trade-api-go/alpaca/stream.go
- Line 20: warning: exported const TradeUpdates should have comment (or a comment on this block) or be unexported (golint)
- Line 25: warning: exported const MaxConnectionAttempts should have comment (or a comment on this block) or be unexported (golint)
- Line 37: warning: exported type Stream should have comment or be unexported (golint)
- Line 307: warning: exported function GetDataStream should have comment or be unexported (golint)
Checks whether your project has a LICENSE file.
No problems detected. Good job!
IneffAssign detects ineffectual assignments in Go code.
Misspell Finds commonly misspelled English words