| | |
| | | import sys |
| | | import os |
| | | import asyncio |
| | | import aiohttp |
| | | import traceback |
| | | import time |
| | | from Util.random_util import RandomUtil # 保证该模块中提供了生成随机数字和随机日期的函数 |
| | | from Util.dingtalk_helper import DingTalkHelper |
| | | from tqdm import tqdm # 导入进度条库 |
| | | import time |
| | | |
| | | def get_parent_directory(file_path, levels=1): |
| | | """获取指定层级的父目录""" |
| | | path = os.path.abspath(file_path) |
| | | for _ in range(levels): |
| | | path = os.path.dirname(path) |
| | | return path |
| | | parent_dir = get_parent_directory(__file__, 5) # 获取上五级目录 |
| | | sys.path.append(parent_dir) |
| | | |
| | | from 测试组.脚本.造数脚本2.Util.random_util import RandomUtil |
| | | from 测试组.脚本.造数脚本2.Util.dingtalk_helper import DingTalkHelper |
| | | |
| | | |
| | | # 钉钉机器人 access_token 和 secret |
| | | ACCESS_TOKEN = '4625f6690acd9347fae5b3a05af598be63e73d604b933a9b3902425b8f136d4d' |