-1
I need a little help here! I need to set up selenium
using the webdrive to click on a Chrome pop-up window. I’ve tried several alternatives I found, but none of them work. A company security policy restricts some settings, but the automatic download is possible, but the automatic download runs only after clicking Allow (Allow). Chrome asks "Store files on this device" with Allow or Lock options. As per image.
That was the code used:
from selenium import webdriver
from selenium.webdriver.chrome.options import Options
import time
option = Options()
option.add_argument("--disable-infobars")
option.add_argument("start-maximized")
option.add_argument('--ignore-certificate-errors')
option.add_argument("--disable-extensions")
option.add_argument('--disable-download-notification')
option.add_experimental_option("useAutomationExtension", False)
option.add_experimental_option("prefs", {
"safebrowsing.enabled": True,
"profile.default_content_setting_values.notifications": 1,
"profile.default_content_setting_values.geolocation": 1})
wd = webdriver.Chrome(chrome_options=option, executable_path='C:\\Users\\Documents\\webdriver\\chromedriver.exe')
wd.get('http://websiteintranet.com.br')
it worked, it was just that!!! Thank you
– Rafael R