Conversation
fix: fix fixedpoint rounding
strategy: rebalance: add order type parameter
FEATURE: add persistence service to environment
…gy-demo-trading-gpt
FEATURE: [grid2] using dnum
feature: strategy: xfunding
|
Welcome back! @austin362667, This pull request may get 621 BBG. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1130 +/- ##
=======================================
Coverage 19.94% 19.94%
=======================================
Files 436 436
Lines 34072 34072
=======================================
Hits 6794 6794
Misses 26734 26734
Partials 544 544 Continue to review full report in Codecov by Sentry.
|
| s.futureStreamBook.BindStream(s.FutureSession.MarketDataStream) | ||
| s.spotStreamBook = types.NewStreamBook(s.SpotMarket.Symbol) | ||
| s.spotStreamBook.BindStream(s.SpotSession.MarketDataStream) | ||
| s.spot2StreamBook = types.NewStreamBook("BTCBUSD") |
There was a problem hiding this comment.
can we pull out this to a config? thanks
| s2ask, s2aok := s.spot2StreamBook.OrderBook.BestAsk() | ||
| fbid, fbok := s.futureStreamBook.BestBid() | ||
| fask, faok := s.futureStreamBook.BestAsk() | ||
| log.Infof("Futures Bid Price: %f, Future Ask Price: %f\n Spot Bid Price: %f, Spot Ask Price: %f", fbid.Price.Float64(), fask.Price.Float64(), sbid.Price.Float64(), sask.Price.Float64()) |
There was a problem hiding this comment.
log message starts with lower case letters
| FutureMarket types.Market | ||
|
|
||
| BestBidPrice fixedpoint.Value | ||
| BestAskPrice fixedpoint.Value |
| return | ||
| case <-posTicker.C: | ||
| s.cancelOrders(ctx) | ||
| sbid, sbok := s.spotStreamBook.OrderBook.BestBid() |
There was a problem hiding this comment.
sbid, sask, ok := s.spotStreamBook.OrderBook.BestBidAndAsk()
if !ok {
return
}
|
|
||
| // SourceExchange session name | ||
| SpotExchange string `json:"spotExchange"` | ||
| // MakerExchange session name |
| SpotPosition *types.Position `json:"position,omitempty" persistence:"position"` | ||
| SpotProfitStats *types.ProfitStats `json:"profitStats,omitempty" persistence:"profit_stats"` | ||
| FuturePosition *types.Position `json:"position,omitempty" persistence:"future_position"` | ||
| FutureProfitStats *types.ProfitStats `json:"profitStats,omitempty" persistence:"future_profit_stats"` |
There was a problem hiding this comment.
you're using the same json keys in the fields
|
|
No description provided.