SolarEdge broken since 0.102.3

Hi
Update lastnight from HASSIO 0.102.2 to 0.102.3
Since then my solar edge sensors report “Entity Not Found”

from the Errorlog:

2019-12-01 14:48:37 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up platform solaredge
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 150, in _async_setup_platform
    await asyncio.wait_for(asyncio.shield(task), SLOW_SETUP_MAX_WAIT)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 442, in wait_for
    return fut.result()
  File "/usr/src/homeassistant/homeassistant/components/solaredge/sensor.py", line 35, in async_setup_entry
    api.get_details, entry.data[CONF_SITE_ID]
  File "/usr/src/homeassistant/homeassistant/core.py", line 343, in async_add_executor_job
    task = self.loop.run_in_executor(None, target, *args)
  File "uvloop/loop.pyx", line 2647, in uvloop.loop.Loop.run_in_executor
  File "/usr/local/lib/python3.7/asyncio/coroutines.py", line 162, in iscoroutinefunction
    return (inspect.iscoroutinefunction(func) or
  File "/usr/local/lib/python3.7/inspect.py", line 185, in iscoroutinefunction
    object.__code__.co_flags & CO_COROUTINE)
AttributeError: 'functools._lru_cache_wrapper' object has no attribute '__code__'

Configuration.yaml is done accordingly the docs: https://www.home-assistant.io/integrations/solaredge/

and looks like:

# Sensors
solaredge:
  api_key: <my_api_key_of_course>
  site_id: <my_site_id_of_course>

sensor:
# Solar Edge Solarpanels
  - platform: template
    sensors:
      solaredge_energy_current_power:
        friendly_name: "Current Power"
        unit_of_measurement: 'Wh'
        value_template: "{{ (states('sensor.solaredge_current_power') | float ) | round(2) }}"
      solaredge_energy_today:
        friendly_name: "Energy Today"
        unit_of_measurement: 'KWh'
        value_template: "{{ (states('sensor.solaredge_energy_today') | float / 1000) | round(1) }}"
      solaredge_energy_this_month:
        friendly_name: "Energy This Month"
        unit_of_measurement: 'KWh'
        value_template: "{{ (states('sensor.solaredge_energy_this_month') | float / 1000) | round(0) }}"
      solaredge_energy_this_year:
        friendly_name: "Energy This year"
        unit_of_measurement: 'MWh'
        value_template: "{{ (states('sensor.solaredge_energy_this_year') | float / 1000000) | round(2) }}"
      solaredge_energy_lifetime_energy:
        friendly_name: "Energy Since"
        unit_of_measurement: 'MWh'
        value_template: "{{ (states('sensor.solaredge_lifetime_energy') | float / 1000000) | round(2) }}"

Hope this can be fixed.

1 Like

Hi,

Just to say I have the same issue. So you’re not alone… :slight_smile:

I can’t find anything in the Release Notes that something is changed.

the same here … broken after update

2019-12-02 15:04:29 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up platform solaredge
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 150, in _async_setup_platform
    await asyncio.wait_for(asyncio.shield(task), SLOW_SETUP_MAX_WAIT)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 442, in wait_for
    return fut.result()
  File "/usr/src/homeassistant/homeassistant/components/solaredge/sensor.py", line 35, in async_setup_entry
    api.get_details, entry.data[CONF_SITE_ID]
  File "/usr/src/homeassistant/homeassistant/core.py", line 343, in async_add_executor_job
    task = self.loop.run_in_executor(None, target, *args)
  File "uvloop/loop.pyx", line 2647, in uvloop.loop.Loop.run_in_executor
  File "/usr/local/lib/python3.7/asyncio/coroutines.py", line 162, in iscoroutinefunction
    return (inspect.iscoroutinefunction(func) or
  File "/usr/local/lib/python3.7/inspect.py", line 185, in iscoroutinefunction
    object.__code__.co_flags & CO_COROUTINE)
AttributeError: 'functools._lru_cache_wrapper' object has no attribute '__code__'

Here too. Broken since update to 102.3. Same erros as above.

I have the same issue, with the same symptoms.

Here too. Broken since update to 102.2. Same erros as above.

Same, fix inc one would hope :_)

Same problem here…

Same here. Checked to see if there were any breaking changes and none.

FYI, already reported to HA Github issue: https://github.com/home-assistant/home-assistant/issues/29291

Same here. I hope there’s a fix for it

Same here, hope this is fixed soon.

Same issue here also

Same here! :roll_eyes:

Yup, me too.

me too :worried:

Now there is HA 0.103.0
Is it fixed?

Jep, it’s working again after this update !

Still not working for me.

The battery chargeLevel is missing