added fix to reduce amount of outdated messages
This commit is contained in:
parent
62d936e11d
commit
06c329abec
@ -146,10 +146,11 @@ class Analyze(object):
|
|||||||
|
|
||||||
latest = dataframe.iloc[-1]
|
latest = dataframe.iloc[-1]
|
||||||
|
|
||||||
|
|
||||||
# Check if dataframe is out of date
|
# Check if dataframe is out of date
|
||||||
signal_date = arrow.get(latest['date'])
|
signal_date = arrow.get(latest['date'])
|
||||||
interval_minutes = constants.TICKER_INTERVAL_MINUTES[interval]
|
interval_minutes = constants.TICKER_INTERVAL_MINUTES[interval]
|
||||||
if signal_date < arrow.utcnow() - timedelta(minutes=(interval_minutes + 5)):
|
if signal_date < (arrow.utcnow() - timedelta(minutes=(interval_minutes + 5))):
|
||||||
logger.warning(
|
logger.warning(
|
||||||
'Outdated history for pair %s. Last tick is %s minutes old',
|
'Outdated history for pair %s. Last tick is %s minutes old',
|
||||||
pair,
|
pair,
|
||||||
|
Loading…
Reference in New Issue
Block a user