guerrerotook / securitas-direct-new-api

This repository contains the new securitas direct API that can be integrated in Home Assistant
Apache License 2.0
79 stars 30 forks source link

Exception during start #122

Closed nottix closed 1 year ago

nottix commented 1 year ago

Hello,

in the last 3-4 data the integration has stopped working. When i try reboot HA i receive this exception:

`Logger: homeassistant.components.alarm_control_panel Source: custom_components/securitas/securitas_direct_new_api/apimanager.py:149 Integration: Pannello di controllo degli allarmi (documentation, issues) First occurred: 20:42:24 (1 occurrences) Last logged: 20:42:24

Error while setting up securitas platform for alarm_control_panel Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 293, in _async_setup_platform await asyncio.shield(task) File "/config/custom_components/securitas/alarm_control_panel.py", line 58, in async_setup_entry current_state: CheckAlarmStatus = await client.update_overview( File "/config/custom_components/securitas/init.py", line 408, in update_overview alarm_status = await self.session.check_alarm_status( File "/config/custom_components/securitas/securitas_direct_new_api/apimanager.py", line 486, in check_alarm_status response: ClientResponse = await self._execute_request( File "/config/custom_components/securitas/securitas_direct_new_api/apimanager.py", line 127, in _execute_request error_login: bool = await self._check_errros(response_text) File "/config/custom_components/securitas/securitas_direct_new_api/apimanager.py", line 149, in _check_errros response = json.loads(value) File "/usr/local/lib/python3.10/json/init.py", line 346, in loads return _default_decoder.decode(s) File "/usr/local/lib/python3.10/json/decoder.py", line 337, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) File "/usr/local/lib/python3.10/json/decoder.py", line 355, in raw_decode raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0) `

wolfcam commented 1 year ago

@nottix I have the same situation, how do you resolve this ?

nottix commented 1 year ago

Requesting to Verisure to update the central unit of alarm :-)