From dabda5e80daf7902f693e7577e88a176cfdc3018 Mon Sep 17 00:00:00 2001 From: MuslemRahimi Date: Mon, 13 Jan 2025 15:07:08 +0100 Subject: [PATCH] bugfixing --- ...earnings_price_action.py => cron_earnings_price_reaction.py} | 2 +- app/main.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) rename app/{cron_earnings_price_action.py => cron_earnings_price_reaction.py} (96%) diff --git a/app/cron_earnings_price_action.py b/app/cron_earnings_price_reaction.py similarity index 96% rename from app/cron_earnings_price_action.py rename to app/cron_earnings_price_reaction.py index 09ea586..0bac9f1 100644 --- a/app/cron_earnings_price_action.py +++ b/app/cron_earnings_price_reaction.py @@ -171,7 +171,7 @@ try: con = sqlite3.connect('stocks.db') cursor = con.cursor() cursor.execute("PRAGMA journal_mode = wal") - cursor.execute("SELECT DISTINCT symbol FROM stocks WHERE symbol NOT LIKE '%.%' AND symbol NOT LIKE '%-%'") + cursor.execute("SELECT DISTINCT symbol FROM stocks WHERE symbol NOT LIKE '%.%'") stock_symbols = [row[0] for row in cursor.fetchall()] #stock_symbols = ['AMD'] diff --git a/app/main.py b/app/main.py index c97370b..0fee218 100755 --- a/app/main.py +++ b/app/main.py @@ -3111,7 +3111,7 @@ async def get_wiim(data:TickerData, api_key: str = Security(get_api_key)): res = [] redis_client.set(cache_key, orjson.dumps(res)) - redis_client.expire(cache_key, 60*60*2) + redis_client.expire(cache_key, 60*5) return res @app.get("/dashboard-info")