MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / quit

Method quit

py/selenium/webdriver/common/webdriver.py:33–42  ·  view source on GitHub ↗

Closes the browser and shuts down the driver executable.

(self)

Source from the content-addressed store, hash-verified

31 return object.__new__(cls)
32
33 def quit(self) -> None:
34 """Closes the browser and shuts down the driver executable."""
35 try:
36 super().quit()
37 except Exception:
38 # We don't care about the message because something probably has gone wrong
39 pass
40 finally:
41 if hasattr(self, "service") and self.service is not None:
42 self.service.stop()
43
44 def download_file(self, *args, **kwargs):
45 """Only implemented in RemoteWebDriver."""

Callers

nothing calls this directly

Calls 2

quitMethod · 0.65
stopMethod · 0.65

Tested by

no test coverage detected