I don't know the reason for this error, for some reason the find_element_by_() commands are not being recognized, I've already tried to reinstall everything, I changed the Python version, nothing works, does anyone know how to solve this problem?

find_element_by_* methods are now deprecated.
find_element(By. are used now.
So, instead of find_element_by_name it is a driver.find_element(By.NAME, "name_attribute") now.
Similarly driver.find_element(By.XPATH, "element_xpath_locator") etc.
To use these methods you will need the following import:
from selenium.webdriver.common.by import By
Make sure you import By from selenium
from selenium.webdriver.common.by import By
then you would format your code like this
dv.find_elements(By.NAME,"<enter name value>")
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With