浏览代码

gzh抓取优化

luojunhui 3 周之前
父节点
当前提交
727fb66507
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      applications/tasks/crawler_tasks/crawler_gzh.py

+ 2 - 2
applications/tasks/crawler_tasks/crawler_gzh.py

@@ -258,7 +258,7 @@ class CrawlerGzhAccountArticles(CrawlerGzhBaseStrategy):
     async def deal(self, method: str, strategy: str = "V1"):
         account_list = await self.get_crawler_accounts(method, strategy)
         for account in tqdm(account_list, desc="抓取单个账号"):
-            print(f"{datetime.now()}: start crawling account: {json.dumps(account, ensure_ascii=False)}")
+            print(f"{datetime.now()}: start crawling account: {account}")
             try:
                 await self.crawler_single_account(method, account)
                 await self.update_account_read_avg_info(
@@ -277,7 +277,7 @@ class CrawlerGzhAccountArticles(CrawlerGzhBaseStrategy):
                         },
                     }
                 )
-            print(f"{datetime.now()}: finish crawled account: {json.dumps(account, ensure_ascii=False)}")
+            print(f"{datetime.now()}: finish crawled account: {account}")
 
 
 class CrawlerGzhSearchArticles(CrawlerGzhBaseStrategy):