Fix: Importar 'services' y 'cache_manager' en main.py

This commit is contained in:
desoladorxx
2026-07-22 17:00:42 -05:00
parent 1edbb89ce0
commit fe6296a07d

View File

@@ -11,8 +11,12 @@ from dotenv import load_dotenv
# Cargar variables de entorno desde .env
load_dotenv()
import services
from cache_manager import start_background_refresh, cache_stats
app = FastAPI(title="Dashboard Leads API", version="1.0")
# Orígenes CORS configurables (por defecto permite todo o el dominio configurado)
cors_env = os.getenv("CORS_ORIGINS", "*")
origins = [o.strip() for o in cors_env.split(",") if o.strip()] if cors_env != "*" else ["*"]