bei meinem letzten Post hat mir das Selenium-Script ein paar Probleme bereitet. Dieses Mal vermute ich (erneut und ohne es wirklich zu wissen), dass die N26 den Aufbau ihrer Webseite geändert hat und ein Auslesen der erforderlichen Daten nicht mehr möglich ist.
Beim Abruf erhalte ich folgende Rückmeldung (und einen Screenshot) :
Code: Alles auswählen
[18.05.2023 23:09:00] Synchronisierung via non-HBCI (Hibiscus Mashup) läuft
[18.05.2023 23:09:00]
[18.05.2023 23:09:00] System-Info: OS[Windows 10 (ver. 10.0) amd64] Platform[Jameica 2.10.4 | Build: 487 vom 20230414] Plugin[hibiscus 2.10.12 | Build: 374 vom 20230418]
[18.05.2023 23:09:00] Installierte und aktive Plugin-Versionen: [Finance.Websync ver. 0.9.60 | Build: 985 vom 20230517] [Hibiscus Mashup ver. 0.9.35 | Build: 560 vom 20230517]
[18.05.2023 23:09:00] Überprüfe Jameica-Version ...
[18.05.2023 23:09:00] OK: Jameica-Version 2.10.4 installiert und aktiv
[18.05.2023 23:09:00] Überprüfe Java-Version und den verwendeten Zeichensatz ...
[18.05.2023 23:09:00] OK: Java-Version 11.0.19 von 'Azul Systems, Inc.' installiert, aktiv und verwendet Zeichensatz 'Cp1252' (Home: C:\Program Files\Jameica\javaruntime)
[18.05.2023 23:09:00] Überprüfe Selenium-Version ...
[18.05.2023 23:09:00] OK: Selenium-Version 4.9.0 installiert und aktiv
[18.05.2023 23:09:00] Überprüfe ChromeDriver-Version ...
[18.05.2023 23:09:01] OK: ChromeDriver-Version 113.0.5672.63 installiert und aktiv
[18.05.2023 23:09:01]
[18.05.2023 23:09:01] Synchronisiere Konto 'N26 - Giro, IBAN DE9410..xxxxxx [N26 Bank]' ...
[18.05.2023 23:09:01] Selenium WebDriver über ChromeDriver wird gestartet ...
[18.05.2023 23:09:02] Überprüfe Chrome-Version ...
[18.05.2023 23:09:02] OK. Browser ist: chrome ver. 113
[18.05.2023 23:09:02] Chrome gefunden. Alternativer Chromium wird daher nun wieder entfernt ...
[18.05.2023 23:09:04] Web-Login mit Selenium-WebDriver-Engine mit Anmeldekennung info******* auf https://app.n26.com/login ...
[18.05.2023 23:09:21] Erste Login-Phase abgeschlossen, prüfe auf Verfahren der Zwei-Faktor-Authentifizierung ...
[18.05.2023 23:09:22] Warte auf Banking-App Freigabe ...
[18.05.2023 23:09:27] N26-Login war erfolgreich
[18.05.2023 23:09:27] Rufe Umsatzübersicht auf und starte Abruf des Kontoauszuges ...
[18.05.2023 23:09:27] Suche Umsätze im Zeitraum vom 01.05.2023 bis 18.05.2023 und lese diese aus ...
[18.05.2023 23:09:39] INFO: Vom folgenden Fehler wurde ein Screenshot auf dem Desktop abgelegt! Datei: HibiscusMashup-Fehler_N26-Sync_1684444179075.png (Pfad: C:\Users\TOBi\Desktop\)
[18.05.2023 23:09:43] Web-Logout der aktuellen Online-Sitzung ...
[18.05.2023 23:09:43] N26-Logout war erfolgreich
[18.05.2023 23:09:44] Fehler: Auslesen des Kontostands fehlerhaft: org.openqa.selenium.TimeoutException: Expected condition failed: waiting for presence of element located by: By.xpath: //span[contains(text(),'Kontostand')]/preceding-sibling::span (tried for 10 second(s) with 500 milliseconds interval)
at org.openqa.selenium.support.ui.WebDriverWait.timeoutException(WebDriverWait.java:87)
at org.openqa.selenium.support.ui.FluentWait.until(FluentWait.java:231)
at de.derrichter.finance.websync.institute.n26.WebPull.getTransData(WebPull.java:190)
at de.derrichter.hibiscus.mashup.crossover.websync.institute.n26.Collector.run(Collector.java:189)
at de.derrichter.hibiscus.mashup.crossover.websync.WebSynchronizeJobKontoauszug.execute(WebSynchronizeJobKontoauszug.java:84)
at de.derrichter.hibiscus.mashup.crossover.websync.WebSynchronizeBackend$WebSyncJobGroup.sync(WebSynchronizeBackend.java:890)
at de.willuhn.jameica.hbci.synchronize.AbstractSynchronizeBackend$Worker.run(AbstractSynchronizeBackend.java:399)
at de.willuhn.jameica.gui.GUI$7.run(GUI.java:1107)
Caused by: org.openqa.selenium.NoSuchElementException: no such element: Unable to locate element: {"method":"xpath","selector":"//span[contains(text(),'Kontostand')]/preceding-sibling::span"}
(Session info: chrome=113.0.5672.93)
For documentation on this error, please visit: https://selenium.dev/exceptions/#no_such_element
Build info: version: '4.9.0', revision: 'd7057100a6'
System info: os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '11.0.19'
Driver info: org.openqa.selenium.chrome.ChromeDriver
Command: [71d43e0fedb1828710c1b353d8c97ad3, findElement {using=xpath, value=//span[contains(text(),'Kontostand')]/preceding-sibling::span}]
Capabilities {acceptInsecureCerts: false, browserName: chrome, browserVersion: 113.0.5672.93, chrome: {chromedriverVersion: 113.0.5672.63 (0e1a4471d5ae..., userDataDir: C:\Users\TOBi\AppData\Local...}, goog:chromeOptions: {debuggerAddress: localhost:52173}, networkConnectionEnabled: false, pageLoadStrategy: normal, platformName: WINDOWS, proxy: Proxy(direct), se:cdp: ws://localhost:52173/devtoo..., se:cdpVersion: 113.0.5672.93, setWindowRect: true, strictFileInteractability: false, timeouts: {implicit: 0, pageLoad: 300000, script: 30000}, unhandledPromptBehavior: dismiss and notify, webauthn:extension:credBlob: true, webauthn:extension:largeBlob: true, webauthn:extension:minPinLength: true, webauthn:extension:prf: true, webauthn:virtualAuthenticators: true}
Session ID: 71d43e0fedb1828710c1b353d8c97ad3
at jdk.internal.reflect.GeneratedConstructorAccessor27.newInstance(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.base/java.lang.reflect.Constructor.newInstance(Unknown Source)
at org.openqa.selenium.remote.codec.w3c.W3CHttpResponseCodec.createException(W3CHttpResponseCodec.java:200)
at org.openqa.selenium.remote.codec.w3c.W3CHttpResponseCodec.decode(W3CHttpResponseCodec.java:133)
at org.openqa.selenium.remote.codec.w3c.W3CHttpResponseCodec.decode(W3CHttpResponseCodec.java:53)
at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:193)
at org.openqa.selenium.remote.service.DriverCommandExecutor.invokeExecute(DriverCommandExecutor.java:183)
at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(DriverCommandExecutor.java:158)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:543)
at org.openqa.selenium.remote.ElementLocation$ElementFinder$2.findElement(ElementLocation.java:162)
at org.openqa.selenium.remote.ElementLocation.findElement(ElementLocation.java:60)
at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:352)
at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:344)
at org.openqa.selenium.support.ui.ExpectedConditions$6.apply(ExpectedConditions.java:174)
at org.openqa.selenium.support.ui.ExpectedConditions$6.apply(ExpectedConditions.java:171)
at org.openqa.selenium.support.ui.FluentWait.until(FluentWait.java:208)
... 6 more
Vielen Dank für Tipps und Unterstützung im Voraus,
Tobias