ChrisHaPunkt / ha-stihl-imow

Using https://github.com/ChrisHaPunkt/stihl-imow-webapi to provide STIHL iMow lawn mower information to Home Assistant
19 stars 1 forks source link

CSRF Token issue #28

Closed fhaferkorn closed 2 months ago

fhaferkorn commented 2 months ago

Logger: homeassistant.config_entries Quelle: config_entries.py:586 Erstmals aufgetreten: 18:41:39 (4 Vorkommnisse) Zuletzt protokolliert: 22:23:28

Error setting up entry Lawn Mower for stihl_imow Traceback (most recent call last): File "/usr/local/lib/python3.12/site-packages/imow/api/init.py", line 237, in __fetch_new_csrf_token_and_request_id ).get("value") ^^^ AttributeError: 'NoneType' object has no attribute 'get'

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/config_entries.py", line 586, in async_setup result = await component.async_setup_entry(hass, self) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/stihl_imow/init.py", line 53, in async_setup_entry await imow_api.get_token(force_reauth=True) File "/usr/local/lib/python3.12/site-packages/imow/api/init.py", line 139, in get_token await self.authenticate(self.api_email, self.api_password) File "/usr/local/lib/python3.12/site-packages/imow/api/init.py", line 190, in authenticate await self.fetch_new_csrf_token_and_request_id() File "/usr/local/lib/python3.12/site-packages/imow/api/init.py", line 242, in fetch_new_csrf_token_and_request_id raise ProcessLookupError( ProcessLookupError: Did not find necessary csrf token and/or request id in html source

fhaferkorn commented 2 months ago

After complete Restart of Home Assistant the issue is gone