fix: arreglar conexión con google auth y proceso de arreglar conexión entre paso2 y paso3

This commit is contained in:
Alexis
2026-04-14 10:29:25 +02:00
parent cb9030eb8d
commit f7bfc4b956
5 changed files with 83 additions and 41 deletions
+4 -4
View File
@@ -1,7 +1,7 @@
# api/routers/docit2mf_build.py
import logging
from fastapi import APIRouter, HTTPException
from fastapi import APIRouter, HTTPException, Request
from slowapi import Limiter
from slowapi.util import get_remote_address
from api.models.docit2mf_models import DoCIT2MFMultiRequest
@@ -14,11 +14,11 @@ logger = logging.getLogger(__name__)
@router.post("/doc-it2mf/build")
@limiter.limit("10/minute")
async def build_doc_it2mf(request: DoCIT2MFMultiRequest):
async def build_doc_it2mf(request: Request, body: DoCIT2MFMultiRequest):
results = []
try:
for level in request.levels:
for level in body.levels:
results.append(build_it2mf_from_level(level))
except ValueError as e:
logger.warning(f"Validation error in doc-it2mf/build: {str(e)}")
@@ -27,4 +27,4 @@ async def build_doc_it2mf(request: DoCIT2MFMultiRequest):
logger.error(f"Unexpected error in doc-it2mf/build: {str(e)}", exc_info=True)
raise HTTPException(status_code=500, detail="Internal server error")
return {"levels": results}
return {"levels": results}