-
-
Notifications
You must be signed in to change notification settings - Fork 8.6k
Closed
Labels
C-pyPython BindingsPython BindingsD-chromeG-chromedriverRequires fixes in ChromeDriverRequires fixes in ChromeDriverI-defectSomething is not working as intendedSomething is not working as intendedOS-linux
Description
Description
Whenever we launch the browser we always maximize the browser using following code:
options.add_argument('--window-size=1920x1080')
However from 137.0.7151.55 version, I see it is ignoring the maximising window. If anyone knows the solution please assist us.
Here is the code we uses:
Note: It is keep on opening the browser with 800X461 size
Reproducible Code
from selenium.webdriver.chrome.options import Options
execution_path = "./drivers/chromedriver.exe"
self.log("execution_path chrome " + execution_path)
os.chmod(execution_path, 0o755)
os.environ["webdriver.chrome.driver"] = execution_path
os.environ["DBUS_SESSION_BUS_ADDRESS"] = "/dev/null"
options = wdriver.ChromeOptions()
options.add_argument('--no-sandbox')
options.add_argument('--ignore-certificate-errors')
options.add_argument('--ignore-ssl-errors')
options.add_argument('--disable-notifications')
options.add_argument('--headless')
options.add_argument('--disable-gpu')
options.add_argument('--disable-dev-shm-usage');
options.add_argument('--window-size=1920x1080');
#options.add_argument('--start-maximized')
self.log("Before initiating the chrome driver ")
try:
driver = wdriver.Chrome(chrome_options=options, executable_path=execution_path)
except Exception as e:
self.log("Inside Exception block")
ℹ️ Last known working version: 135.0.7049.42
Metadata
Metadata
Assignees
Labels
C-pyPython BindingsPython BindingsD-chromeG-chromedriverRequires fixes in ChromeDriverRequires fixes in ChromeDriverI-defectSomething is not working as intendedSomething is not working as intendedOS-linux