From 8afcaeeed988514e2ce2439e36e64c3628a67d44 Mon Sep 17 00:00:00 2001 From: Joe Schr <8218910+TheJoeSchr@users.noreply.github.com> Date: Fri, 17 May 2024 15:58:29 +0200 Subject: [PATCH] `trades()`: add lookahead warning to docstring --- freqtrade/data/dataprovider.py | 1 + 1 file changed, 1 insertion(+) diff --git a/freqtrade/data/dataprovider.py b/freqtrade/data/dataprovider.py index d9c302adb..809dc5c02 100644 --- a/freqtrade/data/dataprovider.py +++ b/freqtrade/data/dataprovider.py @@ -502,6 +502,7 @@ class DataProvider: """ Get candle (TRADES) data for the given pair as DataFrame Please use the `available_pairs` method to verify which pairs are currently cached. + This is not meant to be used in callbacks because of lookahead bias. :param pair: pair to get the data for :param timeframe: Timeframe to get data for :param candle_type: '', mark, index, premiumIndex, or funding_rate