How To Wait For A Text Field To Be Editable With Selenium In Python 3.8
I am just making a selenium bot as a fun project that is supposed to play typeracer for me, and I am having a bit of trouble getting it to wait for the countdown to be done before
Solution 1:
You need to replace the line:
inputField =WebDriverWait(self.driver, 10).until(EC.visibility_of((By.XPATH, "<div contenteditable=\"plaintext-only\"></div>")))
with:
inputField = WebDriverWait(self.driver, 10).until(EC.visibility_of(self.driver.find_element_by_xpath("//div[@contenteditable='plaintext-only']")))
or:
inputField = WebDriverWait(self.driver, 10).until(EC.visibility_of_element_located((By.XPATH, "//div[@contenteditable='plaintext-only']")))
Post a Comment for "How To Wait For A Text Field To Be Editable With Selenium In Python 3.8"