Fix typo
This commit is contained in:
parent
2f1d9696cd
commit
3929ad4e1f
@ -53,7 +53,7 @@ class FreqtradeBot:
|
|||||||
|
|
||||||
self._heartbeat_msg = 0
|
self._heartbeat_msg = 0
|
||||||
|
|
||||||
self.hearbeat_interval = self.config.get('internals', {}).get('heartbeat_interval', 60)
|
self.heartbeat_interval = self.config.get('internals', {}).get('heartbeat_interval', 60)
|
||||||
|
|
||||||
self.strategy: IStrategy = StrategyResolver(self.config).strategy
|
self.strategy: IStrategy = StrategyResolver(self.config).strategy
|
||||||
|
|
||||||
@ -155,9 +155,9 @@ class FreqtradeBot:
|
|||||||
self.check_handle_timedout()
|
self.check_handle_timedout()
|
||||||
Trade.session.flush()
|
Trade.session.flush()
|
||||||
|
|
||||||
if (self.hearbeat_interval
|
if (self.heartbeat_interval
|
||||||
and (arrow.utcnow().timestamp - self._heartbeat_msg > self.hearbeat_interval)):
|
and (arrow.utcnow().timestamp - self._heartbeat_msg > self.heartbeat_interval)):
|
||||||
logger.info(f"Freqtrade heartbeat. PID={getpid()}")
|
logger.info(f"Bot heartbeat. PID={getpid()}")
|
||||||
self._heartbeat_msg = arrow.utcnow().timestamp
|
self._heartbeat_msg = arrow.utcnow().timestamp
|
||||||
|
|
||||||
def _extend_whitelist_with_trades(self, whitelist: List[str], trades: List[Any]):
|
def _extend_whitelist_with_trades(self, whitelist: List[str], trades: List[Any]):
|
||||||
|
@ -3656,7 +3656,7 @@ def test_process_i_am_alive(default_conf, mocker, caplog):
|
|||||||
mocker.patch('freqtrade.exchange.Exchange.exchange_has', MagicMock(return_value=True))
|
mocker.patch('freqtrade.exchange.Exchange.exchange_has', MagicMock(return_value=True))
|
||||||
|
|
||||||
ftbot = get_patched_freqtradebot(mocker, default_conf)
|
ftbot = get_patched_freqtradebot(mocker, default_conf)
|
||||||
message = r"Freqtrade heartbeat. PID=.*"
|
message = r"Bot heartbeat\. PID=.*"
|
||||||
ftbot.process()
|
ftbot.process()
|
||||||
assert log_has_re(message, caplog)
|
assert log_has_re(message, caplog)
|
||||||
assert ftbot._heartbeat_msg != 0
|
assert ftbot._heartbeat_msg != 0
|
||||||
|
Loading…
Reference in New Issue
Block a user