You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

使用Python Selenium 4.13仍提示"Chrome版本不支持"求助

解决Selenium 4.13自带Manager仍提示Chrome版本不兼容问题
  • 先检查代码写法:别手动指定旧版chromedriver路径!如果之前写了webdriver.Chrome(executable_path='xxx')这种代码,删掉executable_path参数,让Selenium Manager自动匹配驱动。正确代码示例:

    from selenium import webdriver
    
    driver = webdriver.Chrome()
    
  • 清理Selenium Manager缓存:缓存的旧驱动可能导致匹配失败,手动删除缓存目录后重启代码:

    • Windows:删除%USERPROFILE%\.cache\selenium下所有内容
    • macOS/Linux:删除~/.cache/selenium下所有内容
  • 确保Chrome是最新版:打开Chrome→右上角三点→帮助→关于Google Chrome,完成更新后重启浏览器再运行代码。

  • 验证Selenium版本:终端执行pip show selenium确认版本是4.13.0,不是的话用pip install --upgrade selenium==4.13.0重新安装。

内容的提问来源于stack exchange,提问作者JimmyG

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.07.09 16:52:08