Chrome in headless mode produces a blank white window equal to the size of the browser.
var dS = ChromeDriverService.CreateDefaultService();
dS.HideCommandPromptWindow = true;
var co = new ChromeOptions();
co.AddArgument("headless");
var bd= new ChromeDriver(dS, co);
bd.Url = "https://amazon.com";
Looks like this is a bug in Chrome Browser 129
, which was released on September 17th, 2024.
https://developer.chrome.com/docs/chromedriver/
Found related issues on github.
https://github.com/SeleniumHQ/selenium/issues/14514
Solution 1. work with Chrome 128.
Solution 2. hide the window by:
var co = new ChromeOptions();
co.AddArgument("--window-position=-10000,-10000")
Solution 3.
options.AddArgument("--headless=old")