freqtrade/freqtrade · error · OperationalException
You are trying to use a FreqAI strategy with process_only_ne
Error message
You are trying to use a FreqAI strategy with process_only_new_candles = False. This is not supported by FreqAI, and it is therefore aborting.
What it means
FreqAI's dry/live execution path (FreqAI.extract_data_and_train_model / update_scheduled_model) requires strategy.process_only_new_candles = True. FreqAI trains on a fixed candle snapshot, and processing every throttle iteration would retrain/repeat work inconsistently, so a False value aborts with OperationalException.
Source
Thrown at freqtrade/freqai/freqai_interface.py:447
dk.append_predictions(append_df)
dk.save_backtesting_prediction(append_df)
def start_live(
self, dataframe: DataFrame, metadata: dict, strategy: IStrategy, dk: FreqaiDataKitchen
) -> FreqaiDataKitchen:
"""
The main broad execution for dry/live. This function will check if a retraining should be
performed, and if so, retrain and reset the model.
:param dataframe: DataFrame = strategy passed dataframe
:param metadata: Dict = pair metadata
:param strategy: IStrategy = currently employed strategy
dk: FreqaiDataKitchen = Data management/analysis tool associated to present pair only
:returns:
dk: FreqaiDataKitchen = Data management/analysis tool associated to present pair only
"""
if not strategy.process_only_new_candles:
raise OperationalException(
"You are trying to use a FreqAI strategy with "
"process_only_new_candles = False. This is not supported "
"by FreqAI, and it is therefore aborting."
)
# get the model metadata associated with the current pair
(_, trained_timestamp) = self.dd.get_pair_dict_info(metadata["pair"])
# append the historic data once per round
if self.dd.historic_data:
self.dd.update_historic_data(strategy, dk)
logger.debug(f"Updating historic data on pair {metadata['pair']}")
self.track_current_candle()
(_, new_trained_timerange, data_load_timerange) = dk.check_if_new_training_required(
trained_timestamp
)
dk.set_paths(metadata["pair"], new_trained_timerange.stopts)View on GitHub (pinned to 1c8edfe4d1)
Solutions
- Set process_only_new_candles = True in the FreqAI strategy class
- Remove or set 'process_only_new_candles': true in the config JSON
- Use the FreqaiExampleStrategy template, which ships with the correct value
Example fix
# before
class MyFreqaiStrategy(IStrategy):
process_only_new_candles = False
# after
class MyFreqaiStrategy(IStrategy):
process_only_new_candles = True Defensive patterns
Strategy: validation
Validate before calling
# Guard before 'freqtrade trade'
process_only_new = config.get('process_only_new_candles',
getattr(strategy, 'process_only_new_candles', True))
assert process_only_new is True, 'FreqAI requires process_only_new_candles = True' Type guard
def freqai_strategy_ready(strategy) -> bool:
return bool(getattr(strategy, 'process_only_new_candles', False)) is True Prevention
- Set process_only_new_candles = True in every FreqAI strategy
- Make sure the config does not override the strategy attribute to false
When it happens
Trigger: Starting dry-run or live trading ('freqtrade trade') with a FreqAI-enabled strategy and config where process_only_new_candles is set to False (in strategy attribute or config 'process_only_new_candles': false).
Common situations: User starts from a scalping strategy template that sets process_only_new_candles = False for faster reaction; config overrides the strategy attribute with 'process_only_new_candles': false.
Related errors
- self.class_names is empty, set self.freqai.class_names = ['c
- Using analyze-per-epoch parameter is not supported with a Fr
- Main timeframe of {main_tf} must be smaller or equal to Freq
- Using timerange parameter is not supported with --freqai-bac
- Using --freqai-backtest-live-models parameter is only suppor
AI-assisted analysis of freqtrade/freqtrade@1c8edfe4d1 (2026-08-15).
Data as JSON: /api/errors/4ad8377dabe25020.
Report an issue: GitHub.