I struggle to get this transition that I have set up in a script to work. I want to turn a light off slowly over an hour or two. Here is the config I am using:
turn_off_jamess_light:
alias: Turn Off James's Light
sequence:
- service: light.turn_off
data:
transition: 3600
target:
entity_id: light.jamess_fan
mode: single
icon: mdi:lightbulb-auto-outline
However, when I run this script, the light turns off immediately. I have tried calling the light.turn_off service with that transition in the Dev tools. The dimming works fine at that point. I’m not sure what is different between the two and how to get it to work in the script properly. Here is the YAML that I use in Dev tools:
service: light.turn_off
data:
transition: 3600
target:
entity_id: light.jamess_fan
Hellis81
(Hellis81)
May 3, 2022, 5:54pm
2
You use entity in one and device in the other.
Try using the entity in the script
My automation transitions broke after one of the April updates. I’m using only entity_id
alias: 'Timed Lights: Hallway'
description: ''
trigger:
- platform: sun
event: sunset
offset: '-00:50:00'
condition: []
action:
- service: scene.turn_on
target:
entity_id:
- scene.hallway_full_bright
data:
transition: 7
mode: single
I updated it, so it uses entity id for both examples, but it doesn’t make a difference. When the transition is in the script, it doesn’t work.
pedolsky
(Pedolsky)
May 4, 2022, 7:57am
5
Maybe a bug. It works with core-2022.5.0bx.
Looking forward to the release then!
Hm no, my lights turn on instantly still even after update, ignoring the 7 second transition I set
pedolsky
(Pedolsky)
May 5, 2022, 4:41am
8
What light bulbs are you using?
Hue bulbs, they support transitions and were successfully doing them just a few weeks ago
pedolsky
(Pedolsky)
May 5, 2022, 5:15am
10
Me too. My test automation works as expected:
alias: test transition
description: ''
trigger:
- platform: state
entity_id:
- input_boolean.test
to: 'on'
condition: []
action:
- service: scene.turn_on
data:
transition: 7
target:
entity_id: scene.wohnzimmer_lesen
mode: single
What does the debug trace say?
kaandorp
(Michael Kaandorp)
May 5, 2022, 7:54am
11
I’m having the exact same experience. I see more and more of these questions popping up, so I guess it’s just a bug. I will file a bug report for this. I can’t get transition to work even in the dev tools.
pedolsky
(Pedolsky)
May 5, 2022, 7:58am
12
I’m running Supervised. And you?
kaandorp
(Michael Kaandorp)
May 5, 2022, 11:26am
13
Same… I see a recent bug report: Scene change ignores transition time · Issue #12540 · home-assistant/frontend · GitHub
But this is focussing on the scene. And I actually think it’s in the Hue integration.
pedolsky
(Pedolsky)
May 5, 2022, 3:24pm
14
Ok… I don’t get it. It’s working flawlessly for me. Thought that custom scenes that were created in the scene editor could cause the problem, so I created one, but this works, too.
kaandorp
(Michael Kaandorp)
May 8, 2022, 10:00am
15
Try to also provide a brightness. It seems that the brightness is needed for the transition to work. Also see my bug report:
opened 08:16AM - 06 May 22 UTC
integration: hue
### The problem
When I use a transition time to turn a Hue light on the transit… ion time is ignored. When turn_off is used with transition the last brightness state is set to 1% as well. So, basically there are two scenarios:
1. The Hue light is on 100% brightness. I use the service light.turn_off with a transition of 10s to turn it off. This is done correct. If I then use the light.turn_on with 10 sec transition it only turns on to 1% brightness.
2. The Hue light is on 100% brightness. I manually turn it off. I use the service light.turn_on with a transition of 10s to turn it on. The transition is ignored and the light goes to 100% instantly.
I have checked this with two friends and both have the exact same result.
### What version of Home Assistant Core has the issue?
2022.5
### What was the last working version of Home Assistant Core?
_No response_
### What type of installation are you running?
Home Assistant OS
### Integration causing the issue
Philips Hue
### Link to integration documentation on our website
https://www.home-assistant.io/integrations/hue/
### Diagnostics information
[config_entry-hue-66b28efd405047a19a96041f5c7c3a4c.json.txt](https://github.com/home-assistant/core/files/8638550/config_entry-hue-66b28efd405047a19a96041f5c7c3a4c.json.txt)
### Example YAML snippet
```yaml
service: light.turn_on
data:
transition: 10
target:
entity_id: light.play_kantoor
```
### Anything in the logs that might be useful for us?
_No response_
### Additional information
_No response_
pedolsky
(Pedolsky)
May 8, 2022, 3:19pm
16
Okay! Now I see the problem. Thanks for the raised issue.
I do have the brightness defined in my scene and it still fails to do the transition