After update to 113: Automations do not trigger any more but work if manually triggered

Dear Forum,

I would like to get my automations back on track. But I have a strange behaviour:

  • in HA 112, all automations did work
  • after the update to 113 automations are not triggered any more.

as an example, let’s take a simple “switch the light on” automation:

- id: '1562488492387'
  alias: EG_KUE_Licht AN
  trigger:
  - entity_id: switch.eg_kue_schtuer_sek
    for: 0:0:0
    from: 'off'
    platform: state
    to: 'on'
  condition: []
  action:
  - data:
      brightness: '255'
      entity_id: group.eg_kue_beleuchtung
    service: light.turn_on
  - data:
      entity_id: media_player.kuche
    service: media_player.media_play
  mode: single

This was created with the automation editor. The Input is a MQTT signal that ultimately switches the entity
“switch.eg_kue_schtuer_sek” on/off.

What did I test so far:

  • If I trigger the automation manually, the light turns on, the music starts
  • The MQTT signal is coming in as usual, an card in lovelace for the switch behaves accordingly (so the MQTT message enters HA, is processed and translated to something HA works with, I guess)
  • If I manually switch the lovelace card of this switch, the automation does not do anything
  • If the MQTT signal is coming in, the automation does not do anything
  • the “for” part of the trigger was added as a test, it is not present in the original automation

Did anyone encounter something similar? Any hints in which direction I can further investigate?

Best regards,
Christian

You definitely do not need that for option on the trigger.

Are you sure the automation is turned on? Check it on the STATES tab of the Developer Tools page. Also check its last_triggered attribute to see if it has ever triggered, and if so, when it did the last time. (Note the time is in UTC.)

Do you see any errors or warnings anywhere?

Dear Phil,

I checked the following:

  • The automation page toggle switches label the automations as “on”
  • before doing any test for your post the last triggered entry labels “27. Juli 2020, 09:42”
  • I pressed the “trigger” button, the last triggered entry labels " 27. Juli 2020, 20:53"
  • The development page labels the automation as “on”
  • The triggered entry corrosponds to the information above.

When doing the update, it was not doing it automatically. Something was wrong and it did reroll back to 112. I then followed the forum in reducing the configuration.yaml to a minimum, the update went well. I then turned stuff back on and by that identyfied the device tracker needed reconfiguration. After that the configuration.yaml was back to its former glory and HA started.

I do have a strange behavoir on a total different corner of HA:

I do have a Xiaomi vacuum cleaner. In one lovelace card the vacuum.xiaomi entry works properly (I see the information that was there in 112) in a different lovelace screen I use the same type of card and it has a yellow label “Home assistant is just starting. Something might not be available” (not the literal text, just my DE-> ENG translation)

In Supervisor -> System I get some error message after a restart:


20-07-27 17:33:39 INFO (SyncWorker_0) [supervisor.docker.interface] Restart homeassistant/qemux86-64-homeassistant
20-07-27 17:35:29 ERROR (MainThread) [supervisor.utils] Can't execute restart while a task is in progress
20-07-27 17:43:45 WARNING (MainThread) [supervisor.homeassistant] Don't wait anymore of Home Assistant startup!
20-07-27 17:43:45 ERROR (MainThread) [asyncio] Task exception was never retrieved
future: <Task finished name='Task-468673' coro=<process_lock.<locals>.wrap_api() done, defined at /usr/src/supervisor/supervisor/utils/__init__.py:22> exception=HomeAssistantError()>
Traceback (most recent call last):
  File "/usr/src/supervisor/supervisor/utils/__init__.py", line 31, in wrap_api
    return await method(api, *args, **kwargs)
  File "/usr/src/supervisor/supervisor/homeassistant.py", line 421, in restart
    await self._block_till_run()
  File "/usr/src/supervisor/supervisor/homeassistant.py", line 638, in _block_till_run
    raise HomeAssistantError()
supervisor.exceptions.HomeAssistantError
20-07-27 17:47:19 INFO (MainThread) [supervisor.updater] Fetch update data from https://version.home-assistant.io/stable.json
20-07-27 17:55:18 INFO (MainThread) [supervisor.homeassistant] Updated Home Assistant API token
20-07-27 18:25:22 INFO (MainThread) [supervisor.homeassistant] Updated Home Assistant API token
20-07-27 18:47:19 INFO (MainThread) [supervisor.store.git] Update add-on https://github.com/hassio-addons/repository repository
20-07-27 18:47:19 INFO (MainThread) [supervisor.store.git] Update add-on https://github.com/home-assistant/hassio-addons repository
20-07-27 18:47:19 INFO (MainThread) [supervisor.store.git] Update add-on https://github.com/esphome/hassio repository
20-07-27 18:47:21 INFO (MainThread) [supervisor.store] Load add-ons from store: 68 all - 0 new - 0 remove
20-07-27 18:55:26 INFO (MainThread) [supervisor.homeassistant] Updated Home Assistant API token
20-07-27 18:57:03 INFO (SyncWorker_4) [supervisor.docker.interface] Restart homeassistant/qemux86-64-homeassistant

Thanks for your help,
Christian

I know nothing about Xiamoi vacuum cleaners. However, I have seen a lot of discussion around it. You might want to read through:

So to elimante the vacuum, I removed it from the configuration.yaml, removed the lovelace cards and deleted the automation starting it. Still the automation behaviour has not changed.
I also renamed home-assistant_v2.db to force HA to create a new one (obviously a shot in the dark). This did not solve anything.

The Supervisor/System error is still occuring:

0-07-27 19:30:33 ERROR (MainThread) [asyncio] Task exception was never retrieved
future: <Task finished name='Task-474414' coro=<process_lock.<locals>.wrap_api() done, defined at /usr/src/supervisor/supervisor/utils/__init__.py:22> exception=HomeAssistantError()>
Traceback (most recent call last):
  File "/usr/src/supervisor/supervisor/utils/__init__.py", line 31, in wrap_api
    return await method(api, *args, **kwargs)
  File "/usr/src/supervisor/supervisor/homeassistant.py", line 421, in restart
    await self._block_till_run()
  File "/usr/src/supervisor/supervisor/homeassistant.py", line 638, in _block_till_run
    raise HomeAssistantError()
supervisor.exceptions.HomeAssistantError

So sadly no helpful news :frowning: .

Again, really can’t help you. Not only are the problems related to an integration I do not use, you’re also having problems using Supervisor, which I also don’t use.

If the discussion in the link I provided you did not help you, then you should probably search other forum topics, or start a new topic, because given the title of this topic, and the fact that there have already been multiple replies, it’s not likely someone who can help you will read it.

Dear Phil,

ok, thanks for your help. Since the robot is out of the equasion, I will try and solve the error given in the system log.

Have a nice day,
Christian

So I did some more fiddeling.
the Supervisor errors were solvable by restarting all home assistant related docker containers. (beforehand I just restarted HA itself)

I digged in the /config/home-assistant.log file and found errors regarding the devicetracker giving too slow responses. I deactivated the device tracker integration and the automations returned to normal operation.

1 Like