puppeteer-sharp icon indicating copy to clipboard operation
puppeteer-sharp copied to clipboard

Running Launcher.LaunchAsync() with LaunchOptions Browser = SupportedBrowser.ChromeHeadlessShell crashes

Open mrawohl opened this issue 2 months ago • 0 comments

Tried with nuget package version 20.2.2. using NET8.0 platform.

When trying to run await Launcher.LaunchAsync(new LaunchOptions() { Browser = SupportedBrowser.ChromeHeadlessShell }; the call is crashing with an inner ArgumentException with message: "Invalid browser". The cause can easily be tracked within Launcher.cs in line 72 as a default result of a switch-case statement, which is checking for the LaunchOptions.Browser property. Seems like, the case SupportedBrowser.ChromeHeadlessShell has been forgotten as it is implemented in the previous switch-case statement in line 61.

mrawohl avatar Oct 07 '25 08:10 mrawohl