mirror of
https://github.com/LibraHp/GetQzonehistory.git
synced 2024-12-27 22:49:09 +00:00
commit
4fbd32089d
5
main.py
5
main.py
@ -17,6 +17,7 @@ import traceback
|
|||||||
import dateparser
|
import dateparser
|
||||||
import hashlib
|
import hashlib
|
||||||
import copy
|
import copy
|
||||||
|
import random
|
||||||
# 程序版本
|
# 程序版本
|
||||||
version = "1.0.2"
|
version = "1.0.2"
|
||||||
|
|
||||||
@ -1105,7 +1106,7 @@ def main(page: ft.Page):
|
|||||||
if is_stop:
|
if is_stop:
|
||||||
return 0
|
return 0
|
||||||
response = get_message(total, 10)
|
response = get_message(total, 10)
|
||||||
time.sleep(1)
|
time.sleep(random.uniform(5, 10))
|
||||||
if "img" in response.text:
|
if "img" in response.text:
|
||||||
# 请求成功,总量应该在当前总量的右侧
|
# 请求成功,总量应该在当前总量的右侧
|
||||||
lower_bound = total + 1
|
lower_bound = total + 1
|
||||||
@ -1150,7 +1151,7 @@ def main(page: ft.Page):
|
|||||||
break
|
break
|
||||||
try:
|
try:
|
||||||
# 获取消息并解码
|
# 获取消息并解码
|
||||||
time.sleep(1)
|
time.sleep(random.uniform(5, 10))
|
||||||
message_content = get_message(i * 100, 100).text
|
message_content = get_message(i * 100, 100).text
|
||||||
message = message_content if message_content else None
|
message = message_content if message_content else None
|
||||||
if not message:
|
if not message:
|
||||||
|
Loading…
Reference in New Issue
Block a user