fui / fui-kk

Course evaluation software for courses in informatics at the University of Oslo.
MIT License
9 stars 7 forks source link

Make download feilet #92

Closed dennisno closed 6 years ago

dennisno commented 6 years ago

Prøver å kjøre "make download" på ubuntu subsystem. Har kjørt make install-linux. Får denne feilmeldingen etter at jeg har skrevet inn passord: python3 fui_kk/download_reports.py -u fui Password: Traceback (most recent call last): File "fui_kk/download_reports.py", line 238, in main() File "fui_kk/download_reports.py", line 227, in main login(driver, args) File "fui_kk/download_reports.py", line 62, in login userfield = driver.find_element_by_css_selector('#username') File "/usr/local/lib/python3.5/dist-packages/selenium/webdriver/remote/webdriver.py", line 437, in find_element_by_css_selector return self.find_element(by=By.CSS_SELECTOR, value=css_selector) File "/usr/local/lib/python3.5/dist-packages/selenium/webdriver/remote/webdriver.py", line 752, in find_element 'value': value})['value'] File "/usr/local/lib/python3.5/dist-packages/selenium/webdriver/remote/webdriver.py", line 236, in execute self.error_handler.check_response(response) File "/usr/local/lib/python3.5/dist-packages/selenium/webdriver/remote/errorhandler.py", line 192, in check_response raise exception_class(message, screen, stacktrace) selenium.common.exceptions.NoSuchElementException: Message: {"errorMessage":"Unable to find element with css selector '#username'","request":{"headers":{"Accept":"application/json","Accept-Encoding":"identity","Connection":"close","Content-Length":"100","Content-Type":"application/json;charset=UTF-8","Host":"127.0.0.1:52116","User-Agent":"Python-urllib/3.5"},"httpVersion":"1.1","method":"POST","post":"{\"sessionId\": \"4655aac0-5dc5-11e8-8b20-175ca5305d09\", \"using\": \"css selector\", \"value\": \"#username\"}","url":"/element","urlParsed":{"anchor":"","query":"","file":"element","directory":"/","path":"/element","relative":"/element","port":"","host":"","password":"","user":"","userInfo":"","authority":"","protocol":"","source":"/element","queryKey":{},"chunks":["element"]},"urlOriginal":"/session/4655aac0-5dc5-11e8-8b20-175ca5305d09/element"}} Screenshot: available via screen

Makefile:31: recipe for target 'download' failed make: *** [download] Error 1

dennisno commented 6 years ago

Fikset seg selv etter et par dager, vet fortsatt ikke hva som gikk galt.

olehermanse commented 6 years ago

@dennisno beklager sent svar. Feilmeldingen NoSuchElementException betyr at den ikke finner de linkene / knappene den forventer etter å ha logget inn i nettskjema. Det skjer f.eks. Hvis du får en "popup" når du logger inn (passordbytte, godta nye regler el.l.). Fikses ved å logge inn i nettskjema som fui-brukeren og godta/klikke seg gjennom det som kommer opp.

dennisno commented 6 years ago

@olehermanse Jeg tror det kan ha vært et problem med ustabilt internett, da jeg fikk samme feil halvveis gjennom downloaden, og oppdaget da at jeg hadde mistet internett tilkoblingen