我收到消息"chromedriver.exe"可执行文件需要在 PATH 中



我试图让硒与goorm一起工作,但它不起作用。 我正在使用goorm IDE,这是一个云服务。

from selenium import webdriver
driver = webdriver.Chrome("C:Users/chromedriver.exe")

运行时,我收到以下消息: "chromedriver.exe"可执行文件需要位于 PATH 中。请参阅 https://sites.google.com/a/chromium.org/chromedri

检查以下内容:

driver = webdriver.Chrome("C:/Users/chromedriver.exe")

添加 chromedriver 的路径.exe在Path中,这是在Environmental Variable

如果您使用的是Windows

  1. 右键单击My Computer并转到Properties
  2. 选择Advanced system settings
  3. 转到选项卡Advanced
  4. 点击Environment Variables
  5. 在"System Variables"部分中搜索Path变量
  6. 双击它并在其value列表中添加chromedriver.exe的路径

相关内容

最新更新