Skip to main content
AI Assist is now on Stack Overflow. Start a chat to get instant answers from across the network. Sign up to save and share your chats.
Updated answer
Source Link
undetected Selenium
  • 194.5k
  • 44
  • 304
  • 387

As you are using Selenium 3.8.0Selenium 3.8.0 you have to use GeckoDriver mandatorilyGeckoDriver as a mandatory. But again as you are using Firefox v46.0Firefox v46.0 you have to set the capability marionettemarionette toas FalseFalse through DesiredCapabilities()DesiredCapabilities() as follows :

from selenium import webdriver from selenium.webdriver.common.desired_capabilities import DesiredCapabilities cap = DesiredCapabilities().FIREFOX cap["marionette"] = False browser = webdriver.Firefox(capabilities=cap, executable_path="C:\\path\\to\\geckodriver.exe") browser.get('http://google.com/') browser.quit() 

As you are using Selenium 3.8.0 you have to use GeckoDriver mandatorily. But again as you are using Firefox v46.0 you have to set the capability marionette to False through DesiredCapabilities() as follows :

from selenium import webdriver from selenium.webdriver.common.desired_capabilities import DesiredCapabilities cap = DesiredCapabilities().FIREFOX cap["marionette"] = False browser = webdriver.Firefox(capabilities=cap, executable_path="C:\\path\\to\\geckodriver.exe") browser.get('http://google.com/') browser.quit() 

As you are using Selenium 3.8.0 you have to use GeckoDriver as a mandatory. But again as you are using Firefox v46.0 you have to set the capability marionette as False through DesiredCapabilities() as follows :

from selenium import webdriver from selenium.webdriver.common.desired_capabilities import DesiredCapabilities cap = DesiredCapabilities().FIREFOX cap["marionette"] = False browser = webdriver.Firefox(capabilities=cap, executable_path="C:\\path\\to\\geckodriver.exe") browser.get('http://google.com/') browser.quit() 
Source Link
undetected Selenium
  • 194.5k
  • 44
  • 304
  • 387

As you are using Selenium 3.8.0 you have to use GeckoDriver mandatorily. But again as you are using Firefox v46.0 you have to set the capability marionette to False through DesiredCapabilities() as follows :

from selenium import webdriver from selenium.webdriver.common.desired_capabilities import DesiredCapabilities cap = DesiredCapabilities().FIREFOX cap["marionette"] = False browser = webdriver.Firefox(capabilities=cap, executable_path="C:\\path\\to\\geckodriver.exe") browser.get('http://google.com/') browser.quit()