I'm seeing a bizarre "untrusted cert" error only on selenium-controlled firefox pop-ups. Very specific. To solve this problem, various google results suggested turning off marionette, like so:
from selenium.webdriver.common.desired_capabilities import DesiredCapabilities
firefox_capabilities = DesiredCapabilities.FIREFOX
firefox_capabilities['marionette'] = False
driver = webdriver.Firefox()
And this works, but how?? How is geckodriver working at all with Marionette off?
From this other Stack Overflow answer:
Marionette is an automation driver for Mozilla's Gecko engine.
The answer goes on to explicitly say it should fail:
"In case of using the Firefox 53.x browsers if you forcefully set "marionette" to false through DesiredCapabilities class you will observe a UnreachableBrowserException."
So, how the heck is this working?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…