zhangyong 1 年之前
父节点
当前提交
f921c9405a
共有 1 个文件被更改,包括 5 次插入1 次删除
  1. 5 1
      video_agc/agc_video_method.py

+ 5 - 1
video_agc/agc_video_method.py

@@ -327,7 +327,11 @@ class AgcVidoe():
             uid, srt, title_list = Material.get_all_data(feishu_id, link, mark)
             # 获取已入库的用户id
             user_id = cls.get_user_id(platform, mark)
-            user = random.choice(user_id)
+            if user_id:
+                user = random.choice(user_id)
+            else:
+                Common.logger("video").info(f"{mark}的{platform} 渠道无抓取的数据")
+                return ""
             user = str(user).replace('(', '').replace(')', '').replace(',', '')
             Common.logger("video").info(f"{mark}的{platform}渠道获取的用户ID:{user}")
             # 获取 未使用的视频链接