Fixed flake8 warnings
This commit is contained in:
parent
67d84e7514
commit
573de1cf08
@ -21,7 +21,6 @@ from freqtrade.persistence import PairLocks, Trade
|
||||
from freqtrade.strategy.strategy_wrapper import strategy_safe_wrapper
|
||||
from freqtrade.wallets import Wallets
|
||||
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
@ -482,7 +481,9 @@ class IStrategy(ABC):
|
||||
logger.debug('trigger: %s (pair=%s) buy=%s sell=%s',
|
||||
latest['date'], pair, str(buy), str(sell))
|
||||
timeframe_seconds = timeframe_to_seconds(timeframe)
|
||||
if self.ignore_expired_candle(latest_date=latest_date, timeframe_seconds=timeframe_seconds, buy=buy):
|
||||
if self.ignore_expired_candle(latest_date=latest_date,
|
||||
timeframe_seconds=timeframe_seconds,
|
||||
buy=buy):
|
||||
return False, sell
|
||||
return buy, sell
|
||||
|
||||
|
@ -117,7 +117,9 @@ def test_ignore_expired_candle(default_conf, ohlcv_history):
|
||||
mocked_history = ohlcv_history.copy()
|
||||
latest_date = mocked_history['date'].max()
|
||||
|
||||
assert strategy.ignore_expired_candle(latest_date=latest_date, timeframe_seconds=300, buy=True) is True
|
||||
assert strategy.ignore_expired_candle(latest_date=latest_date,
|
||||
timeframe_seconds=300,
|
||||
buy=True) is True
|
||||
|
||||
|
||||
def test_assert_df_raise(mocker, caplog, ohlcv_history):
|
||||
|
Loading…
Reference in New Issue
Block a user