Mbonea commited on
Commit
fb85bbb
1 Parent(s): 39f9575
Files changed (1) hide show
  1. App/Worker.py +2 -3
App/Worker.py CHANGED
@@ -205,9 +205,8 @@ def install_dependencies(directory: str):
205
 
206
 
207
  # @celery.task(name="uploadTime")
208
- def upload_video_to_youtube(task_data: dict):
209
  # Convert dict to Pydantic model
210
- task = YouTubeUploadTask(**task_data)
211
 
212
  # Build the command
213
  command = [
@@ -310,7 +309,7 @@ async def celery_task(video_task: EditorRequest):
310
  response: YouTubeUploadTask = tagger(narration="", response_model=YouTubeUploadTask)
311
 
312
  response.filename = output_dir
313
- upload_video_to_youtube()
314
  await cleanup_temp_directory(temp_dir, output_dir, video_task)
315
 
316
  # chain(
 
205
 
206
 
207
  # @celery.task(name="uploadTime")
208
+ def upload_video_to_youtube(task: YouTubeUploadTask):
209
  # Convert dict to Pydantic model
 
210
 
211
  # Build the command
212
  command = [
 
309
  response: YouTubeUploadTask = tagger(narration="", response_model=YouTubeUploadTask)
310
 
311
  response.filename = output_dir
312
+ upload_video_to_youtube(task=response)
313
  await cleanup_temp_directory(temp_dir, output_dir, video_task)
314
 
315
  # chain(