--headless2
to activate Chromium's new headless mode
- Integrate Chromium's new headless mode into SeleniumBase
--> This resolves #1523 - Improve
get_unique_links()
for special scenarios
--> This resolves #1524 - Refresh Python dependencies
--> 8c3c237
Integrate Chromium's new headless mode into SeleniumBase
The Chromium developers recently added a 2nd headless mode (in 2021). See https://bugs.chromium.org/p/chromium/issues/detail?id=706008#c36
Usage (from instantiating Chromium options):
options.add_argument("--headless=chrome")
This new headless mode allows users to get the full functionality of Chrome without limitations. The older, regular headless mode has restricted functionality, did not allow extensions, changed the User-Agent to say HeadlessChrome
, and did other things that may have caused problems during automation.
If something works in regular Chrome, it should now work with the newer headless mode too. The only downside is that the new headless mode is slower than the regular headless mode.
To use the new headless mode for SeleniumBase tests, specify: --headless2
:
pytest --headless2