Unable to obtain driver using Selenium Manager: Selenium Manager failed for: E:\excavate\other\lib\site-packages\selenium\webdriver\common\windows\selenium-manager.exe --browser firefox --output json. error sending request for url (https://github.com/mozilla/geckodriver/releases/latest): connection error: connection reset Traceback (most recent call last): File "E:\Two\pythonProject\main.py", line 3, in <module> driver = webdriver.Firefox() File "E:\excavate\other\lib\site-packages\selenium\webdriver\firefox\webdriver.py", line 195, in __init__ self.service.path = DriverFinder.get_path(self.service, options) File "E:\excavate\other\lib\site-packages\selenium\webdriver\common\driver_finder.py", line 43, in get_path raise err File "E:\excavate\other\lib\site-packages\selenium\webdriver\common\driver_finder.py", line 40, in get_path path = shutil.which(service.path) or SeleniumManager().driver_location(options) File "E:\excavate\other\lib\site-packages\selenium\webdriver\common\selenium_manager.py", line 91, in driver_location result = self.run(args) File "E:\excavate\other\lib\site-packages\selenium\webdriver\common\selenium_manager.py", line 112, in run raise SeleniumManagerException(f"Selenium Manager failed for: {command}.\n{result}{stderr}") selenium.common.exceptions.SeleniumManagerException: Message: Selenium Manager failed for: E:\excavate\other\lib\site-packages\selenium\webdriver\common\windows\selenium-manager.exe --browser firefox --output json. error sending request for url (https://github.com/mozilla/geckodriver/releases/latest): connection error: connection reset Process finished with exit code 1
时间: 2023-08-25 07:05:13 浏览: 4279
这个错误通常发生在Selenium无法从GitHub下载驱动程序时。这可能是由于网络连接问题或GitHub服务器问题引起的。
你可以尝试手动下载geckodriver并将其添加到系统PATH环境变量中。请根据你的操作系统和Firefox浏览器版本下载相应的geckodriver版本。下载地址是:https://github.com/mozilla/geckodriver/releases
如果手动下载并配置geckodriver仍然无法解决问题,你可以尝试使用Firefox的ESR(Extended Support Release)版本,这个版本不需要每个版本都使用新的geckodriver驱动程序。你可以在这里下载Firefox ESR:https://www.mozilla.org/en-US/firefox/organizations/all/
如果问题仍然存在,请提供更多的代码和错误信息,以便更好地诊断问题。
相关问题
python报错Unable to obtain driver using Selenium Manager: Selenium Manager failed for
This error message suggests that there is an issue with the Selenium Manager in Python. It may indicate that the driver required for Selenium is not installed or configured correctly. Here are some possible solutions:
1. Make sure you have installed the appropriate driver for your browser. For example, if you are using Chrome, you need to download the ChromeDriver executable and add it to your system path.
2. Check that you have the correct version of Selenium installed. You can use pip to install the latest version by running "pip install selenium".
3. Verify that your code is correctly specifying the location of the driver. For example, if you are using ChromeDriver, you may need to set the executable path using "webdriver.Chrome(executable_path='/path/to/chromedriver')".
If none of these solutions work, please provide more details about your code and environment so that I can help you better.
Unable to obtain working Selenium Manager binary; F:\anaconda\lib\site-packages\selenium\webdriver\common\windows\selenium-manager.exe
这个错误提示是由于无法获取到可用的Selenium Manager二进制文件导致的。具体来说,它指的是在路径F:\anaconda\lib\site-packages\selenium\webdriver\common\windows\selenium-manager.exe下找不到可用的二进制文件。
解决这个问题的方法之一是确保你已经正确安装了Selenium,并且版本与你的Python环境兼容。你可以通过运行以下命令来安装Selenium:
```
pip install selenium
```
另外,你还需要下载并安装正确版本的浏览器驱动程序,例如ChromeDriver(用于Chrome浏览器)、geckodriver(用于Firefox浏览器)等。根据你的实际情况,你可能需要将这些驱动程序的路径添加到系统的环境变量中。
此外,你也可以尝试更新你当前使用的Selenium版本,有时候旧版本的Selenium可能不兼容最新的浏览器版本。
总之,要解决这个问题,你需要确保正确安装了Selenium和相关浏览器驱动程序,并且它们的版本兼容。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* *3* [ecw2c理解元数据:使用BigQuery k-means将4,000个堆栈溢出标签聚类](https://blog.csdn.net/cunehu1722/article/details/104928781)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
- *2* [golang 开源项目全集](https://blog.csdn.net/yangyangye/article/details/73558218)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文