mirror of
https://github.com/freqtrade/freqtrade.git
synced 2024-11-10 10:21:59 +00:00
Use timestamp() instead of strftime
this will avoid a bug shifting epoch time by 1 hour: https://stackoverflow.com/questions/11743019/convert-python-datetime-to-epoch-with-strftime
This commit is contained in:
parent
12e455cbf5
commit
bfde33c945
|
@ -234,8 +234,8 @@ class Backtesting(object):
|
|||
# record a tuple of pair, current_profit_percent,
|
||||
# entry-date, duration
|
||||
records.append((pair, trade_entry.profit_percent,
|
||||
trade_entry.open_time.strftime('%s'),
|
||||
trade_entry.close_time.strftime('%s'),
|
||||
trade_entry.open_time.timestamp(),
|
||||
trade_entry.close_time.timestamp(),
|
||||
index, trade_entry.trade_duration))
|
||||
else:
|
||||
# Set lock_pair_until to end of testing period if trade could not be closed
|
||||
|
|
Loading…
Reference in New Issue
Block a user