Nordpool price sensor indicator to smart lamp

Hi, I’m trying to make an automation which indicates every hour price to smart lamp from Nordpool sensor. By now when automation fires it just exits to finish state. All actions state untrue, why? What I would need to do to fix this?

alias: Energy Price Indicator (nordpool)
description: >-
  Indicates daily energy price status with variable energy seller (not transfer)
  tariff price.
triggers:
  - entity_id:
      - sensor.nordpool_energyprices
    below: 0.1
    id: energy.trigger.price1
    trigger: numeric_state
    attribute: prices
  - entity_id:
      - sensor.nordpool_energyprices
    above: 0.1
    id: energy.trigger.price2
    trigger: numeric_state
    attribute: prices
  - entity_id:
      - sensor.nordpool_energyprices
    above: 0.12
    id: energy.trigger.price3
    trigger: numeric_state
    attribute: prices
  - entity_id:
      - sensor.nordpool_energyprices
    above: 0.14
    id: energy.trigger.price4
    trigger: numeric_state
    attribute: prices
  - entity_id:
      - sensor.nordpool_energyprices
    above: 0.16
    id: energy.trigger.price5
    trigger: numeric_state
    attribute: prices
  - entity_id:
      - sensor.nordpool_energyprices
    above: 0.2
    id: energy.trigger.price6
    trigger: numeric_state
    attribute: prices
conditions: []
actions:
  - choose:
      - conditions:
          - condition: trigger
            id:
              - energy.trigger.price1
        sequence:
          - action: light.turn_on
            metadata: {}
            data:
              rgb_color:
                - 0
                - 0
                - 255
              brightness_pct: 1
            target:
              entity_id: light.energy_smart_led_g45_400lm_cct_rgb_none
      - conditions:
          - condition: trigger
            id:
              - energy.trigger.price2
        sequence:
          - action: light.turn_on
            metadata: {}
            data:
              rgb_color:
                - 0
                - 255
                - 128
              brightness_pct: 1
            target:
              entity_id: light.energy_smart_led_g45_400lm_cct_rgb_none
      - conditions:
          - condition: trigger
            id:
              - energy.trigger.price3
        sequence:
          - action: light.turn_on
            metadata: {}
            data:
              rgb_color:
                - 0
                - 128
                - 0
              brightness_pct: 1
            target:
              entity_id: light.energy_smart_led_g45_400lm_cct_rgb_none
      - conditions:
          - condition: trigger
            id:
              - energy.trigger.price4
        sequence:
          - action: light.turn_on
            metadata: {}
            data:
              rgb_color:
                - 255
                - 255
                - 0
              brightness_pct: 1
            target:
              entity_id: light.energy_smart_led_g45_400lm_cct_rgb_none
      - conditions:
          - condition: trigger
            id:
              - energy.trigger.price5
        sequence:
          - action: light.turn_on
            metadata: {}
            data:
              rgb_color:
                - 255
                - 133
                - 74
              brightness_pct: 1
            target:
              entity_id: light.energy_smart_led_g45_400lm_cct_rgb_none
      - conditions:
          - condition: trigger
            id:
              - energy.trigger.price6
        sequence:
          - action: light.turn_on
            metadata: {}
            data:
              rgb_color:
                - 255
                - 0
                - 0
              brightness_pct: 1
            target:
              entity_id: light.energy_smart_led_g45_400lm_cct_rgb_none
mode: single

What does the attribute prices have?
It’s in plural but you seem to use it as singular.

Attribute prices have the actual prices prices: 0.0922, 0.0932, 0.0942, 0.0942, 0.09620000000000001, (with added additional costs, transfer’s fee + seller’s fee + margin). Sensor is actually a template helper.
I also tried without the attribute and it makes no difference, actions still read untrue.

We need to know more about the sensor to help you

Okay. Initial values are collected from sensor.nordpool_kwh_fi_eur (custom integration) and then the helper sensor.nordpool_energyprices [unit_of_measurement: EUR/kWh icon: mdi:currency-eur friendly_name: NordPool Energyprices] (template) adds up additional costs. Both sensors show correct values from developer tools section.
Are helpers usage as a triggers broken currently?

No nothing is broken.
I still don’t understand what the helper is.
Is the values in the helper a string or a list.
What value in this string/list are you supposed to trigger on?

You are right, nothing is broken. Automation triggers from below 0.10 EUR to above 0.20 EUR. It is a string list imo. But, I added additional - trigger: time_pattern hours: /1 and now the automation is working. Thanks for the support :smile: