From 811e23e3da398feb9100c34dbf158eda9b2fe34d Mon Sep 17 00:00:00 2001 From: Matthias Date: Sun, 24 May 2020 08:58:26 +0200 Subject: [PATCH] Have profit return time in timestamp --- freqtrade/rpc/rpc.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/freqtrade/rpc/rpc.py b/freqtrade/rpc/rpc.py index 81fb3d4be..c8d17c7b3 100644 --- a/freqtrade/rpc/rpc.py +++ b/freqtrade/rpc/rpc.py @@ -314,7 +314,9 @@ class RPC: 'profit_all_fiat': profit_all_fiat, 'trade_count': len(trades), 'first_trade_date': arrow.get(trades[0].open_date).humanize(), + 'first_trade_timestamp': int(trades[0].open_date.timestamp() * 1000), 'latest_trade_date': arrow.get(trades[-1].open_date).humanize(), + 'latest_trade_timestamp': int(trades[-1].open_date.timestamp() * 1000), 'avg_duration': str(timedelta(seconds=sum(durations) / num)).split('.')[0], 'best_pair': bp_pair, 'best_rate': round(bp_rate * 100, 2),