RogerSelwyn / Home_Assistant_SkyQ_MediaPlayer

Home Assistant SkyQ Media player component
MIT License
105 stars 16 forks source link

[BUG] Error handling status file #136

Closed felisida closed 1 year ago

felisida commented 1 year ago

my sky's don't was configured Screenshot 2023-01-06 alle 18 48 54

Component versions

  1. What version of SkyQ component are you using? 2.10.8
  2. What was the last version where the problem was not shown? before update HA

Output of HA logs
Questo errore ha avuto origine da un'integrazione personalizzata.

Logger: homeassistant.config_entries Source: custom_components/skyq/init.py:158 Integration: Sky Q (documentation, issues) First occurred: 18:36:18 (4 occurrences) Last logged: 18:38:32

Error setting up entry Sky Soggiorno for skyq Error setting up entry Sky Cucina for skyq Error setting up entry Sky Camera for skyq Error setting up entry Sky Taverna for skyq Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/config_entries.py", line 382, in async_setup result = await component.async_setup_entry(hass, self) File "/config/custom_components/skyq/init.py", line 64, in async_setup_entry _check_for_legacy_storage(hass) File "/config/custom_components/skyq/init.py", line 158, in _check_for_legacy_storage file_content = json.load(infile) File "/usr/local/lib/python3.10/json/init.py", line 293, in load return loads(fp.read(), 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)

RogerSelwyn commented 1 year ago

As a workaround delete the file .storage/skyq.restore_state should get you working again

RogerSelwyn commented 1 year ago

If it doesn't, I'll work a fix for tomorrow I would think.

felisida commented 1 year ago

Thank you for the prompt response, I deleted the file, reloaded the integration, and everything is working again.

RogerSelwyn commented 1 year ago

Fixed by - https://github.com/RogerSelwyn/Home_Assistant_SkyQ_MediaPlayer/releases/tag/v2.10.9