xfunding: send positions to slack when start up

This commit is contained in:
c9s 2023-03-30 00:46:41 +08:00
parent b18d4da402
commit 4b9e3f2302
No known key found for this signature in database
GPG Key ID: 7385E7E464CB0A54

View File

@ -343,6 +343,10 @@ func (s *Strategy) CrossRun(ctx context.Context, orderExecutionRouter bbgo.Order
log.Infof("loaded futures position: %s", s.FuturesPosition.String())
log.Infof("loaded neutral position: %s", s.NeutralPosition.String())
bbgo.Notify("Spot Position", s.SpotPosition)
bbgo.Notify("Futures Position", s.FuturesPosition)
bbgo.Notify("Neutral Position", s.NeutralPosition)
// sync funding fee txns
if !s.ProfitStats.LastFundingFeeTime.IsZero() {
s.syncFundingFeeRecords(ctx, s.ProfitStats.LastFundingFeeTime)