From eef3c01da73008c9f9a4bb03ff5c4106cbbf68fa Mon Sep 17 00:00:00 2001 From: Matthias Date: Thu, 18 Jun 2020 19:46:03 +0200 Subject: [PATCH] Fix function header formatting --- docs/strategy-advanced.md | 4 ++-- freqtrade/strategy/interface.py | 4 ++-- freqtrade/templates/subtemplates/strategy_methods_advanced.j2 | 4 ++-- tests/strategy/test_interface.py | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/docs/strategy-advanced.md b/docs/strategy-advanced.md index 100e96b81..c576cb46e 100644 --- a/docs/strategy-advanced.md +++ b/docs/strategy-advanced.md @@ -168,8 +168,8 @@ class Awesomestrategy(IStrategy): # ... populate_* methods - def confirm_trade_exit(self, pair: str, trade: Trade, order_type: str, amount: float, rate: float, - time_in_force: str, sell_reason: str, ** kwargs) -> bool: + def confirm_trade_exit(self, pair: str, trade: Trade, order_type: str, amount: float, + rate: float, time_in_force: str, sell_reason: str, **kwargs) -> bool: """ Called right before placing a regular sell order. Timing for this function is critical, so avoid doing heavy computations or diff --git a/freqtrade/strategy/interface.py b/freqtrade/strategy/interface.py index 969259446..f8e59ac7b 100644 --- a/freqtrade/strategy/interface.py +++ b/freqtrade/strategy/interface.py @@ -221,8 +221,8 @@ class IStrategy(ABC): """ return True - def confirm_trade_exit(self, pair: str, trade: Trade, order_type: str, amount: float, rate: float, - time_in_force: str, sell_reason: str, ** kwargs) -> bool: + def confirm_trade_exit(self, pair: str, trade: Trade, order_type: str, amount: float, + rate: float, time_in_force: str, sell_reason: str, **kwargs) -> bool: """ Called right before placing a regular sell order. Timing for this function is critical, so avoid doing heavy computations or diff --git a/freqtrade/templates/subtemplates/strategy_methods_advanced.j2 b/freqtrade/templates/subtemplates/strategy_methods_advanced.j2 index 28d2d1c1b..c7ce41bb7 100644 --- a/freqtrade/templates/subtemplates/strategy_methods_advanced.j2 +++ b/freqtrade/templates/subtemplates/strategy_methods_advanced.j2 @@ -34,8 +34,8 @@ def confirm_trade_entry(self, pair: str, order_type: str, amount: float, rate: f """ return True -def confirm_trade_exit(self, pair: str, trade: 'Trade', order_type: str, amount: float, rate: float, - time_in_force: str, sell_reason: str, ** kwargs) -> bool: +def confirm_trade_exit(self, pair: str, trade: Trade, order_type: str, amount: float, + rate: float, time_in_force: str, sell_reason: str, **kwargs) -> bool: """ Called right before placing a regular sell order. Timing for this function is critical, so avoid doing heavy computations or diff --git a/tests/strategy/test_interface.py b/tests/strategy/test_interface.py index 70ae067d7..381454622 100644 --- a/tests/strategy/test_interface.py +++ b/tests/strategy/test_interface.py @@ -9,7 +9,7 @@ from pandas import DataFrame from freqtrade.configuration import TimeRange from freqtrade.data.history import load_data -from freqtrade.exceptions import StrategyError, OperationalException +from freqtrade.exceptions import StrategyError from freqtrade.persistence import Trade from freqtrade.resolvers import StrategyResolver from freqtrade.strategy.strategy_wrapper import strategy_safe_wrapper