]> git.ipfire.org Git - thirdparty/python-fints.git/commitdiff
Gracefully fail on error 9010
authorRaphael Michel <mail@raphaelmichel.de>
Mon, 15 Jul 2019 15:52:40 +0000 (17:52 +0200)
committerRaphael Michel <mail@raphaelmichel.de>
Mon, 15 Jul 2019 16:07:52 +0000 (18:07 +0200)
fints/client.py

index 115b6fed50effc5f0ff191c8767e6fea4b7e183b..2cf49fa8fdf47c4fce164c089cce0817e4c16495 100644 (file)
@@ -1224,6 +1224,10 @@ class FinTS3PinTanClient(FinTS3Client):
                     # Fall back to onestep
                     self.set_tan_mechanism('999')
 
+        if response.code == '9010':
+            raise FinTSClientError("Error during dialog initialization, could not fetch BPD. Please check that you "
+                                   "passed the correct bank identifier to the HBCI URL of the correct bank.")
+
         if (not dialog.open and response.code.startswith('9')) or response.code in ('9340', '9910', '9930', '9931', '9942'):
             # Assume all 9xxx errors in a not-yet-open dialog refer to the PIN or authentication
             # During a dialog also listen for the following codes which may explicitly indicate an