raise BrowserHTTPError when the website is unavailable
This commit is contained in:
parent
88da52a57a
commit
76040343bc
1 changed files with 1 additions and 1 deletions
|
|
@ -54,7 +54,7 @@ class HSBC(BaseBrowser):
|
|||
assert self.password.isdigit()
|
||||
|
||||
data = {'Ident': self.username}
|
||||
r = self.readurl('https://client.hsbc.fr/cgi-bin/emcgi?Appl=WEBACC', urllib.urlencode(data))
|
||||
r = self.readurl('https://client.hsbc.fr/cgi-bin/emcgi?Appl=WEBACC', urllib.urlencode(data), if_fail='raise')
|
||||
m = re.search('sessionid=([^ "]+)', r, flags=re.MULTILINE)
|
||||
if not m:
|
||||
raise BrowserIncorrectPassword()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue