[freemobile] New website launched, current module not working ('Response' object has no attribute 'login')
With which module do you encounter problems?
freemobile
Describe the problem you encounter
A new website launched (Cf this article for example) and it seems that the current module is not compatible with it. Some changes may be needed.
Paste here the stacktrace or error message you observe
2020-12-13 00:15:02,419:DEBUG:weboob.config:2.1:yamlconfig.py:69:load Loading configuration file: <homedir>/.config/weboob/boobill.storage.
2020-12-13 00:15:02,421:DEBUG:weboob.config:2.1:yamlconfig.py:73:load Configuration file loaded: <homedir>/.config/weboob/boobill.storage.
2020-12-13 00:15:02,515:DEBUG:modules:2.1:modules.py:166:load_module Loaded module "freemobile" from <homedir>/Projects/WEBOOB/weboob/modules/freemobile
2020-12-13 00:15:02,824:DEBUG:backend:2.1:modules.py:97:create_instance Created backend "freemobile" for module "freemobile"
2020-12-13 00:15:02,825:DEBUG:weboob.config:2.1:iniconfig.py:53:load Loading application configuration file: <homedir>/.config/weboob/boobill.
2020-12-13 00:15:02,825:DEBUG:weboob.config:2.1:iniconfig.py:73:load Application configuration file loaded: <homedir>/.config/weboob/boobill.
2020-12-13 00:15:02,841:DEBUG:bcall:2.1:bcall.py:92:backend_process <Backend 'freemobile'>: Calling function <bound method Application._do_complete of <weboob.applications.boobill.boobill.Boobill object at 0x10300a710>>
2020-12-13 00:15:02,848:DEBUG:urllib3.util.retry:2.1:retry.py:210:from_int Converted retries value: 2 -> Retry(total=2, connect=None, read=None, redirect=None, status=None)
2020-12-13 00:15:02,848:DEBUG:urllib3.util.retry:2.1:retry.py:210:from_int Converted retries value: 2 -> Retry(total=2, connect=None, read=None, redirect=None, status=None)
2020-12-13 00:15:02,851:DEBUG:urllib3.connectionpool:2.1:connectionpool.py:813:_new_conn Starting new HTTPS connection (1): mobile.free.fr:443
2020-12-13 00:15:02,878:DEBUG:urllib3.connectionpool:2.1:connectionpool.py:393:_make_request https://mobile.free.fr:443 "GET /moncompte/index.php HTTP/1.1" 301 None
2020-12-13 00:15:02,935:DEBUG:urllib3.connectionpool:2.1:connectionpool.py:393:_make_request https://mobile.free.fr:443 "GET /account/index.php HTTP/1.1" 200 None
2020-12-13 00:15:02,941:DEBUG:backend.freemobile.browser:2.1:browsers.py:898:internal_callback Unable to handle https://mobile.free.fr/account/index.php
2020-12-13 00:15:02,941:DEBUG:bcall:2.1:bcall.py:98:backend_process <Backend 'freemobile'>: Called function <bound method Application._do_complete of <weboob.applications.boobill.boobill.Boobill object at 0x10300a710>> raised an error: AttributeError("'Response' object has no attribute 'login'")
Bug(freemobile): 'Response' object has no attribute 'login'
Traceback (most recent call last):
File "<homedir>/Projects/WEBOOB/weboob/weboob/core/bcall.py", line 94, in backend_process
result = function(backend, *args, **kwargs)
File "<homedir>/Projects/WEBOOB/weboob/weboob/tools/application/base.py", line 318, in _do_complete
res = getattr(backend, function)(*args, **kwargs)
File "<homedir>/Projects/WEBOOB/weboob/weboob/capabilities/bill.py", line 325, in iter_resources
return self.iter_subscription()
File "<homedir>/Projects/WEBOOB/weboob/modules/freemobile/module.py", line 56, in iter_subscription
return self.browser.get_subscription_list()
File "<homedir>/Projects/WEBOOB/weboob/weboob/browser/browsers.py", line 985, in inner
browser.do_login()
File "<homedir>/Projects/WEBOOB/weboob/modules/freemobile/browser.py", line 45, in do_login
self.loginpage.stay_or_go().login(self.username, self.password)
AttributeError: 'Response' object has no attribute 'login'
What are the steps to reproduce the problem?
Just try to use freemobile with boobill
for example.
What weboob version are you using?
Git current.
Output of weboob-config --version
command:
weboob-config v2.1 Copyright(C) 2010-2020 Christophe Benz, Romain Bignon
What module version are you using?
Output of weboob-config info MODULE_NAME
command:
.------------------------------------------------------------------------------.
| Module freemobile |
+-----------------.------------------------------------------------------------'
| Version | 202008112126
| Maintainer | Florent Fourcot <weboob@flo.fourcot.fr>
| License | LGPLv3+
| Description | Free Mobile website
| Capabilities | CapMessages, CapMessagesPost, CapProfile, CapCollection, CapDocument
| Installed | yes
| Location | <homedir>/Projects/WEBOOB/weboob/modules/freemobile
| |
| Configuration | login: Account ID (default: )
| | password: Password (default: )
'-----------------'
How did you install weboob?
pip install -e .
Additional info you'd like to mention
I'll try to have a look at it.