fix SAWarning

This commit is contained in:
gcarq 2017-09-08 19:52:20 +02:00
parent e38f73c0dc
commit 3ecfebee77

View File

@ -281,7 +281,7 @@ def _performance(bot: Bot, update: Update) -> None:
pair_rates = Trade.session.query(Trade.pair, func.sum(Trade.close_profit).label('profit_sum')) \
.filter(Trade.is_open.is_(False)) \
.group_by(Trade.pair) \
.order_by('profit_sum DESC') \
.order_by(text('profit_sum DESC')) \
.all()
stats = '\n'.join('{index}. <code>{pair}\t{profit:.2f}%</code>'.format(