From 4b9e3f2302b7647229cf74333d72f9b445562536 Mon Sep 17 00:00:00 2001 From: c9s Date: Thu, 30 Mar 2023 00:46:41 +0800 Subject: [PATCH] xfunding: send positions to slack when start up --- pkg/strategy/xfunding/strategy.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkg/strategy/xfunding/strategy.go b/pkg/strategy/xfunding/strategy.go index 4656015f1..99d75d9a8 100644 --- a/pkg/strategy/xfunding/strategy.go +++ b/pkg/strategy/xfunding/strategy.go @@ -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)