Browse Source

去重规则修改

罗俊辉 1 year ago
parent
commit
185f1d03f7
1 changed files with 2 additions and 2 deletions
  1. 2 2
      gongzhonghao/gongzhonghao_author/gongzhonghao_author.py

+ 2 - 2
gongzhonghao/gongzhonghao_author/gongzhonghao_author.py

@@ -660,8 +660,8 @@ class GongzhonghaoAuthor:
     @classmethod
     def repeat_video(cls, log_type, crawler, video_id, video_title, env):
         # sql = f""" select * from crawler_video where platform="公众号" and out_video_id="{video_id}"; """
-        # sql = f""" select * from crawler_video where platform in ("{crawler}","{cls.platform}") and out_video_id="{video_id}" ; """
-        sql = f"""select * from crawler_video where platform = "{crawler}" and (out_video_id="{video_id}" or video_title="{video_title}") ;"""
+        sql = f""" select * from crawler_video where platform in ("{crawler}","{cls.platform}") and out_video_id="{video_id}" ; """
+        # sql = f"""select * from crawler_video where platform = "{crawler}" and (out_video_id="{video_id}" or video_title="{video_title}") ;"""
         repeat_video = MysqlHelper.get_values(log_type, crawler, sql, env)
         return len(repeat_video)