Commit 1f266c65 authored by Yaowentong's avatar Yaowentong

美团截图修复

parent e904aeee
...@@ -1073,39 +1073,9 @@ def webhook_snipaste(promp_list): ...@@ -1073,39 +1073,9 @@ def webhook_snipaste(promp_list):
if __name__ == "__main__": if __name__ == "__main__":
# t1 = threading.Thread(target=scheduler_thread, daemon=True) t1 = threading.Thread(target=scheduler_thread, daemon=True)
# t2 = threading.Thread(target=runner_thread, daemon=True) t2 = threading.Thread(target=runner_thread, daemon=True)
# t1.start() t1.start()
# t2.start() t2.start()
# t1.join() t1.join()
# t2.join() t2.join()
pt = 20260630
cn =1
result = bh_utils.query_data(f"select * from geo_third_task_log where cn = {cn} and pt = {pt}") or []
for i in result:
req_id = i.get("reqId")
if not req_id:
continue
file = f"geo_snipaste/{pt}/doubao/{req_id}/text.json"
try:
raw = tos_utils.get_string_from_tos(file)
if not raw:
continue
content = json.loads(raw).get("content")
if content:
doubao_process_original_data(file, content)
except Exception as e:
logger.success(f"[pt={pt} cn={cn}] 处理 {file} 失败: {e}")
# 2) 导出 Excel
out_path = to_excel2(pt, cn)
# 3) 上传 + 发飞书
file_name = os.path.basename(out_path)
file_key = upload_file(out_path, file_name)
if file_key:
chat_message(file_key)
logger.success(f"[pt={pt} cn={cn}] 已发送飞书文件: {file_name}")
else:
logger.success(f"[pt={pt} cn={cn}] 上传失败,未发送飞书消息")
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment