-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Closed
Labels
UC Mode / CDP ModeUndetected Chromedriver Mode / CDP ModeUndetected Chromedriver Mode / CDP Modeworkaround existsYou can reach your destination if you do this...You can reach your destination if you do this...
Description
When using SeleniumBase with the following code:
with SB(uc=True, mobile=True, proxy=proxy_address, locale="fr") as sb:
url = "https://google.fr"
sb.activate_cdp_mode(url)
sb.sleep(3)
sb.cdp.mouse_click("button:contains('Tout accepter')")
sb.sleep(3.5)
sb.type("input[name='q'], textarea[name='q']", "SeleniumBase GitHub page\n")
The \n character in the .type() method does not trigger the “Enter” key to submit the Google search. Instead, it inserts a newline into the input field, as if the user pressed Shift+Enter.
I also tested the following command:
sb.cdp.press_keys("input[name='q'], textarea[name='q']", keyword + "\n")
However, this also failed to trigger the “Enter” key as expected.
Metadata
Metadata
Assignees
Labels
UC Mode / CDP ModeUndetected Chromedriver Mode / CDP ModeUndetected Chromedriver Mode / CDP Modeworkaround existsYou can reach your destination if you do this...You can reach your destination if you do this...