mechanize forms accept only str objects
This commit is contained in:
parent
0335020963
commit
5e5cf2f380
5 changed files with 9 additions and 9 deletions
|
|
@ -54,7 +54,7 @@ class LoginPage(BasePage):
|
|||
|
||||
def login3(self, passwd):
|
||||
self.browser.select_form(name='Main')
|
||||
self.browser['codconf'] = passwd
|
||||
self.browser['codconf'] = passwd.encode('utf-8')
|
||||
a = self.document.xpath('//a[@title="Valider"]')[0]
|
||||
m = re.match("javascript:RedirectToDeiPart\('([^']+)'\);", a.attrib['href'])
|
||||
if not m:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue