【发布时间】:2020-09-18 23:56:39
【问题描述】:
我想避免机器人检测并且我的随机东西不起作用。实际上,它根本不是不喜欢的。 Xpaths 没问题。我在这里做错了什么?
def auto_swipe(self):
while True:
sleep_time = random.randrange(1, 3)
time.sleep(sleep_time)
try:
rand1 = random.randrange(0,100)
if rand1 < random.randrange(70,80):
self.like()
else:
self.dislike()
except Exception:
try:
self.close_popup()
except Exception:
self.close_match()
【问题讨论】:
-
这听起来像X-Y problem。与其寻求解决问题的帮助,不如编辑您的问题并询问实际问题。你想做什么?
标签: python python-2.7 selenium