From 9bb0a90a97ad291b22f7616377df2b26768804fd Mon Sep 17 00:00:00 2001 From: tef Date: Wed, 29 Dec 2021 18:47:27 -0500 Subject: [PATCH] remove buy callback --- config_examples/Strategy002.py | 48 +++++++++++++++++----------------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/config_examples/Strategy002.py b/config_examples/Strategy002.py index 6586ef34a..283069d74 100644 --- a/config_examples/Strategy002.py +++ b/config_examples/Strategy002.py @@ -10,7 +10,7 @@ import talib.abstract as ta import freqtrade.vendor.qtpylib.indicators as qtpylib import numpy # noqa -PROJECT_DIR = "/home/ubuntu/workspace/execution/" +PROJECT_DIR = "/root/workspace/execution/" import sys sys.path.append(PROJECT_DIR) from executor import * @@ -140,26 +140,26 @@ class Strategy002(IStrategy): 'sell'] = 1 return dataframe - def confirm_trade_entry(self, pair: str, order_type: str, amount: float, rate: float, - time_in_force: str, current_time: datetime, **kwargs) -> bool: - """ - Called right before placing a buy order. - Timing for this function is critical, so avoid doing heavy computations or - network requests in this method. - - For full documentation please go to https://www.freqtrade.io/en/latest/strategy-advanced/ - - When not implemented by a strategy, returns True (always confirming). - - :param pair: Pair that's about to be bought. - :param order_type: Order type (as configured in order_types). usually limit or market. - :param amount: Amount in target (quote) currency that's going to be traded. - :param rate: Rate that's going to be used when using limit orders - :param time_in_force: Time in force. Defaults to GTC (Good-til-cancelled). - :param current_time: datetime object, containing the current datetime - :param **kwargs: Ensure to keep this here so updates to this won't break your strategy. - :return bool: When True is returned, then the buy-order is placed on the exchange. - False aborts the process - """ - self.executor.start_signal() - return True + # def confirm_trade_entry(self, pair: str, order_type: str, amount: float, rate: float, + # time_in_force: str, current_time: datetime, **kwargs) -> bool: + # """ + # Called right before placing a buy order. + # Timing for this function is critical, so avoid doing heavy computations or + # network requests in this method. + # + # For full documentation please go to https://www.freqtrade.io/en/latest/strategy-advanced/ + # + # When not implemented by a strategy, returns True (always confirming). + # + # :param pair: Pair that's about to be bought. + # :param order_type: Order type (as configured in order_types). usually limit or market. + # :param amount: Amount in target (quote) currency that's going to be traded. + # :param rate: Rate that's going to be used when using limit orders + # :param time_in_force: Time in force. Defaults to GTC (Good-til-cancelled). + # :param current_time: datetime object, containing the current datetime + # :param **kwargs: Ensure to keep this here so updates to this won't break your strategy. + # :return bool: When True is returned, then the buy-order is placed on the exchange. + # False aborts the process + # """ + # self.executor.start_signal() + # return True