Automation is crashing

What does automation.robby_heinrich_ist_wach do? You might as well post it’s config too.

alias: Robby - EG ist wach
description: ""
trigger:
  - platform: state
    entity_id:
      - group.heini_computerzimmer_rechner
    to: home
  - platform: state
    entity_id:
      - device_tracker.henry_pc
    to: home
  - platform: state
    entity_id:
      - person.heinrich_xyz
    from: home
  - platform: numeric_state
    entity_id: sensor.edel_mi_11_lite_sleep_confidence
    above: 50
    for:
      hours: 0
      minutes: 15
      seconds: 0
  - platform: state
    entity_id:
      - person.edeltraud_xyz
    from: home
  - platform: numeric_state
    entity_id: vacuum.valetudo_robby
    attribute: battery_level
    above: 70
condition:
  - condition: or
    conditions:
      - condition: numeric_state
        entity_id: sensor.edel_mi_11_lite_sleep_confidence
        below: 50
      - condition: state
        entity_id: person.edeltraud_xyz
        state: not_home
    alias: Edel schläft nicht oder ist nicht da
  - condition: or
    conditions:
      - condition: state
        entity_id: group.heini_computerzimmer_rechner
        state: home
      - condition: state
        entity_id: device_tracker.henry_pc
        state: home
      - condition: state
        entity_id: person.heinrich_xyz
        state: not_home
    alias: Heinrich abwesend oder Rechner an
  - condition: numeric_state
    entity_id: vacuum.valetudo_robby
    attribute: battery_level
    above: 50
  - condition: or
    conditions:
      - condition: time
        after: "09:30:00"
        before: "22:00:00"
        weekday:
          - mon
          - tue
          - wed
          - thu
          - fri
          - sat
          - sun
      - condition: and
        conditions:
          - condition: state
            entity_id: person.heinrich_xyz
            state: not_home
          - condition: state
            entity_id: person.edeltraud_xyz
            state: not_home
action:
  - if:
      - condition: state
        entity_id: vacuum.valetudo_robby
        state: cleaning
    then:
      - wait_for_trigger:
          - platform: state
            entity_id:
              - vacuum.valetudo_robby
            from: cleaning
        continue_on_timeout: false
    enabled: true
  - service: vacuum.start
    data: {}
    target:
      device_id: 696e85cc0fdf721148e74444b71008d6
    enabled: false
  - service: mqtt.publish
    data:
      topic: homeassistant/robby/MapSegmentationCapability/clean/set
      payload: >-
        {"segment_ids": [ "19", "21", "22"], "iterations": 1, "customOrder":
        true}
      qos: "1"
    enabled: true
  - wait_for_trigger:
      - platform: state
        entity_id:
          - vacuum.valetudo_robby
        from: cleaning
    continue_on_timeout: false
    enabled: true
  - service: automation.trigger
    data:
      skip_condition: true
    target:
      entity_id: automation.robby_zuruck_basis_oder_ausleeren
  - service: automation.turn_off
    data:
      stop_actions: true
    target:
      entity_id: automation.robby_heinrich_ist_wach
    enabled: false
  - service: script.robby_zuruck_basis_oder_ausleeren
    data: {}
mode: single

BTW renamed it in automation.robby_eg_ist_wach

Looks like its working in this state:

alias: Robby - Zurück Basis oder ausleeren
description: ""
trigger:
  - platform: numeric_state
    entity_id: sensor.valetudo_robby_current_statistics_area
    above: 100000
  - platform: state
    entity_id:
      - vacuum.valetudo_robby
    to: docked
condition:
  - condition: state
    entity_id: automation.robby_eg_alle_weg
    attribute: current
    state: 0
  - condition: state
    entity_id: automation.robby_eg_ist_wach
    attribute: current
    state: 0
  - condition: state
    entity_id: vacuum.valetudo_robby
    state: docked
  - condition: numeric_state
    entity_id: sensor.valetudo_robby_current_statistics_area
    above: 100000
action:
  - service: automation.turn_off
    data:
      stop_actions: true
    target:
      entity_id:
        - automation.robby_eg_alle_weg
    enabled: false
  - if:
      - condition: numeric_state
        entity_id: sensor.valetudo_robby_current_statistics_area
        above: 100000
    then:
      - if:
          - condition: numeric_state
            entity_id: vacuum.valetudo_robby
            attribute: battery_level
            below: 50
        then:
          - service: vacuum.return_to_base
            data: {}
            target:
              entity_id: vacuum.valetudo_robby
          - wait_for_trigger:
              - platform: numeric_state
                entity_id: vacuum.valetudo_robby
                attribute: battery_level
                above: 49
            continue_on_timeout: false
      - if:
          - condition: or
            conditions:
              - condition: state
                entity_id: vacuum.valetudo_robby
                state: returning
              - condition: state
                entity_id: vacuum.valetudo_robby
                state: cleaning
        then:
          - service: vacuum.stop
            data: {}
            target:
              entity_id: vacuum.valetudo_robby
        enabled: true
      - service: mqtt.publish
        data:
          topic: homeassistant/robby/GoToLocationCapability/go/set
          payload: "{   \"coordinates\": {     \"x\": 2097,     \"y\": 3231   } }"
          qos: "1"
      - service: notify.matrix_haus_xyz
        data:
          message: Robby ist fertig mit saugen, bitte Behälter ausleeren!
    else:
      - service: vacuum.return_to_base
        data: {}
        target:
          entity_id: vacuum.valetudo_robby
  - service: automation.turn_on
    data: {}
    target:
      entity_id: automation.robby_eg_alle_weg
    enabled: false
mode: single

I don’t know why but deactivating a automation in the script let’s crashing it…