Skip to content

Commit

Permalink
xdepthmaker: improve fixer logging
Browse files Browse the repository at this point in the history
  • Loading branch information
c9s committed Mar 5, 2024
1 parent 4bed29a commit 26c3461
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/strategy/xdepthmaker/profitfixer.go
Expand Up @@ -51,8 +51,10 @@ func (f *ProfitFixer) Fix(ctx context.Context, since, until time.Time, stats *ty
var allTrades = make([]types.Trade, 0, 1000)

g, subCtx := errgroup.WithContext(ctx)
for _, service := range f.sessions {
for n, service := range f.sessions {
sessionName := n
g.Go(func() error {
log.Infof("batch querying %s trade history from %s since %s until %s", f.market.Symbol, sessionName, since.String(), until.String())
trades, err := f.batchQueryTrades(subCtx, service, f.market.Symbol, since, until)
if err != nil {
log.WithError(err).Errorf("unable to batch query trades for fixer")
Expand Down

0 comments on commit 26c3461

Please sign in to comment.