diff --git a/app/services/universe_service.py b/app/services/universe_service.py index db2d7c4..dc3e979 100644 --- a/app/services/universe_service.py +++ b/app/services/universe_service.py @@ -30,7 +30,7 @@ from app.services.sec_http_client import SECHttpClient logger = logging.getLogger(__name__) _CHUNK = 3000 # asyncpg 32767-param limit (10 cols × 3000 = 30000) -_PRICE_BATCH = 50 # tickers per yfinance bulk download (smaller = more responsive) +_PRICE_BATCH = 30 # tickers per yfinance bulk download _SEC_CONCURRENCY = 3 # concurrent SEC EDGAR companyfacts requests _SCREEN_PAGE = 250 # max per yf.screen() call @@ -494,7 +494,7 @@ class UniverseService: interval="1mo", auto_adjust=False, progress=False, - threads=True, + threads=False, # disable internal thread pool — prevents OS thread explosion group_by="ticker", ) except Exception as e: