|
@@ -107,8 +107,8 @@ def re_get_webdriver():
|
|
|
|
|
|
def run_once(url):
|
|
|
global driver
|
|
|
- i=random.randint(0,13)
|
|
|
- if i<=3 or driver is None:
|
|
|
+ i=random.randint(0,15)
|
|
|
+ if i==0 or driver is None:
|
|
|
# if True:
|
|
|
re_get_webdriver()
|
|
|
time.sleep(3)
|
|
@@ -117,7 +117,7 @@ def run_once(url):
|
|
|
try:
|
|
|
driver.execute_script('window.open("'+url+'","_blank");')
|
|
|
driver.execute_script("window.scrollTo(0, window.scrollY + 400)")
|
|
|
- time.sleep(2)
|
|
|
+ time.sleep(0.2)
|
|
|
except:
|
|
|
print('exception')
|
|
|
|