我的python腳本按預期運行,然後我需要添加PIL軟件包,並安裝了Pyscreenshot,PIL和Pillow進行圖像處理。安裝枕頭後無法導入selenium webdriver
安裝這些軟件包後,導入selenium語句變灰,我不能再導入硒。
我卸載了圖像處理的包來恢復設置,但沒有運氣
from selenium import webdriver
from selenium.common.exceptions import NoSuchElementException
from selenium.webdriver.support.ui import WebDriverWait
from selenium.common.exceptions import TimeoutException
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.common.by import By
#import pyscreenshot as ImageGrab
#from PIL import Image
BaseUrl = "http://google.com"
browser.get(BaseUrl)
browser.implicitly_wait(10)
注:我有硒和安裝gckodriver和路徑也增加了。
任何幫助將不勝感激。提前致謝。
什麼樣的錯誤你得到 –