"Any Value" Trigger Removed?

Long ago, I created a rule that triggered on a device attribute of "pushed" for a virtual button.

It was set to trigger on "any value" so that I could use the button on dashboards with any number of different values to trigger different things (in this case, it was a "snooze" button that triggered different minutes of snoozing, based on the button number).

When I just looked, I didn't see the "any value" as an option (and it broke the trigger that I previously set).

Is this a trigger event that has gone away?

(my workaround for that was to trigger on ">=0" - I was just wondering what happened).

I looked as far back as Rule 5.0 and don't see this on custom "pushed" triggers or the actual Button trigger. But if this what you want, "changed" should do it. Of course, the workaround you found should too, given that it will always be true of button events.

I'd probably use Button Controller for this since you're doing different actions based on the button number, but the above should work if that approach bothers you for some reason.

Thx

Changed might not be reliable, in that pushing the button with the same number wouldn't change it (e.g., snoozing for 10 min a second time)

But,>=0 seems to work in this case

This is not true. It looks for any event marked as a "state change." For many events, that is a new/different value, but button events typically force this (since you need an event even if the old number is the same as the new one). I would not have suggested this otherwise.

It's also easy to test. Here is an example rule and the complete rule and device event logs for two "button 1 pushed" events in a row:

image

4 Likes