fix: host_silence proactive notify when event is None

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-06-11 09:26:03 +10:00
parent 37bffe0e3f
commit 3f7095ed03
3 changed files with 40 additions and 4 deletions
+9 -2
View File
@@ -114,6 +114,13 @@ def dispatch_host_silence_notifications(db: Session, results: list[HostSilenceSc
for item in results:
if not item.created:
continue
notify_problem(item.problem, event=None, db=db)
sent += 1
try:
notify_problem(item.problem, event=None, db=db)
sent += 1
except Exception:
logger.exception(
"host_silence notify failed host=%s problem_id=%s",
item.hostname,
item.problem.id,
)
return sent