luuuis / hass_omie

OMIE Home Assistant Integration

Home Page:https://forum.cpha.pt/t/integracao-omie-precos-horarios-diarios-mecanismo-de-ajuste/11668

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Erro com 2024.3.1

dgomes opened this issue · comments

2024-03-15 23:29:21.132 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up omie platform for sensor
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 350, in _async_setup_platform
    await asyncio.shield(awaitable)
  File "/config/custom_components/omie/sensor.py", line 122, in async_setup_entry
    await c.yesterday.async_config_entry_first_refresh()
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 283, in async_config_entry_first_refresh
    await self._async_refresh(
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 417, in _async_refresh
    self.async_update_listeners()
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 183, in async_update_listeners
    update_callback()
  File "/config/custom_components/omie/sensor.py", line 79, in update
    cet_today_hourly_data = _localize_hourly_data(today_data, series_name)
                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/omie/sensor.py", line 132, in _localize_hourly_data
    market_date = results.market_date
                  ^^^^^^^^^^^^^^^^^^^
AttributeError: 'dict' object has no attribute 'market_date'