feat(notify): notify-py + _notification.py Wrapper

This commit is contained in:
2026-05-14 17:33:37 +02:00
parent 9d53ff7eee
commit 67687a9b43
3 changed files with 78 additions and 0 deletions
+19
View File
@@ -0,0 +1,19 @@
"""Desktop-Benachrichtigungen via notify-py."""
import logging
logger = logging.getLogger(__name__)
_APP_NAME = "whisper-local"
def notify(title: str, message: str) -> None:
"""Zeigt eine Desktop-Benachrichtigung. Bei Fehler wird nur geloggt."""
try:
from notifypy import Notify
n = Notify()
n.application_name = _APP_NAME
n.title = title
n.message = message
n.send()
except Exception:
logger.warning("Benachrichtigung fehlgeschlagen: %s %s", title, message)