Procházet zdrojové kódy

解构任务提交完成

luojunhui před 9 hodinami
rodič
revize
511efa7a50

+ 2 - 2
app/domains/decode_task/ad_platform_articles_decode/entrance.py

@@ -52,7 +52,7 @@ class AdPlatformArticlesDecodeTask(AdPlatformArticlesDecodeConst):
             )
             return
 
-        task_id = response.get("data", {}).get("task_id")
+        task_id = response.get("data", {}).get("task_id") or response.get("data", {}).get("taskId")
         if not task_id:
             # 解构任务创建失败
             await self.mapper.update_article_decode_status(
@@ -135,7 +135,7 @@ class AdPlatformArticlesDecodeTask(AdPlatformArticlesDecodeConst):
             return
 
         response_data = response.get("data", {})
-        response_task_id = response_data.get("taskId")
+        response_task_id = response_data.get("taskId") or response_data.get("task_id")
         if task_id != response_task_id:
             # 解构任务获取失败
             await self.mapper.update_decode_task_status(