0

i use python 3.6.4 and install selenium with pip command

pip install -U selenium when i use a simple code like this

from selenium import webdriver

browser = webdriver.Firefox()
browser.get('http://seleniumhq.org/')

i get error:

from selenium.firefox.webdriver import WebDriver
ImportError: No module named 'selenium.firefox'

i download chromedriver.exe and add this path to system environment bot not working how can i fix this problem?

lord_viper
  • 1,139
  • 1
  • 9
  • 13
  • Are you sure you are actually using `from selenium import webdriver` and not `from selenium.firefox.webdriver import WebDriver`? – G_M Mar 15 '18 at 17:38
  • yes i sure,it only define from selenium import webdriver – lord_viper Mar 15 '18 at 17:48
  • I can't reproduce your error using `from selenium import webdriver` – G_M Mar 15 '18 at 17:50
  • If you downloaded `chromedriver.exe`, why aren't you using `browser = webdriver.Chrome()`? – G_M Mar 15 '18 at 17:50
  • Make sure that you are running and installing on the same version of python. Try `pip3 install selenium` or `python3 -m pip install selenium`. – Florent B. Mar 15 '18 at 18:31
  • i install 2 python 3.6.4 and 3.4.3 i think Interference environment reason of this error after delete all pythons and clean directory,registery,environment and install only python 3.4.3 this problem fixed – lord_viper Mar 16 '18 at 07:16

0 Answers0