update: fixed time estimation

This commit is contained in:
2025-07-24 11:51:05 +08:00
parent c48f50cfb5
commit 9aced634fa

View File

@@ -217,13 +217,14 @@ def main():
return 5
rate = 60 / (args.interval + 3)
length = list.count(sents, None)
command = None
timezone = ZoneInfo(args.timezone)
print(f'[信息] 当前发送速率 {round(rate, 2)} 封/分钟')
print(f'[信息] 预计使用时间 {timedelta(minutes=limit / rate)}')
if rate > 8.33: print('[警告] 当前发送速率已超出限制 8.33 封/分钟')
print(f'[信息] 计划发送 {length}')
print(f'[信息] 预计使用时间 {timedelta(minutes=length / rate)}')
print(f'[信息] 当前时区:{args.timezone}')
print(f'[信息] 已读取可用问候语 {len(greetings)} 条:', end='\n\n')
@@ -283,7 +284,7 @@ def main():
try:
clean = True
attempt += 1
print(f'[信息] 正在发送:{recipient}')
print('[信息] 正在发送:%s (%.2f %%)' % (recipient, current / limit))
click("button[aria-label='Edit copy']")
ready(driver, lambda x: x.find_element(By.CSS_SELECTOR, ".io-ox-busy"))