wangkun hace 2 años
padre
commit
7e0b24c639

+ 7 - 7
weixinzhishu/weixinzhishu_main/search_key_mac.py

@@ -24,6 +24,7 @@ class SearchKey:
         # 点击聊天按钮,展开聊天列表
         print("点击聊天按钮")
         chat_btn.Press()
+        time.sleep(1)
 
         # # 查找文件传输助手
         # print("查找文件传输助手")
@@ -34,13 +35,13 @@ class SearchKey:
         # chat_help.clickMouseButtonLeft(chat_help_position)
 
         print("查找微信指数小程序消息")
-        # chat_msg = window.findFirstR(AXIdentifier="MMNormalAppBrandMessageCellView", AXRole="AXUnknown")
-        chat_msg = window.findFirstR(AXValue="小程序", AXRole="AXStaticText")
-        print(f"微信指数小程序消息:{chat_msg}")
+        weixinzhishu = window.findFirstR(AXValue="微信指数", AXRole="AXStaticText")
+        print(f"微信指数小程序消息:{weixinzhishu}")
         print("点击微信指数小程序消息")
-        chat_msg_position = chat_msg.AXSize
-        print(chat_msg_position)
-        chat_msg.clickMouseButtonLeft(chat_msg_position)
+        weixinzhishu_position = weixinzhishu.AXSize
+        print(weixinzhishu_position)
+        # weixinzhishu.clickMouseButtonLeft(weixinzhishu_position)
+        # chat_msg.clickMouseButtonLeft((780, 450))
         # chat_msg_position.Press()
         time.sleep(3)
 
@@ -48,6 +49,5 @@ class SearchKey:
 
 
 
-
 if __name__ == "__main__":
     SearchKey.start_wechat()

+ 4 - 4
weixinzhishu/weixinzhishu_main/weixinzhishu_inner_long.py

@@ -108,10 +108,10 @@ class Test:
                 }
                 if response.json()['code'] == -10002:
                     Common.logger(log_type, crawler).info("该词暂未收录")
-                    # 写飞书
-                    if word_list[i]['word'] in [x for y in Feishu.get_values_batch(log_type, crawler, "JpgyAv") for x in y]:
-                        Common.logger(log_type, crawler).info("该词已存在")
-                        continue
+                    # # 写飞书
+                    # if word_list[i]['word'] in [x for y in Feishu.get_values_batch(log_type, crawler, "JpgyAv") for x in y]:
+                    #     Common.logger(log_type, crawler).info("该词已存在")
+                    #     continue
                     Feishu.insert_columns(log_type, crawler, "JpgyAv", "ROWS", 1, 2)
                     time.sleep(0.5)
                     Feishu.update_values(log_type, crawler, "JpgyAv", "F2:Z2",

+ 4 - 4
weixinzhishu/weixinzhishu_main/weixinzhishu_inner_sort.py

@@ -108,10 +108,10 @@ class Test:
                 }
                 if response.json()['code'] == -10002:
                     Common.logger(log_type, crawler).info("该词暂未收录")
-                    # 写飞书
-                    if word_list[i]['word'] in [x for y in Feishu.get_values_batch(log_type, crawler, "DrZHpa") for x in y]:
-                        Common.logger(log_type, crawler).info("该词已存在")
-                        continue
+                    # # 写飞书
+                    # if word_list[i]['word'] in [x for y in Feishu.get_values_batch(log_type, crawler, "DrZHpa") for x in y]:
+                    #     Common.logger(log_type, crawler).info("该词已存在")
+                    #     continue
                     Feishu.insert_columns(log_type, crawler, "DrZHpa", "ROWS", 1, 2)
                     time.sleep(0.5)
                     Feishu.update_values(log_type, crawler, "DrZHpa", "F2:Z2",

+ 4 - 4
weixinzhishu/weixinzhishu_main/weixinzhishu_out.py

@@ -109,9 +109,9 @@ class Test:
                 if response.json()['code'] == -10002:
                     Common.logger(log_type, crawler).info("该词暂未收录")
                     # 写飞书
-                    if word_list[i]['word'] in [x for y in Feishu.get_values_batch(log_type, crawler, "YVuVgQ") for x in y]:
-                        Common.logger(log_type, crawler).info("该词已存在")
-                        continue
+                    # if word_list[i]['word'] in [x for y in Feishu.get_values_batch(log_type, crawler, "YVuVgQ") for x in y]:
+                    #     Common.logger(log_type, crawler).info("该词已存在")
+                    #     continue
                     Feishu.insert_columns(log_type, crawler, "YVuVgQ", "ROWS", 1, 2)
                     time.sleep(0.5)
                     Feishu.update_values(log_type, crawler, "YVuVgQ", "F2:Z2",
@@ -147,5 +147,5 @@ class Test:
 
 if __name__ == "__main__":
     # print(Test.get_words("test", "weixinzhishu"))
-    Test.get_score_test("out-1", "weixinzhishu")
+    Test.get_score_test("out", "weixinzhishu")
     pass