MCPcopy Create free account
hub / github.com/seleniumbase/SeleniumBase / launch_driver

Function launch_driver

examples/raw_multi_drivers.py:9–20  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

7
8
9def launch_driver(url):
10 seed(len(threading.enumerate())) # Random seed for browser placement
11 driver = Driver()
12 try:
13 driver.set_window_rect(randint(4, 720), randint(8, 410), 700, 500)
14 driver.get(url=url)
15 if driver.is_element_visible("h1"):
16 driver.highlight("h1", loops=9)
17 else:
18 driver.sleep(2.2)
19 finally:
20 driver.quit()
21
22
23if __name__ == "__main__":

Callers

nothing calls this directly

Calls 7

DriverFunction · 0.90
set_window_rectMethod · 0.45
getMethod · 0.45
is_element_visibleMethod · 0.45
highlightMethod · 0.45
sleepMethod · 0.45
quitMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…