Issue metadata
Sign in to add a comment
|
Browser Maximize is not working in Chrome Headless mode
Reported by
tanmoysa...@gmail.com,
Sep 18
|
||||||||||||||||||||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/69.0.3497.92 Safari/537.36 Steps to reproduce the problem: 1. used chrome option and set argument "--headless","--disable-gpu" and "--start-maximized" 2. launch the browser and get window size using selenium. 3. In headless mode getting size of <800, 600>. 4. Same code in headon mode getting full size <1616,876>. Chrome Version - 69.0.3497.92 chromedriver=70.0.3538.16 What is the expected behavior? In headless mode also browser should get fully maximized What went wrong? Log :- HEADLESS MODE Running TestSuite 11:56:11.244 [main] INFO io.github.bonigarcia.wdm.WebDriverManager - Reading https://chromedriver.storage.googleapis.com/ to seek chromedriver 11:56:12.256 [main] INFO io.github.bonigarcia.wdm.WebDriverManager - Latest version of chromedriver is 70.0.3538.16 11:56:12.266 [main] INFO io.github.bonigarcia.wdm.Downloader - Using binary driver previously downloaded 11:56:12.276 [main] INFO io.github.bonigarcia.wdm.WebDriverManager - Exporting webdriver.chrome.driver as C:\Users\Tanmoy\.m2\repository\webdriver\chromedriver\win32\70.0.3538.16\chromedriver.exe Starting ChromeDriver 70.0.3538.16 (16ed95b41bb05e565b11fb66ac33c660b721f778) on port 27507 Only local connections are allowed. Sep 18, 2018 11:56:15 AM org.openqa.selenium.remote.ProtocolHandshake createSession INFO: Detected dialect: OSS WARNING: An illegal reflective access operation has occurred WARNING: Illegal reflective access by org.assertj.core.internal.cglib.core.ReflectUtils$1 (file:/C:/Users/Tanmoy/.m2/repository/org/assertj/assertj-core/3.3.0/assertj-core-3.3.0.jar) to method java.la ng.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain) WARNING: Please consider reporting this to the maintainers of org.assertj.core.internal.cglib.core.ReflectUtils$1 WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations WARNING: All illegal access operations will be denied in a future release window size - (800, 600) Tests run: 10, Failures: 1, Errors: 0, Skipped: 9, Time elapsed: 11.241 sec <<< FAILURE! - in TestSuite navigateTologinModule(com.test.ui.admin.user.UserUITest) Time elapsed: 10.945 sec <<< FAILURE! org.openqa.selenium.ElementNotVisibleException: element not interactable (Session info: headless chrome=69.0.3497.92) (Driver info: chromedriver=70.0.3538.16 (16ed95b41bb05e565b11fb66ac33c660b721f778),platform=Windows NT 6.1.7601 SP1 x86_64) (WARNING: The server did not provide any stacktrace information) Command duration or timeout: 0 milliseconds Build info: version: '3.12.0', revision: '7c6e0b3', time: '2018-05-08T14:04:26.12Z' System info: host: 'PC', ip: '192.168.2.95', os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '9.0.1' Driver info: org.openqa.selenium.chrome.ChromeDriver Capabilities {acceptInsecureCerts: false, acceptSslCerts: false, applicationCacheEnabled: false, browserConnectionEnabled: false, browserName: chrome, chrome: {chromedriverVersion: 70.0.3538.16 (16ed9 5b41bb05..., userDataDir: C:\Users\Tanmoy\AppData\Loc...}, cssSelectorsEnabled: true, databaseEnabled: false, goog:chromeOptions: {debuggerAddress: localhost:51120}, handlesAlerts: true, hasTouchScree n: false, javascriptEnabled: true, locationContextEnabled: true, mobileEmulationEnabled: false, nativeEvents: true, networkConnectionEnabled: false, pageLoadStrategy: normal, platform: XP, platformNam e: XP, rotatable: false, setWindowRect: true, takesHeapSnapshot: true, takesScreenshot: true, unexpectedAlertBehaviour: , unhandledPromptBehavior: , version: 69.0.3497.92, webStorageEnabled: true} Session ID: c6b1becd64aa4ac3c49e237c073f6d4f Did this work before? Yes Chrome version: 69.0.3497.92 Channel: stable OS Version: 7 Flash Version:
,
Sep 19
Thanks for filing the issue! As per comment#0 steps to reproduce the problem it requires Selenium to test and confirm the issue, which is out of scope from TE end. Hence requesting someone from the Dev team for further investigation of the issue and adding TE-NeedsTriageHelp label to it. Note: Tentatively adding Tests>WebDriver component to it. Thanks!
,
Sep 19
By definition, maximize browser window sets the window size based on the screen size. However, a headless browser isn't attached to any screen, and can't query the screen for its size. So headless Chrome doesn't support maximizing window. Please set the window to a specific size instead. |
|||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||
Comment 1 by phanindra.mandapaka@chromium.org
, Sep 19