繁体   English   中英

如何在ubuntu上为python3硒安装firefoxdriver webdriver?

[英]How to install firefoxdriver webdriver for python3 selenium on ubuntu?

我在Ubuntu 16.04上安装了python3-selenium apt软件包。 在安装时,收到一条消息:

Suggested packages:
  chromedriver firefoxdriver
The following NEW packages will be installed:
  python3-selenium

当我尝试在python3-django中运行测试用例时,出现以下错误:

FileNotFoundError: [Errno 2] No such file or directory: '/usr/lib/firefoxdriver/webdriver.xpi'

我确实在Ubuntu存储库中搜索名称为firefoxdriver的软件包,但不存在。

感谢您对安装网络驱动程序的任何帮助。

我不确定在安装python3-selenium软件包后如何安装Firefox Webdriver。

您可以改为使用pip进行安装,最好在虚拟环境中进行安装。

如果您已经安装了Firefox,并且在虚拟环境中运行了pip install selenium ,那么您应该一切顺利。

暂无
暂无

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM