Commit df3fa35a authored by Sylvie Ye's avatar Sylvie Ye Committed by Romain Bignon

[sgpe] handle password expired

parent 60dfff3b
......@@ -31,7 +31,9 @@ from weboob.capabilities.base import Currency
from weboob.capabilities import NotAvailable
from import Account
from weboob.capabilities.bill import Document, Subscription
from weboob.exceptions import BrowserUnavailable, NoAccountsException, BrowserIncorrectPassword
from weboob.exceptions import (
BrowserUnavailable, NoAccountsException, BrowserIncorrectPassword, BrowserPasswordExpired,
from import is_iban_valid
from import FrenchTransaction
from import quote_plus
......@@ -62,6 +64,8 @@ class AccountsJsonPage(LoggedPage, JsonPage):
raise NoAccountsException("Vous n'avez pas l'autorisation de consulter : {}".format(reason))
elif reason == 'niv_auth_insuff':
raise BrowserIncorrectPassword('Vos identifiants sont incorrects')
elif reason == 'chgt_mdp_oblig':
raise BrowserPasswordExpired('Veuillez renouveler votre mot de passe')
raise BrowserUnavailable(reason)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment