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

Function main

examples/cdp_mode/raw_multi_c_async.py:9–19  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

7
8
9async def main(url):
10 driver = await cdp_driver.start_async()
11 page = await driver.get(url)
12 await page.set_window_rect(randint(4, 600), randint(8, 410), 860, 500)
13 await page.sleep(2.6)
14 await page.solve_captcha()
15 await page.sleep(2.2)
16 if not await page.is_element_visible("img#captcha-success"):
17 await page.solve_captcha()
18 await page.sleep(2.2)
19 driver.stop()
20
21
22def run_main(url):

Callers 1

run_mainFunction · 0.70

Calls 6

getMethod · 0.45
set_window_rectMethod · 0.45
sleepMethod · 0.45
solve_captchaMethod · 0.45
is_element_visibleMethod · 0.45
stopMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…