我正在尝试执行 Java selenium 测试。
预期结果:浏览器 session 启动并执行测试步骤。
当前行为:浏览器 session 未启动,并出现错误:
org.openqa.selenium.SessionNotCreatedException: Could not start a new session. Response code 500. Message: session not created: This version of ChromeDriver only supports Chrome version 114
Current browser version is 117.0.5938.89 with binary path C:\Program Files (x86)\Google\Chrome\Application\chrome.exe
chrome 从 116 版本更新到 117 版本后,我收到以下错误:
org.openqa.selenium.SessionNotCreatedException: Could not start a new session. Response code 500. Message: session not created: This version of ChromeDriver only supports Chrome version 114
Current browser version is 117.0.5938.89 with binary path C:\Program Files (x86)\Google\Chrome\Application\chrome.exe
在我的 pom.xml 文件中,我有:
webdriver-manager 5.5.3
selenium-java 4.12.1
最佳答案
为了解决这个问题,我使用了这个链接 (Chrome for Testing availability)并根据我的操作系统检查了chromedriver。 不要忘记确认并在必要时调整 chromedriver 的环境变量。
Chrome > 版本 117.0.5938.132 Chrome 驱动程序 > Download Link
希望对您有所帮助。
关于java - 此版本的ChromeDriver仅支持Chrome版本114当前浏览器版本为117.0.5938.89,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/77148932/