jeroenterheerdt / HAsmartirrigation

Smart Irrigation custom component for Home Assistant
MIT License
301 stars 47 forks source link

assert self._unsub_sun is not None #311

Closed stephalltricks closed 6 months ago

stephalltricks commented 7 months ago

What happened?

I get this error in the log when calculating or reseting buckets.

How to reproduce

Wait automatic calculation at 23:00

config_entry-smart_irrigation-97016f6e7231a5e3167776bdd9b143c9.json.txt

Relevant log output

2023-10-20 23:00:00.357 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/home/homeassistant/.homeassistant/custom_components/smart_irrigation/__init__.py", line 541, in _async_calculate_all
    return
  File "/home/homeassistant/.homeassistant/custom_components/smart_irrigation/__init__.py", line 920, in register_start_event
    await self.handle_reset_all_buckets(None)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/helpers/event.py", line 1558, in async_detach
    assert self._unsub_sun is not None
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError

Which version are you running?

v2023.9.3

Diagnostics file

Additional information

No response

jeroenterheerdt commented 6 months ago

I can't reproduce this :( @gatonero are you still seeing this? You confirmed it was gone in beta 5.

gatonero commented 6 months ago

I haven't seen this since then again.

stephanerosi commented 6 months ago

Hello, sorry, you're right, I am not getting it anymore now. You can close the bug.