|
@@ -47,7 +47,7 @@ def re_get_webdriver():
|
|
|
|
|
|
options.add_argument("--no-sandbox")
|
|
|
options.add_argument("--disable-dev-shm-usage")
|
|
|
-# options.add_argument("--headless")
|
|
|
+ options.add_argument("--headless")
|
|
|
|
|
|
# print(user_agent)
|
|
|
# options.add_argument("--user-agent=" +user_agent)
|
|
@@ -91,8 +91,9 @@ def run_once(url):
|
|
|
# driver.execute_script("window.scrollTo(0, window.scrollY + 400)")
|
|
|
# time.sleep(0.5)
|
|
|
except:
|
|
|
+ traceback.print_exc()
|
|
|
print('exception')
|
|
|
- time.sleep(9999)
|
|
|
+# time.sleep(9999)
|
|
|
|
|
|
|
|
|
lst=[]
|
|
@@ -104,6 +105,8 @@ lst=[]
|
|
|
while True:
|
|
|
l='https://cmm.ai/meta'
|
|
|
print(l)
|
|
|
- run_once(l)
|
|
|
- time.sleep(2)
|
|
|
-
|
|
|
+ try:
|
|
|
+ run_once(l)
|
|
|
+ time.sleep(2)
|
|
|
+ except:
|
|
|
+ traceback.print_exc()
|