balor83379
balor83379

Reputation: 1

Python Selenium - Does it close after crash?

I have quick question about selenium browser automation after it crashes on for example linux server does it close automatically after certain period of time? Cleaning memory?

Upvotes: 0

Views: 776

Answers (1)

undetected Selenium
undetected Selenium

Reputation: 193058

In case of a crash, there are two distinct objects involved, the WebDriver and the Web Browser. Considering the ChromeDriver and Google Chrome browser combination either of the following crash can happen:

  • The ChromeDriver crash.
  • The Chrome Browser crash.

ChromeDriver crash

In case of ChromeDriver crash in systems you may see an error message like this:

chromedriver_exe

After the crash, the zombie chromedriver process may still continue to occupy your system memory and resources. In those cases you have to kill the dangling instances of ChromeDriver with brute force.

You can find a relevant detailed discussion in Selenium : How to stop geckodriver process impacting PC memory, without calling driver.quit()?


Chrome Browser crash

In case of crashing just closing the crashed window may not be sufficient. You may require to kill the other associated processes as well with brute force.

You can find a relevant detailed discussion in Many process of Google Chrome (32 bit)

The behaviour with other WebDriver and Web Browser variants will be more or less similar.

Upvotes: 1

Related Questions