peetereczek / ztm

Home Assistant (hass.io) custom component for Warsaw public transport
MIT License
12 stars 2 forks source link

No data - MySQL #13

Closed SharkmanTyp closed 4 years ago

SharkmanTyp commented 4 years ago

Cześć,

Przełaczyłem HA na bazę MySQL, zamiast wbudowanej. Po starcie jest taki probłem: 2020-07-24 10:24:18 ERROR (MainThread) [homeassistant.helpers.entity] Update for sensor.ztm_105_from_5045_01 fails Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 272, in async_update_ha_state await self.async_device_update() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 463, in async_device_update await self.async_update() # type: ignore File "/config/custom_components/ztm/sensor.py", line 139, in async_update self._timetable = self.map_results(res.get('response', [])) File "/config/custom_components/ztm/sensor.py", line 212, in map_results return [parse_raw_timetable(row) for row in response['result']] File "/config/custom_components/ztm/sensor.py", line 212, in return [parse_raw_timetable(row) for row in response['result']] File "/config/custom_components/ztm/sensor.py", line 218, in parse_raw_timetable for val in raw_result['values']: TypeError: string indices must be integers

Pozostałe integracje działają

SharkmanTyp commented 4 years ago

Działa