python - The system cannot find the path specified - FirefoxDriver.exe -


i doing sample selenium code python 3.5 opening link https://www.python.org/ when executing py showed followingf error.. firefoxdriver.exe exists in given path.. , i've added path in environmental variables too.. still error exists.. can me out of this..

my py sample.py :

from selenium import webdriver selenium.webdriver.common.keys import keys  browser = webdriver.firefox('c:\\pythonselenium\\firefoxdriver.exe') browser.get(parameters['https://www.python.org/']) 

==================== restart: c:/pythonselenium/sample.py ==================== traceback (most recent call last):

file "c:/pythonselenium/sample.py", line 4, in <module>     driver = webdriver.firefox('c:\\pythonselenium\\firefoxdriver.exe')   file "c:\python36\lib\site-packages\selenium\webdriver\firefox\webdriver.py", line 134, in __init__     firefox_profile = firefoxprofile(firefox_profile)   file "c:\python36\lib\site-packages\selenium\webdriver\firefox\firefox_profile.py", line 78, in __init__     ignore=shutil.ignore_patterns("parent.lock", "lock", ".parentlock"))   file "c:\python36\lib\shutil.py", line 303, in copytree     names = os.listdir(src) filenotfounderror: [winerror 3] system cannot find path specified: 'c:\\pythonselenium\\firefoxdriver.exe' 

if have driver in path, should able use without providing arguments this:

browser = webdriver.firefox() 

you should restart system after you've changed environmental variables on windows changes take effect.


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -