]> Piment Noir Git Repositories - freqai-strategies.git/commitdiff
refactor(qav3): typing
authorJérôme Benoit <jerome.benoit@piment-noir.org>
Thu, 13 Mar 2025 18:04:57 +0000 (19:04 +0100)
committerJérôme Benoit <jerome.benoit@piment-noir.org>
Thu, 13 Mar 2025 18:04:57 +0000 (19:04 +0100)
Signed-off-by: Jérôme Benoit <jerome.benoit@piment-noir.org>
quickadapter/user_data/strategies/QuickAdapterV3.py

index beaf97a7435ff0262e3a9ff0c43ba38384d436ca..c9739f73f321671583022c1533a65d0f051ded26 100644 (file)
@@ -72,11 +72,11 @@ class QuickAdapterV3(IStrategy):
     process_only_new_candles = True
 
     @property
-    def can_short(self):
+    def can_short(self) -> bool:
         return self.is_short_allowed()
 
     @property
-    def plot_config(self):
+    def plot_config(self) -> dict:
         return {
             "main_plot": {},
             "subplots": {
@@ -97,7 +97,7 @@ class QuickAdapterV3(IStrategy):
         }
 
     @property
-    def protections(self):
+    def protections(self) -> list:
         fit_live_predictions_candles = self.freqai_info.get(
             "fit_live_predictions_candles", 100
         )
@@ -122,7 +122,7 @@ class QuickAdapterV3(IStrategy):
     use_exit_signal = True
 
     @property
-    def startup_candle_count(self):
+    def startup_candle_count(self) -> int:
         return int(self.freqai_info.get("fit_live_predictions_candles", 100) / 2)
 
     def bot_start(self, **kwargs) -> None: