Reputation: 601
I have downloaded selenium to my Mac. I am trying to run a script in python using selenium but I am getting the error:
Traceback (most recent call last):
File "selenium.py", line 3, in <module>
from selenium import webdrive
File "/Users/shynds23/python/selenium.py", line 3, in <module>
from selenium import webdriver
ImportError: cannot import name webdriver
My script has these headers:
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
from selenium.common.exceptions import NoSuchElementException
import time
Any ideas on how to fix it?
Upvotes: 4
Views: 105
Reputation: 71451
Try downloading selenium using pip instead:
pip install selenium
If pip is not installed on your machine, run:
python get-pip.py
Here is the link for get-pip:
https://bootstrap.pypa.io/get-pip.py
Upvotes: 1