create a task
Browse files
App/Editor/editorRoutes.py
CHANGED
@@ -8,8 +8,8 @@ videditor_router = APIRouter(tags=["vidEditor"])
|
|
8 |
|
9 |
@videditor_router.post("/create-video")
|
10 |
async def create_video(videoRequest: EditorRequest, background_task: BackgroundTasks):
|
11 |
-
background_task.add_task(celery_task, videoRequest)
|
12 |
-
|
13 |
return {"task_id": "started"}
|
14 |
|
15 |
|
|
|
8 |
|
9 |
@videditor_router.post("/create-video")
|
10 |
async def create_video(videoRequest: EditorRequest, background_task: BackgroundTasks):
|
11 |
+
# background_task.add_task(celery_task, videoRequest)
|
12 |
+
result = celery_task.delay(videoRequest)
|
13 |
return {"task_id": "started"}
|
14 |
|
15 |
|