Wpis z mikrobloga

#naukaprogramowania #python
próbuje się zalogować do strony, przez pythona i selenium
syszukuję na stronie label name, i chce tam wlepic dane:

cos nie idzie :(
jakaś porada jak to znprawić?

KOD:
PATH="C:\Program Files (x86)\chromedriver.exe"
driver = webdriver.Chrome(PATH)
driver.get(url)

Logininput= driver.findelementbyid("login")
Logininput.sendkeys(username)
Passinput=driver.findelementbyid("password-login")
Passinput.sendkeys(password)

bład:
selenium.common.exceptions.ElementNotInteractableException: Message: element not interactable
(Session info: chrome=85.0.4183.121)

dane strony : obrazek
l.....k - #naukaprogramowania #python 
próbuje się zalogować do strony, przez python...

źródło: comment_1601547594TB4z9ts2PSg2xacPHV2v0u.jpg

Pobierz
  • 6
  • Odpowiedz
element not interactable

(Session info: chrome=85.0.4183.121)


@luukasek: ps znajdowanie przez xpath tez daje ten sam blad:
Logininput = driver.findelementbyxpath('//*[@id="login"]')
Logininput.sendkeys(username)
Passinput=driver.findelementbyxpath('//*[@id="password-login"]')
Passinput.sendkeys(password)
#
selenium.common.exceptions.ElementNotInteractableException: Message: element not interactable
(Session info: chrome=85.0.4183.121)
  • Odpowiedz
wycielo _ ale tutaj na stronie, a nie w kodzie


@luukasek: Masz pastebin od tego, albo przynajmniej możesz wypokowi zaznaczyć, że wpisujesz kod
Ok, z tym wykopem to mój błąd. Rację pewnie ma @aseeon_ - wiec zaznacz w xpath, że chodzi o pole input.
  • Odpowiedz