Repository navigation
Tag snooze matches the automation or script that sent the notification - #270
Merged
Merged
Conversation
The sender is the automation or script whose state carries the call's context (or its parent, for a script started by an automation). Looked up only while a tag snooze is active, once per notification. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01DUP2qytcsLgRptSv1oR6TY
lollox80
added a commit
to lollox80/supernotify-cards
that referenced
this pull request
Oct 7, 2026
archive 0.40.0: pause_sender: true offers the sender (from the logbook) next to the entity, so almost every notification can be paused. Needs SuperNotify with rhizomatics/supernotify#270 (off by default). Fix: a pause made during a read of the pauses showed as not made until the next read. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01DUP2qytcsLgRptSv1oR6TY
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A
TAGsnooze now also matches the automation or script that sent the notification, by itsentity_id, object_id, friendly name or alias, the same way it already matches theentity_idin the data or the camera.Why
I wanted to pause one noisy notification for an hour, e.g. a thermostat going offline and back online every few minutes. The tag snooze already does this, but only for calls that pass
entity_idin their data. In my archive that is 7 of the last 100 notifications. All 100 came from an automation or script, and the sender was identifiable in every case. With this change, pause garage closed for an hour works for any notification raised byautomation.garage_closed(by voice, AI tool,supernotify.snoozewithscope: tag, or a mobile action), with nothing added to the notify call.How
HomeAssistantAPI.sender_entity_ids(context): theautomation.*/script.*states whose context is the call's context or its parent. An automation writes its state with the context of the run it starts, and that run's actions carry the same context. A script started by an automation has it as parent, so both count.Notification.snooze_tags()adds the senders. They are looked up only when a tag snooze is active (Snoozer.has_tag_snooze()), and once per notification, because a later run of the same automation changes the context its state carries.usage/snoozing.md) and CHANGELOG under Unreleased.No new config, no change for anyone without a tag snooze.
Tests
test_tag_snooze_matches_the_sending_automation: snoozed by the automation's entity_id; another automation's notification and one without context still go out.test_tag_snooze_matches_a_script_started_by_an_automation: the script's run has the automation as parent; snoozed by the script's friendly name; both are senders.CI replica: py3.14 / HA 2026.9.3: 2345 passed, coverage 97%; ruff, format, codespell, mypy clean on both lanes. py3.13 / HA 2026.2.3: 2305 passed; the same 3 missing-action tests fail as on main at 3628dda (the lane issue #266 addresses).
Related to the tag design in #254: this gives every automation-raised notification a tag without a new top-level key.
🤖 Generated with Claude Code
https://claude.ai/code/session_01DUP2qytcsLgRptSv1oR6TY