Below trigger condition activated when sensor reconnected

Hi,

I want to get a notification, when my drier finished his work. I’m using a DeLock 11827 Wifi Power Outlet to get the power information and I’m using a trigger condition. This is working, but the outlet is loosing sometimes connection and if the connection is reestablished I get a notification. How to solve the problem?

alias: Trockner fertig
description: ""
trigger:
  - platform: numeric_state
    entity_id: sensor.trockner_energy_power
    for:
      hours: 0
      minutes: 5
      seconds: 0
    below: 10
condition: []
action:
  - service: notify.mobile_app_sm_g981b
    data:
      message: Trockner fertig
      title: Trockner
mode: single
condition:
  - "{{ trigger.from_state.state not in ('unknown', 'unavailable') }}"

You may want to consider using one of the following blueprints:

Both work well but use slightly different methods and have different options. Personally, I use the first one because I don’t need the options included in the other one.

Is this correct? I’m a newbie.

alias: Waschmaschine fertig
description: ""
trigger:
  - platform: numeric_state
    entity_id: sensor.waschmaschine_energy_power
    for:
      hours: 0
      minutes: 5
      seconds: 0
    below: 10
condition:
  - "{{ trigger.from_state.state not in ('unknown', 'unavailable') }}"
action:
  - service: notify.mobile_app_sm_g981b
    data:
      message: Waschmaschine fertig
      title: Waschmaschine
mode: single

That’s correctly formatted — I’ll be interested to know if it solves your problem.

@Troon Thank you very much. No further false triggering has been generated since I inserted the line of code!