Help needed for waking lights!

Hi everyone!

I tried to adapt Leonardo’s fade light script to use my lights to wake me up in the morning (They don’t seem to be compatible with the light transition feature.

Here’s what I came up with:

#wake up lights

wake_lights:

  alias: Wake Lights

  fields:

    light:

      description: Waking with the lights

      example: toutes_les_lumieres

  sequence:

    - variables:

        light.entity: light.{{ light }}

    - service: input_number.set_value

      entity_id: input_number.brightness_level

      data:

        value: 0

    - repeat:

        while:

          - condition: numeric_state

            entity_id: input_number.brightness_level

            below: 255

        sequence:

          - service: light.turn_on

            target:

              entity_id: "{{ light_entity  }}"

            data:

              brightness: "{{ states('input_number.brightness_level')|int }}"

          - delay:

              hours: 0

              minutes: 0

              seconds: 1

              milliseconds: 0

          - service: input_number.increment

            entity_id: input_number.brightness_level

Sooooo when I run it nothing happens and I have no idea why. Could anyone help me to get it working?

Thanks!