在Selenium for Python w/Windows 10中打开Firefox
我正试图按照本教程进行操作 这让我编写了以下代码,以使用Selenium打开firefox浏览器:在Selenium for Python w/Windows 10中打开Firefox,python,firefox,selenium,windows-10,Python,Firefox,Selenium,Windows 10,我正试图按照本教程进行操作 这让我编写了以下代码,以使用Selenium打开firefox浏览器: from selenium import webdriver browser = webdriver.Firefox() browser.get('http://localhost:8000') assert 'Django' in browser.title 但是,firefox会打开一个恼人的Windows10“欢迎”页面,并且从不访问我指定的url。如何解决这个问题?Firefox
from selenium import webdriver
browser = webdriver.Firefox()
browser.get('http://localhost:8000')
assert 'Django' in browser.title
但是,firefox会打开一个恼人的Windows10“欢迎”页面,并且从不访问我指定的url。如何解决这个问题?Firefox 43和selenium 2.47存在兼容性问题 将selenium升级至最新(目前为2.48)版本:
开发服务器目前正在运行吗?您使用的是哪种selenium和firefox版本?另外,控制台上有错误吗?@alecxe firefox v 43.0.3,selenium v 2.47.1Ok,快速猜测,升级selenium并重试:
pip安装——升级selenium
。
pip install --upgrade selenium