Add step library foundation and user preferences #24

Merged
chihlasm merged 6 commits from feature/step-library-and-preferences into main 2026-02-03 07:07:47 +00:00
Showing only changes of commit 46da0d78fd - Show all commits

View File

@@ -20,6 +20,7 @@ async def lifespan(app: FastAPI):
# Startup
logger.info("Starting Patherly API server...")
logger.info(f"Environment: {'Development' if settings.DEBUG else 'Production'}")
logger.info(f"ALLOW_RAILWAY_ORIGINS: {settings.ALLOW_RAILWAY_ORIGINS}")
# Note: In production, use Alembic migrations instead of init_db
# await init_db()
yield
@@ -87,3 +88,13 @@ async def root():
async def health_check():
"""Health check endpoint."""
return {"status": "healthy"}
@app.get("/debug/cors")
async def debug_cors():
"""Debug endpoint to check CORS configuration."""
return {
"allow_railway_origins": settings.ALLOW_RAILWAY_ORIGINS,
"cors_mode": "regex" if settings.ALLOW_RAILWAY_ORIGINS else "list",
"allowed_origins": settings.allowed_origins if not settings.ALLOW_RAILWAY_ORIGINS else "*.up.railway.app (regex)"
}