{"id":9141,"library":"notify-py","title":"Notify-py","description":"Notify-py is a cross-platform Python library designed for sending desktop notifications on Windows, macOS, and Linux. It simplifies the process of displaying alerts, messages, and system notifications from Python scripts and applications. Currently at version 0.3.43, the library is actively maintained with frequent patch releases addressing bug fixes and minor improvements.","status":"active","version":"0.3.43","language":"en","source_language":"en","source_url":"https://github.com/ms7m/notify-py","tags":["notifications","desktop","cross-platform","gui","utility"],"install":[{"cmd":"pip install notify-py","lang":"bash","label":"Install stable version"}],"dependencies":[{"reason":"Required for internal logging; it's the primary runtime dependency.","package":"loguru","optional":false},{"reason":"Required for D-Bus communication to send notifications on Linux systems.","package":"jeepney","optional":true}],"imports":[{"symbol":"Notify","correct":"from notifypy import Notify"}],"quickstart":{"code":"from notifypy import Notify\n\nnotification = Notify()\nnotification.title = \"My Application Alert\"\nnotification.message = \"This is a test notification from notify-py!\"\n# Optional: Set an icon (path to .png) and sound (path to .wav)\n# notification.icon = \"/path/to/my_icon.png\"\n# notification.audio = \"/path/to/my_sound.wav\"\n# To prevent blocking the main thread (runs notification in background):\n# notification.send(block=False)\nnotification.send()","lang":"python","description":"This basic example demonstrates how to create a simple desktop notification with a title and message. You can optionally add an icon or a custom sound. For non-blocking behavior, set `block=False` on the `send()` method."},"warnings":[{"fix":"If passing a custom notifier object, use the new `use_custom_notifier` keyword argument. If overriding the detected platform name, continue to use `override_detected_notification_system` with a string value.","message":"The `override_detected_notification_system` keyword argument was repurposed in v0.3.0. It now accepts a custom platform name (string) instead of a custom notifier object.","severity":"breaking","affected_versions":"<0.3.0"},{"fix":"For macOS, consider bundling your application with a pre-configured notifier binary that includes your desired icon, or rely on system-default icon behavior. This is a limitation of macOS notification system integration.","message":"On macOS, custom icons cannot be set dynamically for notifications. You must bundle a customized version of the notifier with your custom icon to display it.","severity":"gotcha","affected_versions":"All versions"},{"fix":"If interactive notifications are required, an alternative library or a platform-specific solution that allows for user interaction will be necessary. Notify-py is designed only for displaying messages.","message":"Notify-py notifications are purely informational and do not support interactive elements like buttons or custom actions.","severity":"gotcha","affected_versions":"All versions"},{"fix":"Initialize the `Notify` object with `enable_logging=True`: `notification = Notify(enable_logging=True)`.","message":"Logging within `notify-py` is disabled by default to minimize output. If you need to see internal library logs (e.g., for debugging), it must be explicitly enabled.","severity":"gotcha","affected_versions":"0.2.2 and later"}],"env_vars":null,"last_verified":"2026-04-16T00:00:00.000Z","next_check":"2026-07-15T00:00:00.000Z","problems":[{"fix":"Upgrade `notify-py` to version `0.3.43` or newer using `pip install --upgrade notify-py`.","cause":"This error occurred on Windows 11 with Python 3.12 in `notify-py` versions prior to `0.3.43` due to an incompatibility with the Windows notification backend.","error":"notifypy.exceptions.UnsupportedPlatform: This version of Windows (11) is not supported."},{"fix":"Use the correct keyword argument `use_custom_notifier` when passing a custom notifier object. The `override_detected_notification_system` argument should now be used to pass a string representing a custom platform name.","cause":"Attempting to pass a custom notifier object using the `override_detected_notification_system` keyword argument in versions 0.3.0 or later, after the argument was repurposed.","error":"TypeError: Notify.__init__() got an unexpected keyword argument 'override_detected_notification_system'"},{"fix":"To enable logging for debugging or verbose output, initialize the `Notify` object with `enable_logging=True`, like `notification = Notify(enable_logging=True)`.","cause":"By default, `notify-py` disables its internal logging to prevent excessive output, especially in production environments.","error":"No logging messages from notify-py are appearing in console or logs."}]}