简体   繁体   English

Selenium WebDriverException:消息:“ chromedriver.exe”可执行文件必须位于PATH中

[英]Selenium WebDriverException: Message: 'chromedriver.exe' executable needs to be in PATH

I realize this is a duplicate, but I've tried all the suggestions made by the other similar posts on this error. 我意识到这是重复的,但是我已经尝试过其他类似帖子针对此错误提出的所有建议。 I'm running Windows 10. 我正在运行Windows 10。

Per this post, they suggest to explicitly state the folder location in my python code. 在这篇文章中,他们建议在我的python代码中明确说明文件夹位置。 I've done that. 我已经做到了。 Error message: "'chromedriver' executable needs to be available in the path" 错误消息:“'chromedriver'可执行文件在路径中必须可用”

Per another post, they say to make sure the environment variable, PATH is pointed correctly. 在另一篇文章中,他们说要确保正确指向环境变量PATH。 Error message: "'chromedriver' executable needs to be available in the path" 错误消息:“'chromedriver'可执行文件在路径中必须可用”

Here are the different ways I tried entering the code: 这是我尝试输入代码的不同方法:

driver = webdriver.Chrome(executable_path='/Users/Admin/Documents/Python/chromedriver.exe'‌)  #SyntaxError: invalid character in identifier

and

driver = webdriver.Chrome('/Users/Admin/Documents/Python/chromedriver.exe')

Here are screenshots: 这是屏幕截图: 在此处输入图片说明

and another: 另一个: 在此处输入图片说明

also added chromesetup.exe to the C:\\Python36-32\\Scripts folder and calling 还将chromesetup.exe添加到C:\\ Python36-32 \\ Scripts文件夹并调用

driver= webdriver.Chrome()

在此处输入图片说明

I have also restarted my computer and restarted Pycharm. 我还重新启动了计算机并重新启动了Pycharm。 Any other suggestions? 还有其他建议吗?

driver = webdriver.Chrome(executable_path = os.path.abspath(“ ChromeSetup”),options = chrome_options)

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 为 Windows - selenium.common.exceptions.WebDriverException 安装 Chromedriver:消息:“chromedriver.exe”可执行文件需要在 PATH 中 - Installing Chromedriver for Windows - selenium.common.exceptions.WebDriverException: Message: 'chromedriver.exe' executable needs to be in PATH Selenium WebDriverException 'chromedriver.exe' 需要在 PATH 中 - Selenium WebDriverException 'chromedriver.exe' needs to be in PATH 我收到消息“chromedriver.exe”可执行文件需要在 PATH 中 - i got message 'chromedriver.exe' executable needs to be in PATH 如何修复 Selenium 错误(Python) - 消息:“chromedriver.exe”可执行文件需要在 PATH 中 - How to fix Selenium Error (Python) - Message: 'chromedriver.exe' executable needs to be in PATH WebDriverException:WebDriverException:消息:“chromedriver”可执行文件需要在 PATH 中 - WebDriverException: WebDriverException: Message: 'chromedriver' executable needs to be in PATH selenium.common.exceptions.WebDriverException:消息:“chromedriver”可执行文件需要在 PATH 中 - selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to be in PATH WebDriverException:消息:“chromedriver.exe”可执行文件需要在 PATH 中。 请参阅 https://sites.google.com/a/chromium.org/chromedriver/home - WebDriverException: Message: 'chromedriver.exe' executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home WebDriverException:消息:“chromedriver.exe”可执行文件可能通过 Selenium Python 使用 Google Colaboratory 具有错误权限 - WebDriverException: Message: 'chromedriver.exe' executable may have wrong permissions using Google Colaboratory through Selenium Python WebDriverException:消息:“ ChromeDriver可执行文件需要在路径中可用 - WebDriverException: Message: 'ChromeDriver executable needs to be available in the path 如何修复“chromedriver.exe”可执行文件需要在 Github Actions 的 PATH 中? - How to fix 'chromedriver.exe' executable needs to be in PATH` in Github Actions?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM