求大神,selenium打開生意參謀時查找元素的代碼出錯導致無法填寫用戶名,何解?


代碼:
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver import Chrome
from selenium.webdriver import ChromeOptions
option = ChromeOptions()
option.add_experimental_option('excludeSwitches', ['enable-automation'])
browser = Chrome(options=option)
wait = WebDriverWait(browser, 10)
browser.get('https://sycm.taobao.com/portal/home.htm')
input=wait.until(EC.presence_of_all_elements_located((By.CSS_SELECTOR, '#fm-login-id')))
input[0].send_keys('123')
轉載請註明出處,本文鏈接:https://www.uj5u.com/qita/38511.html
上一篇:Python爬蟲怎么爬取騰訊位置大資料里邊熱力圖的熱點資料,還有就是我找到一些資料 ,但是看不懂,有沒有大神幫我看看,感激不盡
