From 6fd7048cb5bd99ef0689c931ccd2148316974426 Mon Sep 17 00:00:00 2001 From: MuslemRahimi Date: Mon, 14 Apr 2025 18:07:15 +0200 Subject: [PATCH] bugfixing --- app/cron_market_movers.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/cron_market_movers.py b/app/cron_market_movers.py index 5d4ff9c..93691ac 100755 --- a/app/cron_market_movers.py +++ b/app/cron_market_movers.py @@ -21,6 +21,7 @@ api_key = os.getenv('FMP_API_KEY') market_cap_threshold = 10E9 volume_threshold = 50_000 +price_threshold = 10 def check_market_hours(): @@ -89,7 +90,7 @@ async def get_gainer_loser_active_stocks(symbols): price = data.get("price", None) # Ensure the stock meets criteria - if market_cap >= market_cap_threshold: + if market_cap >= market_cap_threshold and price >= price_threshold: if price and changes_percentage: res_list.append({ "symbol": symbol,