Skip to content

Commit

Permalink
xgap, autobuy: disable notify
Browse files Browse the repository at this point in the history
  • Loading branch information
c9s committed Dec 16, 2024
1 parent c842609 commit ee4fef7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions pkg/strategy/autobuy/strategy.go
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ func (s *Strategy) Subscribe(session *bbgo.ExchangeSession) {

func (s *Strategy) Run(ctx context.Context, _ bbgo.OrderExecutor, session *bbgo.ExchangeSession) error {
s.Strategy.Initialize(ctx, s.Environment, session, s.Market, ID, s.InstanceID())
s.Strategy.OrderExecutor.DisableNotify()

if s.Bollinger != nil {
s.boll = session.Indicators(s.Symbol).BOLL(s.Bollinger.IntervalWindow, s.Bollinger.BandWidth)
Expand Down
2 changes: 2 additions & 0 deletions pkg/strategy/xgap/strategy.go
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,8 @@ func (s *Strategy) CrossRun(ctx context.Context, _ bbgo.OrderExecutionRouter, se
}

s.Strategy.Initialize(ctx, s.Environment, tradingSession, s.tradingMarket, ID, s.InstanceID())
s.Strategy.OrderExecutor.DisableNotify()

s.FeeBudget.Initialize()

s.stopC = make(chan struct{})
Expand Down

0 comments on commit ee4fef7

Please sign in to comment.