Browse Source

Merge branch 'dev-1209'

max_liu 3 days ago
parent
commit
5235993413
1 changed files with 3 additions and 3 deletions
  1. 3 3
      src/workflows/decode_workflow.py

+ 3 - 3
src/workflows/decode_workflow.py

@@ -475,14 +475,14 @@ class DecodeWorkflow(BaseGraphAgent):
             video_id = state.get("video_id", "")
             task_id = state.get("task_id")
             
-            if not video_id:
-                logger.warning("未提供 video_id,跳过数据库记录初始化")
+            if not task_id:
+                logger.warning("未提供 task_id,跳过数据库记录初始化")
                 return state
             
             db = next(get_db())
             try:
                 # 根据 video_id 查询是否已有记录
-                existing_record = db.query(DecodeVideo).filter_by(video_id=video_id).first()
+                existing_record = db.query(DecodeVideo).filter_by(task_id=task_id).first()
                 
                 if existing_record:
                     # 如果存在记录,使用现有的 task_id