Explorar o código

优化更新每日发送文章code

luojunhui hai 4 meses
pai
achega
abdbf12396
Modificáronse 1 ficheiros con 23 adicións e 0 borrados
  1. 23 0
      check_articles_task.py

+ 23 - 0
check_articles_task.py

@@ -0,0 +1,23 @@
+"""
+@author: luojunhui
+"""
+from datetime import datetime, timedelta
+from tqdm import tqdm
+
+from applications import WeixinSpider, PQMySQL
+
+
+db_client = PQMySQL()
+spider = WeixinSpider()
+
+
+def main():
+    """
+    入口函数
+    :return:
+    """
+    select_sql = f"""
+        SELECT accountName, ghId, ContentUrl
+        FROM official_articles_v2
+        WHERE publish_timestamp > ''
+    """