Skip to content

Commit

Permalink
Switch to new chrome headless mode
Browse files Browse the repository at this point in the history
Since version 112 chrome has a new headless mode [1]. By trial we found
the old mode causes low and unchangeable window size on MacOS, which made
some elements not clickable by Selenium. In new mode all elements were
clickable. This change lets all e2e tests run in new mode.

Chrome developers say regarding the new mode

> We intend to remove the old Headless from the Chrome binary and stop
> supporting this mode in Puppeteer in 2024.

seleniumbase --headless means old mode chrome --headless=chrome [2]
seleniumbase --headless2 means new mode chrome --headless=new [3]

[1] https://developer.chrome.com/docs/chromium/new-headless
[2] https://github.com/seleniumbase/SeleniumBase/blob/283c3db0228e30def2ca4f710d2d312a2bdae419/seleniumbase/core/browser_launcher.py#L1631
[3] https://github.com/seleniumbase/SeleniumBase/blob/283c3db0228e30def2ca4f710d2d312a2bdae419/seleniumbase/core/browser_launcher.py#L3278
  • Loading branch information
haxtibal committed Aug 7, 2024
1 parent f4c2766 commit a2dadf2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ def test_end2end(

focus_argument = f"-k {focus}" if focus is not None else ""
exit_first_argument = "--exitfirst" if exit_first else ""
headless_argument = "--headless" if headless else ""
headless_argument = "--headless2" if headless else ""

test_command = f"""
pytest
Expand Down

0 comments on commit a2dadf2

Please sign in to comment.