|
@@ -394,9 +394,12 @@ class AGC():
|
|
srt_new = SRT.getSrt(int(uid))
|
|
srt_new = SRT.getSrt(int(uid))
|
|
Common.logger("video").info(f"S{mark}的{platform}渠道音频ID{uid}")
|
|
Common.logger("video").info(f"S{mark}的{platform}渠道音频ID{uid}")
|
|
if error_count == 5:
|
|
if error_count == 5:
|
|
- Feishu.bot('recommend', 'AGC异常通知', f'{platform}渠道音频id为{uid},任务处理异常5次,该任务跳过,请检查格式!', name, mark_name)
|
|
|
|
|
|
+ Common.logger("video").info(f"{platform}渠道音频id为{uid},任务处理异常5次,该任务跳过,请检查格式,{name}")
|
|
|
|
+
|
|
|
|
+ # Feishu.bot('recommend', 'AGC异常通知', f'{platform}渠道音频id为{uid},任务处理异常5次,该任务跳过,请检查格式!', name, mark_name)
|
|
count += 1
|
|
count += 1
|
|
- time.sleep(300)
|
|
|
|
|
|
+ if platform == "常规":
|
|
|
|
+ time.sleep(300)
|
|
continue
|
|
continue
|
|
if srt_new:
|
|
if srt_new:
|
|
# 创建临时字幕文件
|
|
# 创建临时字幕文件
|
|
@@ -409,16 +412,20 @@ class AGC():
|
|
audio_duration = cls.get_audio_duration(audio_video)
|
|
audio_duration = cls.get_audio_duration(audio_video)
|
|
Common.logger("video").info(f"{mark}的{platform}渠道获音频秒数{audio_duration}")
|
|
Common.logger("video").info(f"{mark}的{platform}渠道获音频秒数{audio_duration}")
|
|
if int(audio_duration) >= 300:
|
|
if int(audio_duration) >= 300:
|
|
|
|
+ print(f"{mark}的{platform}渠道获取需要拼接的音频秒数为:{audio_duration},超过300秒不做拼接")
|
|
count += 1
|
|
count += 1
|
|
continue
|
|
continue
|
|
Common.logger("video").info(f"{mark}的{platform}渠道获取需要拼接的音频秒数为:{audio_duration}")
|
|
Common.logger("video").info(f"{mark}的{platform}渠道获取需要拼接的音频秒数为:{audio_duration}")
|
|
except Exception as e:
|
|
except Exception as e:
|
|
|
|
|
|
count += 1
|
|
count += 1
|
|
- time.sleep(150)
|
|
|
|
|
|
+ if platform == "常规":
|
|
|
|
+ time.sleep(150)
|
|
# 清空所有mp4数据
|
|
# 清空所有mp4数据
|
|
cls.clear_mp4_files(mark)
|
|
cls.clear_mp4_files(mark)
|
|
- Feishu.bot('recommend', 'AGC异常通知', f'{platform}任务下,{uid}音频格式填写错误该任务跳过,请关注', name, mark_name)
|
|
|
|
|
|
+ Common.logger("video1").info(f"{platform}任务下,{uid}音频格式填写错误该任务跳过,请关注,{name},异常信息:{e}")
|
|
|
|
+
|
|
|
|
+ # Feishu.bot('recommend', 'AGC异常通知', f'{platform}任务下,{uid}音频格式填写错误该任务跳过,请关注', name, mark_name)
|
|
continue
|
|
continue
|
|
|
|
|
|
if platform != "常规":
|
|
if platform != "常规":
|
|
@@ -523,7 +530,8 @@ class AGC():
|
|
Feishu.insert_columns("IbVVsKCpbhxhSJtwYOUc8S1jnWb", "jd9qD9", "ROWS", 1, 2)
|
|
Feishu.insert_columns("IbVVsKCpbhxhSJtwYOUc8S1jnWb", "jd9qD9", "ROWS", 1, 2)
|
|
time.sleep(random_wait_time)
|
|
time.sleep(random_wait_time)
|
|
Feishu.update_values("IbVVsKCpbhxhSJtwYOUc8S1jnWb", "jd9qD9", "A2:Z2", values)
|
|
Feishu.update_values("IbVVsKCpbhxhSJtwYOUc8S1jnWb", "jd9qD9", "A2:Z2", values)
|
|
- time.sleep(300)
|
|
|
|
|
|
+ if platform == "常规":
|
|
|
|
+ time.sleep(300)
|
|
except Exception as e:
|
|
except Exception as e:
|
|
error_count += 1
|
|
error_count += 1
|
|
Common.logger("video").warning(f"{mark}的视频拼接失败:{e}\n")
|
|
Common.logger("video").warning(f"{mark}的视频拼接失败:{e}\n")
|