fix time printing

This commit is contained in:
c9s 2022-05-10 01:09:40 +08:00
parent f6d95a49be
commit f4991dbbfa
No known key found for this signature in database
GPG Key ID: 7385E7E464CB0A54

View File

@ -418,11 +418,12 @@ var BacktestCmd = &cobra.Command{
trader.Graceful.Shutdown(shutdownCtx)
cancelShutdown()
log.Infof("START TIME: %s", startTime.Format(time.RFC1123))
log.Infof("END TIME: %s", endTime.Format(time.RFC1123))
// put the logger back to print the pnl
log.SetLevel(log.InfoLevel)
log.Infof("START TIME: %s", startTime.Format(time.RFC1123))
log.Infof("END TIME: %s", endTime.Format(time.RFC1123))
for _, session := range environ.Sessions() {
backtestExchange := session.Exchange.(*backtest.Exchange)
exchangeName := session.Exchange.Name().String()