|
@@ -469,7 +469,7 @@ class XiaoniangaoHour:
|
|
|
try:
|
|
|
befor_yesterday = (datetime.date.today() + datetime.timedelta(days=-3)).strftime("%Y-%m-%d %H:%M:%S")
|
|
|
update_time_stamp = int(time.mktime(time.strptime(befor_yesterday, "%Y-%m-%d %H:%M:%S")))
|
|
|
- select_sql = f""" select * from crawler_xiaoniangao_hour where crawler_time_stamp >= {update_time_stamp} """
|
|
|
+ select_sql = f""" select * from crawler_xiaoniangao_hour where crawler_time_stamp >= {update_time_stamp} GROUP BY out_video_id """
|
|
|
update_video_list = MysqlHelper.get_values(log_type, crawler, select_sql, env)
|
|
|
if len(update_video_list) == 0:
|
|
|
Common.logger(log_type, crawler).info("暂无需要更新的小时榜数据\n")
|