selenium: [🐛 Bug]: Chrome driver fails to start with WebDriverException : no such execution context

What happened?

Starting chrome driver fails to start and gives the following error message Message:  OpenQA.Selenium.WebDriverException : no such execution context (Session info: chrome=118.0.5993.72)

Stack Trace:  WebDriver.UnpackAndThrowOnError(Response errorResponse, String commandToExecute) WebDriver.Execute(String driverCommandToExecute, Dictionary2 parameters) WebDriver.InternalExecute(String driverCommandToExecute, Dictionary2 parameters) Window.Maximize()

I am using Selenium v4.14.1 & 1118v chromedriver. With had this issue for a while now and its random can be when running 2 or 3 tests or a larger number.

How can we reproduce the issue?

ChromeOptions options = BrowserIsChrome();
ChromeDriver webDriver = new ChromeDriver(options);
                
webDriver.Manage().Window.Maximize();                
webDriver.Manage().Timeouts().PageLoad = _pageLoadTimeOut;
webDriver.Manage().Timeouts().AsynchronousJavaScript = _asynchronousJavaScriptTimeOut;
webDriver.Manage().Timeouts().ImplicitWait = _implicitWaitTimeOut;
return webDriver;

Relevant log output

Message: 
OpenQA.Selenium.WebDriverException : no such execution context
  (Session info: chrome=118.0.5993.72)

  Stack Trace: 
WebDriver.UnpackAndThrowOnError(Response errorResponse, String commandToExecute)
WebDriver.Execute(String driverCommandToExecute, Dictionary`2 parameters)
WebDriver.InternalExecute(String driverCommandToExecute, Dictionary`2 parameters)
Window.Maximize()

Operating System

Windows11

Selenium version

C# 4.14.1

What are the browser(s) and version(s) where you see this issue?

Chrome v118

What are the browser driver(s) and version(s) where you see this issue?

Chrome v118

Are you using Selenium Grid?

No

About this issue

  • Original URL
  • State: closed
  • Created 8 months ago
  • Comments: 20 (5 by maintainers)

Most upvoted comments

Hi, @cdutton1. This issue has been determined to require fixes in ChromeDriver.

You can see if the feature is passing in the Web Platform Tests.

If it is something new, please create an issue with the ChromeDriver team. Feel free to comment the issues that you raise back in this issue. Thank you.