@@ -26,7 +26,7 @@ def test_exchangews_init(mocker):
2626 assert exchange_ws ._background_tasks == set ()
2727 assert exchange_ws ._klines_watching == set ()
2828 assert exchange_ws ._klines_scheduled == set ()
29- assert exchange_ws .klines_last_refresh == {}
29+ assert exchange_ws ._klines_last_refresh == {}
3030 assert exchange_ws ._klines_last_request == {}
3131 # Cleanup
3232 exchange_ws .cleanup ()
@@ -258,7 +258,7 @@ async def test_exchangews_get_ohlcv(mocker, caplog):
258258 mocker .patch ("freqtrade.exchange.exchange_ws.ExchangeWS._start_forever" , MagicMock ())
259259
260260 exchange_ws = ExchangeWS (config , ccxt_object )
261- exchange_ws .klines_last_refresh = {
261+ exchange_ws ._klines_last_refresh = {
262262 ("ETH/USDT" , "1m" , CandleType .SPOT ): 1635840120000 ,
263263 ("ETH/USDT" , "5m" , CandleType .SPOT ): 1635840600000 ,
264264 }
@@ -287,7 +287,7 @@ async def test_exchangews_get_ohlcv(mocker, caplog):
287287
288288 # Change "received" times to be before the candle starts.
289289 # This should trigger the "time sync" warning.
290- exchange_ws .klines_last_refresh = {
290+ exchange_ws ._klines_last_refresh = {
291291 ("ETH/USDT" , "1m" , CandleType .SPOT ): 1635840110000 ,
292292 ("ETH/USDT" , "5m" , CandleType .SPOT ): 1635840600000 ,
293293 }
@@ -323,7 +323,7 @@ async def test_exchangews_get_ohlcv_missing_refresh_date(mocker, caplog):
323323 mocker .patch ("freqtrade.exchange.exchange_ws.ExchangeWS._start_forever" , MagicMock ())
324324
325325 exchange_ws = ExchangeWS (config , ccxt_object )
326- exchange_ws .klines_last_refresh = {}
326+ exchange_ws ._klines_last_refresh = {}
327327
328328 # No refresh-date entry should not raise KeyError.
329329 resp = await exchange_ws .get_ohlcv ("ETH/USDT" , "1m" , CandleType .SPOT , 1635840120000 )
@@ -355,7 +355,7 @@ def test_exchangews_continuous_stopped_task_exception(mocker, caplog):
355355
356356 paircomb = ("ETH/USDT" , "1m" , CandleType .SPOT )
357357 exchange_ws ._klines_scheduled .add (paircomb )
358- exchange_ws .klines_last_refresh [paircomb ] = 1
358+ exchange_ws ._klines_last_refresh [paircomb ] = 1
359359
360360 task = MagicMock ()
361361 task .cancelled .return_value = False
@@ -378,7 +378,7 @@ def side_effect(coro, loop):
378378
379379 assert task not in exchange_ws ._background_tasks
380380 assert paircomb not in exchange_ws ._klines_scheduled
381- assert paircomb not in exchange_ws .klines_last_refresh
381+ assert paircomb not in exchange_ws ._klines_last_refresh
382382 assert ccxt_object .ohlcvs ["ETH/USDT" ].get ("1m" ) is None
383383 assert run_threadsafe .call_count == 1
384384 assert log_has_re ("Unhandled exception in watch task callback for ETH/USDT, 1m" , caplog )
0 commit comments