Skip to content

Commit fd5ded4

Browse files
committed
Merge branch 'green1052-main'
2 parents 9b8a78a + d5150a4 commit fd5ded4

File tree

6 files changed

+33
-55
lines changed

6 files changed

+33
-55
lines changed

NostalgiaForInfinityX.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
## ##
5151
## For optimal performance, suggested to use between 4 and 6 open trades, with unlimited stake. ##
5252
## A pairlist with 40 to 80 pairs. Volume pairlist works well. ##
53-
## Prefer stable coin (USDT, BUSDT etc) pairs, instead of BTC or ETH pairs. ##
53+
## Prefer stable coin (USDT, USDC etc) pairs, instead of BTC or ETH pairs. ##
5454
## Highly recommended to blacklist leveraged tokens (*BULL, *BEAR, *UP, *DOWN etc). ##
5555
## Ensure that you don't override any variables in you config.json. Especially ##
5656
## the timeframe (must be 5m). ##

NostalgiaForInfinityX2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
## ##
3333
## For optimal performance, suggested to use between 4 and 6 open trades, with unlimited stake. ##
3434
## A pairlist with 40 to 80 pairs. Volume pairlist works well. ##
35-
## Prefer stable coin (USDT, BUSDT etc) pairs, instead of BTC or ETH pairs. ##
35+
## Prefer stable coin (USDT, USDC etc) pairs, instead of BTC or ETH pairs. ##
3636
## Highly recommended to blacklist leveraged tokens (*BULL, *BEAR, *UP, *DOWN etc). ##
3737
## Ensure that you don't override any variables in you config.json. Especially ##
3838
## the timeframe (must be 5m). ##

NostalgiaForInfinityX3.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
## ##
3434
## For optimal performance, suggested to use between 4 and 6 open trades, with unlimited stake. ##
3535
## A pairlist with 40 to 80 pairs. Volume pairlist works well. ##
36-
## Prefer stable coin (USDT, BUSDT etc) pairs, instead of BTC or ETH pairs. ##
36+
## Prefer stable coin (USDT, USDC etc) pairs, instead of BTC or ETH pairs. ##
3737
## Highly recommended to blacklist leveraged tokens (*BULL, *BEAR, *UP, *DOWN etc). ##
3838
## Ensure that you don't override any variables in you config.json. Especially ##
3939
## the timeframe (must be 5m). ##

NostalgiaForInfinityX4.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
## ##
3434
## For optimal performance, suggested to use between 4 and 6 open trades, with unlimited stake. ##
3535
## A pairlist with 40 to 80 pairs. Volume pairlist works well. ##
36-
## Prefer stable coin (USDT, BUSDT etc) pairs, instead of BTC or ETH pairs. ##
36+
## Prefer stable coin (USDT, USDC etc) pairs, instead of BTC or ETH pairs. ##
3737
## Highly recommended to blacklist leveraged tokens (*BULL, *BEAR, *UP, *DOWN etc). ##
3838
## Ensure that you don't override any variables in you config.json. Especially ##
3939
## the timeframe (must be 5m). ##

NostalgiaForInfinityX5.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
## ##
3232
## For optimal performance, suggested to use between 4 and 6 open trades, with unlimited stake. ##
3333
## A pairlist with 40 to 80 pairs. Volume pairlist works well. ##
34-
## Prefer stable coin (USDT, BUSDT etc) pairs, instead of BTC or ETH pairs. ##
34+
## Prefer stable coin (USDT, USDC etc) pairs, instead of BTC or ETH pairs. ##
3535
## Highly recommended to blacklist leveraged tokens (*BULL, *BEAR, *UP, *DOWN etc). ##
3636
## Ensure that you don't override any variables in you config.json. Especially ##
3737
## the timeframe (must be 5m). ##

NostalgiaForInfinityX6.py

Lines changed: 28 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
## ##
3232
## For optimal performance, suggested to use between 6 and 12 open trades, with unlimited stake. ##
3333
## A pairlist with 40 to 80 pairs. Volume pairlist works well. ##
34-
## Prefer stable coin (USDT, BUSDT etc) pairs, instead of BTC or ETH pairs. ##
34+
## Prefer stable coin (USDT, USDC etc) pairs, instead of BTC or ETH pairs. ##
3535
## Highly recommended to blacklist leveraged tokens (*BULL, *BEAR, *UP, *DOWN etc). ##
3636
## Ensure that you don't override any variables in you config.json. Especially ##
3737
## the timeframe (must be 5m). ##
@@ -683,55 +683,33 @@ def __init__(self, config: dict) -> None:
683683
"sell_profit_only" in self.config and self.config["sell_profit_only"]
684684
):
685685
self.exit_profit_only = True
686-
if "num_cores_indicators_calc" in self.config:
687-
self.num_cores_indicators_calc = self.config["num_cores_indicators_calc"]
688-
689-
if "custom_fee_open_rate" in self.config:
690-
self.custom_fee_open_rate = self.config["custom_fee_open_rate"]
691-
if "custom_fee_close_rate" in self.config:
692-
self.custom_fee_close_rate = self.config["custom_fee_close_rate"]
693-
694-
if "futures_mode_leverage" in self.config:
695-
self.futures_mode_leverage = self.config["futures_mode_leverage"]
696-
if "futures_mode_leverage_rebuy_mode" in self.config:
697-
self.futures_mode_leverage_rebuy_mode = self.config["futures_mode_leverage_rebuy_mode"]
698-
if "futures_mode_leverage_grind_mode" in self.config:
699-
self.futures_mode_leverage_grind_mode = self.config["futures_mode_leverage_grind_mode"]
700-
701-
if "futures_max_open_trades_long" in self.config:
702-
self.futures_max_open_trades_long = self.config["futures_max_open_trades_long"]
703-
if "futures_max_open_trades_short" in self.config:
704-
self.futures_max_open_trades_short = self.config["futures_max_open_trades_short"]
705-
706-
if "stop_threshold_doom_spot" in self.config:
707-
self.stop_threshold_doom_spot = self.config["stop_threshold_doom_spot"]
708-
if "stop_threshold_doom_futures" in self.config:
709-
self.stop_threshold_doom_futures = self.config["stop_threshold_doom_futures"]
710-
if "stop_threshold_rapid_spot" in self.config:
711-
self.stop_threshold_rapid_spot = self.config["stop_threshold_rapid_spot"]
712-
if "stop_threshold_rapid_futures" in self.config:
713-
self.stop_threshold_rapid_futures = self.config["stop_threshold_rapid_futures"]
714-
715-
if "derisk_enable" in self.config:
716-
self.derisk_enable = self.config["derisk_enable"]
717-
if "stops_enable" in self.config:
718-
self.stops_enable = self.config["stops_enable"]
719-
720-
if "regular_mode_derisk_1_spot" in self.config:
721-
self.regular_mode_derisk_1_spot = self.config["regular_mode_derisk_1_spot"]
722-
if "regular_mode_derisk_spot" in self.config:
723-
self.regular_mode_derisk_spot = self.config["regular_mode_derisk_spot"]
724-
if "regular_mode_derisk_1_futures" in self.config:
725-
self.regular_mode_derisk_1_futures = self.config["regular_mode_derisk_1_futures"]
726-
if "regular_mode_derisk_futures" in self.config:
727-
self.regular_mode_derisk_futures = self.config["regular_mode_derisk_futures"]
728-
729-
if "grind_mode_max_slots" in self.config:
730-
self.grind_mode_max_slots = self.config["grind_mode_max_slots"]
731-
if "grind_mode_coins" in self.config:
732-
self.grind_mode_coins = self.config["grind_mode_coins"]
733-
if "max_slippage" in self.config:
734-
self.max_slippage = self.config["max_slippage"]
686+
687+
for config in [
688+
"num_cores_indicators_calc",
689+
"custom_fee_open_rate",
690+
"custom_fee_close_rate",
691+
"futures_mode_leverage",
692+
"futures_mode_leverage_rebuy_mode",
693+
"futures_mode_leverage_grind_mode",
694+
"futures_max_open_trades_long",
695+
"futures_max_open_trades_short",
696+
"stop_threshold_doom_spot",
697+
"stop_threshold_doom_futures",
698+
"stop_threshold_rapid_spot",
699+
"stop_threshold_rapid_futures",
700+
"derisk_enable",
701+
"stops_enable",
702+
"regular_mode_derisk_1_spot",
703+
"regular_mode_derisk_spot",
704+
"regular_mode_derisk_1_futures",
705+
"regular_mode_derisk_futures",
706+
"grind_mode_max_slots",
707+
"grind_mode_coins",
708+
"max_slippage"
709+
]:
710+
if config in self.config:
711+
setattr(self, config, self.config[config])
712+
735713
if self.target_profit_cache is None:
736714
bot_name = ""
737715
if "bot_name" in self.config:

0 commit comments

Comments
 (0)