… I need to be very diligent about dismissing each notification as it comes in…
Regarding the above statement: I’ve experienced the same issue but I don’t believe the issue source is because you didn’t dismiss a notification. i.e. I’ve had this issue where I got the com.dd.doordash response with not text but then another notification comes in and it displays just fine. Please note I haven’t dismissed or even read any notifications on my phone.
I haven’t been successful in tracking this issue down. Things I’ve noticed:
The missing data message shows fine on the phone.
For me, when this occurred the space between previous and next messages are in “minutes”. No insta-double notification.
Only started happening “recently” for me. Unfortunately i don’t know what revision of HA it was working properly versus not.
what about the rest of attributes? That notification may use a different API for showing the text in the title or elsewhere.
please keep in mind that Doordash app updates can also impact the data the sensor gets, best to look at all attributes to see what data is coming into the app.
For me, it is only the second notification that is messed up.
The first comes in fine.
The second comes in as com.dd.doordash.
And the third and subsequent ones are fine.
So, if I always dismiss the first one after it comes in, everything works.
If I forget to dismiss, then the second one is bad, but if I continue to forget to dismiss, then it works fine again when the third (and later) ones come in, … until I dismiss them all again.
Ok found what’s happening: So I was able to see in the Trace for my trigger that it changes state to the below. You’ll notice it’s missing a bunch of android.xxx attributes. I’m grabbing state, even though I know there are things like big text, sub text, etc. but this event for some reason is missing all informational attributes? This particular notification shows in the app fine.
thats because its a grouped notification which was the last item to post to the devices status bar. Thats how the sensor works it listens to updates to when things are added to the status bar and sends those updates. When a notification becomes grouped it has different data. The active notification sensor should contain data for all notifications posted to the status bar including all grouped items. It has a lot of attributes and are therefore not stored in the db.
So what then is the recommendation? If I’m following, you’re saying the grouped notification doesn’t log the attributes but ARE there and rather read from the state I should just try to read from Bigtext for example? FYI that makes debugging difficult with inconsistencies like that.
every app is going to have different data when it posts a notification, we cant account for all of the differences. What we can do is provide all of the data we get so users can decide what is best for their situation.
no they are not there, otherwise we would have them. Remember there is a difference between the grouped notification and the individual notification items. The group is always the last item to post.
Help me understand the difference here between the grouped notifications and individual notifications relevant to the original problem statement?
i.e. there is a notification that shows on the phone with the correct text, but that same notification is captured as a “group notification” with no data. So where did the data go? I feel like I’m missing something obvious here
so your phone already has 1 notification which the sensor sent, when it gets a second one it may create a grouped notification. The sensor itself only reports whats posted to the status, so upon receiving the second notification it may group the notifications which results in an additional item being posted to the status bar. Different devices and apps do different things. A pixel device will group the notifications if not already grouped by the app after a set amount of notifications (4).
I don’t see an " active notification sensor" available my mobile device. I have “active notification count” but the only relevant sensor is “last notification” which is what I’m currently using.
I never enabled “active notification count” as I assumed it’s literally just telling me the number of active notifications, which I wouldn’t find useful.
not sure i follow…both sensors will contain the data you are looking for…last notification only contains the data of the last posted notification.
I know what last notification does, that’s the sensor I’m currently using in my automations but that’s where, per my previous posts, I’m getting the notification with a state of “com.dd.doordash” rather than the expected text which is shown on the phone.
The logic for the state of the sensor is as follows: if text is not present go for notification title, if title is not present then use the package name because every notification has a package name
Ok so let me see if I’m following correctly. Based on what you just described, in context to the original problem statement:
The last notification sensor doesn’t contain the updated text I’m expecting because the specific notification that came through is an update to a grouped notification?
But that extra data I’m expecting does exist in the “active notification count” sensor (which is NOT an intuitive name by the way ) however I’d now have to build logic to parse through that now as well?
Oh for last notification I’m using the allow list. I only allow UberEats and Doordash. I also just read that the active notification count doesn’t have an allow list