Pastebin
Paste #23624: No description
< previous paste - next paste>
Pasted by Anonymous Coward
def get_driver_instance():
    b = webdriver.Chrome(service=Service(driver_path), options=options)
    b.implicitly_wait(10)
    b.set_window_position(0, 0)
    b.set_window_rect(0, 0, 1000, 600)
    return b
with get_driver_instance() as b:
    b.get("https://www.python.org")
    time.sleep(3)
New Paste
Go to most recent paste.
 
      