Skip to content

Commit 14c9f78

Browse files
committed
refactor: Improve clarity of method name
1 parent 6c9c709 commit 14c9f78

File tree

1 file changed

+15
-13
lines changed

1 file changed

+15
-13
lines changed

freqtrade/optimize/backtesting.py

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -966,7 +966,7 @@ def _run_funding_fees(self, trade: LocalTrade, current_time: datetime, force: bo
966966
)
967967
)
968968

969-
def get_valid_price_and_stake(
969+
def get_valid_entry_price_and_stake(
970970
self,
971971
pair: str,
972972
row: tuple,
@@ -1089,18 +1089,20 @@ def _enter_trade(
10891089
stake_amount_ = stake_amount or (trade.stake_amount if trade else 0.0)
10901090
precision_price, precision_mode_price = self.get_pair_precision(pair, current_time)
10911091

1092-
propose_rate, stake_amount, leverage, min_stake_amount = self.get_valid_price_and_stake(
1093-
pair,
1094-
row,
1095-
row[OPEN_IDX],
1096-
stake_amount_,
1097-
direction,
1098-
current_time,
1099-
entry_tag,
1100-
trade,
1101-
order_type,
1102-
precision_price,
1103-
precision_mode_price,
1092+
propose_rate, stake_amount, leverage, min_stake_amount = (
1093+
self.get_valid_entry_price_and_stake(
1094+
pair,
1095+
row,
1096+
row[OPEN_IDX],
1097+
stake_amount_,
1098+
direction,
1099+
current_time,
1100+
entry_tag,
1101+
trade,
1102+
order_type,
1103+
precision_price,
1104+
precision_mode_price,
1105+
)
11041106
)
11051107

11061108
# replace proposed rate if another rate was requested

0 commit comments

Comments
 (0)