瀏覽代碼

按小时补充创意添加else模块,记录该时点不需要补充

liyuyi@c-top.com.cn 4 年之前
父節點
當前提交
792780c495
共有 1 個文件被更改,包括 5 次插入0 次删除
  1. 5 0
      ai_time_task_creative_handler.py

+ 5 - 0
ai_time_task_creative_handler.py

@@ -661,6 +661,11 @@ class AiUpCreativeByHour(tornado.web.RequestHandler):
                     logger.info("account_id=%s, 按小时补充创意: 没有成功获取到视频!" % account_id)
                     logger.info("account_id=%s, 按小时补充创意: 没有成功获取到视频!" % account_id)
                     self.write(json.dumps({"message": "account_id=%s, 按小时补充创意: 没有成功获取到视频!" % account_id}))
                     self.write(json.dumps({"message": "account_id=%s, 按小时补充创意: 没有成功获取到视频!" % account_id}))
                     self.flush()
                     self.flush()
+            else:
+                logger.info("account_id=%s, 按小时补充创意: 不需要补充!" % account_id)
+                self.write(json.dumps({"message": "account_id=%s, 按小时补充创意: 不需要补充!" % account_id}))
+                self.flush()
+
         except Exception:
         except Exception:
             logger.error("account_id = %s, traceback is %s" % (account_id, traceback.format_exc()))
             logger.error("account_id = %s, traceback is %s" % (account_id, traceback.format_exc()))
             self.write(json.dumps({"account_id": account_id, "message": traceback.format_exc(), "code": -1}))
             self.write(json.dumps({"account_id": account_id, "message": traceback.format_exc(), "code": -1}))