Confused about Conditions (was: Rule has 2 false conditions, but still runs?)

Evening all,

This problem has caused me to pull back some automation as it's too unstable for my wife... so I need to isolate this.

My wife wakes at an hour of the morning WAY earlier than I do, so I wanted to use a motion sensor to see the motion and turn lights on. Now this is pointing towards an active hallway so enlisted some logic to minimize it running freely.

My house has 3 active modes. OVERNIGHT, DAY, EVENING. Evening is after sunset to midnight, Overnight midnight to sunrise, and Day is sunrise to sunset.

Rules are created as 5.1.
The motion is read as active, then the conditions require the lights to already be off, and be either Overnight, or Day. After being paused all day I have resumed now to do some testing and low and behold it's triggering the action (wrong mode, and the lights were previously on)

Any thoughts what I should be looking at to isolate the problem here?

1 Like

Can you post a screenshot of the Triggers and Required Expression for the rule? The screen before the Actions which you have already posted.

1 Like

This is the main page, which is what I believe you are looking for. There are 2 motion sensors in play (motion test has been hidden by my wife so not relevant), it was Motion - Kitchen I walked in front of to trigger.


This is a common misunderstanding of the "Manage Conditions" section. This is seen as a listing of the conditions that have been created as part of the rule. It does not guarantee that they are used in any way. For them to be used, you would have some kind of conditional action (IF-THEN-ELSE) or a Required Expression.

In your case, I suspect you would want this Expression to be a Required Expression, though a conditional action would work just as well... With the IF-THEN surrounding the turning on of the lights.... If that makes sense....


Your action here of "On: early morning" looks like a switch and not a mode. What is "early morning" doing?

You are mistaken about the conditions - those don't actually do anything until you use them elsewhere in the rule.

Just to make this very clear - this is what triggers your rule:

What you see below is a list of conditions you can use in expressions and such, but aren't being used based upon your screenshots. The text above the box is important.

As @sburke781 suggests, one way to accomplish this is to turn on Use Required Expression and then select these conditions when filling it out.


I wish the box said "Manage Available Conditions" - it might make this more obvious.



Thanks everyone, will be tonight's project to explore further.. I really appreciate the assistance.


On early morning as a scene that was created within an app I can't remember off hand. It's setting my dimmers to a specific predetermined level.

1 Like

Tonight I will rewrite the trigger to include all the information,but then need to ask what is the purpose of conditions?

Conditions in that bottom section are just a "pool" of things. You can select from that pool of conditions, or not. You can select multiple time from that pool, which sometimes helps to speed up writing a rule.

Those conditions must be applied to your rule. You can't just have conditions hanging out there and expect they will do something.

Maybe a bad example, but you have a kid and you put these conditions.

  • No dessert
  • No toys

That doesn't tell the kid anything, and wouldn't necessarily be correct either.

You apply those conditions to a rule.

  • No dessert before dinner.
  • No toys if you misbehave in the supermarket.

A condition can be used as a further discriminator to determine if an action should be run. Here's an example of how motion triggers a rule but the light won't turn on unless the School Day switch is on. If it's off, the light won't turn on.

You'll see here how the defined conditional action is actually used in the rule.

In Manage Conditions "School Day is on" does nothing until I included it in the IF (School Day is on) THEN conditional action.


I think this is answered, but not "what is the purpose of the 'Manage Conditions' box" which is probably another question to answer along with all this.

The purpose is to allow you to edit conditions without editing the rule actions themselves.

Using @pseudonym's example...let's say you want to change 'School Day is on' to 'Weekday is on'. If you edit the action, then your only option is to delete the condition of 'School Day is on' and create a new condition for 'Weekday is On.'

Alternatively, you can use the 'Manage Conditions' box to edit the 'School Day is on' condition to 'Weekday is on' and it will automagically be update in the actions.


Thanks everyone, I have added logic to the conditions, to me conditions mean something different, but it makes more sense now. This was my first real attempt at a real automation, rather than simple 1:1 action is what I mean. I have reactivated this again and the real test will come what happens tomorrow morning.

Conditions = These things must be true before any triggers will be acted upon.
Triggers = Any of these being true will cause the Actions to be executed.

1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.