feat: Implement quiz attempt tracking and limits with persistence, and add background transcription for lessons.

This commit is contained in:
2026-01-16 16:29:15 -03:00
parent 42976236b3
commit 55aede97ed
4 changed files with 90 additions and 11 deletions
+10 -2
View File
@@ -594,6 +594,14 @@ pub async fn process_transcription(
)
.await;
// 4. Spawn background task
let pool_clone = pool.clone();
tokio::spawn(async move {
if let Err(e) = run_transcription_task(pool_clone, id).await {
tracing::error!("Transcription task failed for lesson {}: {}", id, e);
}
});
Ok(Json(updated_lesson))
}
@@ -1842,7 +1850,7 @@ pub async fn delete_module(
return Err(StatusCode::NOT_FOUND);
}
Ok(StatusCode::OK)
Ok(StatusCode::NO_CONTENT)
}
pub async fn delete_lesson(
@@ -1897,7 +1905,7 @@ pub async fn delete_lesson(
return Err(StatusCode::NOT_FOUND);
}
Ok(StatusCode::OK)
Ok(StatusCode::NO_CONTENT)
}
// User Management