Skip to content

Commit c63fba2

Browse files
committed
chore: rename flag to better match what it does
1 parent c8d74ba commit c63fba2

File tree

6 files changed

+8
-8
lines changed

6 files changed

+8
-8
lines changed

freqtrade/exchange/binance.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ class Binance(Exchange):
5151
"funding_fee_candle_limit": 1000,
5252
"stoploss_order_types": {"limit": "stop", "market": "stop_market"},
5353
"stoploss_blocks_assets": False, # Stoploss orders do not block assets
54-
"stoploss_fetch_requires_stop_param": True,
54+
"stoploss_query_requires_stop_flag": True,
5555
"stoploss_algo_order_info_id": "actualOrderId",
5656
"tickers_have_price": False,
5757
"floor_leverage": True,

freqtrade/exchange/bitget.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class Bitget(Exchange):
3131
"stop_price_prop": "stopPrice",
3232
"stoploss_blocks_assets": False, # Stoploss orders do not block assets
3333
"stoploss_order_types": {"limit": "limit", "market": "market"},
34-
"stoploss_fetch_requires_stop_param": True,
34+
"stoploss_query_requires_stop_flag": True,
3535
"ohlcv_candle_limit": 200, # 200 for historical candles, 1000 for recent ones.
3636
"order_time_in_force": ["GTC", "FOK", "IOC", "PO"],
3737
}

freqtrade/exchange/exchange.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ class Exchange:
132132
"stop_price_prop": "stopLossPrice", # Used for stoploss_on_exchange response parsing
133133
"stoploss_order_types": {},
134134
"stoploss_blocks_assets": True, # By default stoploss orders block assets
135-
"stoploss_fetch_requires_stop_param": False, # Require "stop": True" to fetch stop orders
135+
"stoploss_query_requires_stop_flag": False, # Require "stop": True" to fetch stop orders
136136
"order_time_in_force": ["GTC"],
137137
"ohlcv_params": {},
138138
"ohlcv_has_history": True, # Some exchanges (Kraken) don't provide history via ohlcv
@@ -1688,7 +1688,7 @@ def fetch_order(self, order_id: str, pair: str, params: dict | None = None) -> C
16881688
def fetch_stoploss_order(
16891689
self, order_id: str, pair: str, params: dict | None = None
16901690
) -> CcxtOrder:
1691-
if self.get_option("stoploss_fetch_requires_stop_param"):
1691+
if self.get_option("stoploss_query_requires_stop_flag"):
16921692
params = params or {}
16931693
params["stop"] = True
16941694
order = self.fetch_order(order_id, pair, params)
@@ -1760,7 +1760,7 @@ def cancel_order(self, order_id: str, pair: str, params: dict | None = None) ->
17601760
raise OperationalException(e) from e
17611761

17621762
def cancel_stoploss_order(self, order_id: str, pair: str, params: dict | None = None) -> dict:
1763-
if self.get_option("stoploss_fetch_requires_stop_param"):
1763+
if self.get_option("stoploss_query_requires_stop_flag"):
17641764
params = params or {}
17651765
params["stop"] = True
17661766
return self.cancel_order(order_id, pair, params)

freqtrade/exchange/exchange_types.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class FtHas(TypedDict, total=False):
1919
stop_price_type_value_mapping: dict
2020
stoploss_order_types: dict[str, str]
2121
stoploss_blocks_assets: bool
22-
stoploss_fetch_requires_stop_param: bool
22+
stoploss_query_requires_stop_flag: bool
2323
stoploss_algo_order_info_id: str
2424
# ohlcv
2525
ohlcv_params: dict

freqtrade/exchange/gate.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ class Gate(Exchange):
3030
"stoploss_order_types": {"limit": "limit"},
3131
"stop_price_param": "stopPrice",
3232
"stop_price_prop": "stopPrice",
33-
"stoploss_fetch_requires_stop_param": True,
33+
"stoploss_query_requires_stop_flag": True,
3434
"stoploss_algo_order_info_id": "fired_order_id",
3535
"l2_limit_upper": 1000,
3636
"marketOrderRequiresPrice": True,

freqtrade/exchange/okx.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class Okx(Exchange):
3131
"ohlcv_candle_limit": 100, # Warning, special case with data prior to X months
3232
"stoploss_order_types": {"limit": "limit"},
3333
"stoploss_on_exchange": True,
34-
"stoploss_fetch_requires_stop_param": True,
34+
"stoploss_query_requires_stop_flag": True,
3535
"trades_has_history": False, # Endpoint doesn't have a "since" parameter
3636
"ws_enabled": True,
3737
}

0 commit comments

Comments
 (0)