I created a simple Notifier app to send out text messages and emails (using Twilio and Sendgrid) if it detects water from leak sensors. I want it to send the notification immediately and then do it again in 5 minutes if the state hasn't changed (from wet to dry). I tested it and it is sending a bunch of notifications immediately (4 of them in just a few seconds).
As a developer, I should have thought of that. Yeah that's what happening. 4 wet -> dry events occurred at the same time. So the device is reporting as dry again for some reason and then right back to wet a few seconds later.
If that's the case, I guess there's no way to use Notifier since none of the restrictions would prevent that from happening. If it resets to dry, and then throws another wet event, Notifier is going to kick in every time.
I've paused the Notifier for now and created a HSM app instead. Looks like custom monitoring rules to be configured for water sensors, wet state, only notify once every [x] minutes. I'll do some testing, but hopefully that takes care of this.
These are ThirdReality Zigbee sensors. They are actually really nice and work well. I'm going to do some testing to see if this happens again and/or if it's the result of partial contacts being wet.
Another option you have is to 'debounce' the sensor. See this app in our public repo, which would be easy to modify for a water sensor being debounced instead of a contact sensor.
Circling back on this... Looks like the multiple events from wet/dry was a fluke or the water test I was using wasn't touching all the way. I just tried it again and it did not throw multiple events. I sat it in a really small puddle of water that only touched 2 of the 3 contacts. It thew one event (to "wet") and stayed in wet status until I removed it about 8 minutes later. I tried it again, and the same thing. So I think my original test was a fluke where I was dripping a little water nearby and the contact wasn't strong or consistent enough to stay in wet status.
Circling back on this yet again... I switched back to the Notifier app. HSM doesn't appear to actually fire every [x] minutes as it first appears. Looks like the "how many times per hour" setting is just a global variable that stops it from being activated again. Once armed, HSM does not come out of arming or send any additional alerts, so that's a dead end. But Notifier does work well (and does repeat correctly) assuming your device isn't going on and off over and over.