I'm trying to give simple input in the Youtube search box. I get this error:
selenium.common.exceptions.ElementNotVisibleException: Message: element not interactable
This is my code:
from selenium import webdriver
browser = webdriver.Opera()
browser.set_window_position(0,0)
browser.set_window_size(1366, 768)
browser.get('https://youtube.com')
elem = browser.find_element_by_xpath('//*[@id="search"]')
elem.click()
elem.sendkeys('cats')
Could it be because the page doesn't load fast enough?