--- id: pydispatcher version: "2.0.7" license: BSD license_treatment: permissive maintenance: dormant --- # PyDispatcher — Multi-producer multi-consumer in-memory signal dispatch system License: permissive · Maintenance: dormant · Downloads: 3.4M/mo ## What it is and what it does PyDispatcher is a lightweight in-memory signal-dispatch library that decouples event producers from event consumers through a registration and routing mechanism. You register callback functions to listen for signals identified by a key and sender, then dispatch signals from anywhere in your code; all registered listeners for that signal-sender pair are invoked with the event data. The library originated as a Python Cookbook recipe and is now used as the foundation for signal systems in other frameworks. It has no runtime dependencies and installs cleanly. However, the project is dormant—the last release was 2023-02-17 and the last commit was 2024-05-15—so it receives no active maintenance or new features, though the core mechanism is stable. Use it for: - Decouple application components by having them communicate via signals rather than direct function calls or imports. - Build event-driven architectures where multiple handlers need to react to the same application event. - Implement plugin systems where plugins register callbacks for application lifecycle or data events. - Create observer patterns in frameworks to notify multiple listeners when underlying data changes. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. PyDispatcher implements a signal-dispatch system where multiple producers can send signals that multiple consumers listen for and handle via registered callbacks. Yes, if you need a lightweight, zero-dependency signal-dispatch mechanism and accept that the project is no longer actively maintained. The code is stable and battle-tested, making it suitable for production use in applications that don't require ongoing updates. Avoid it if you need active maintenance, bug fixes, or support for the latest Python features. ## Install pip install pydispatcher uv add pydispatcher poetry add pydispatcher ## Installing PyDispatcher Before you install: Installation is straightforward with no runtime dependencies. The package is dormant—last release was 2023-02-17 and last commit 2024-05-15—so expect no active maintenance or bug fixes, though the codebase is stable enough for production use in established projects. License in practice: BSD license is permissive, allowing commercial and private use with minimal restrictions; you may use and modify freely provided you retain the license notice. Quickstart: pip install PyDispatcher from pydispatcher import dispatcher def callback(event=None): print("Signal received", event) metaKey = "moo" MyNode = object() dispatcher.connect(callback, sender=MyNode, signal=metaKey) dispatcher.send(metaKey, MyNode, event={"sample": "event"}) Verify before relying: - Whether the package works reliably with modern Python versions beyond those listed in classifiers (Python 2 and 3 are noted but no specific versions given). - Performance characteristics under high-volume signal dispatch or with many registered callbacks. - Current stability and reliability in production systems given dormant maintenance status. ## Package facts - License: BSD (permissive) - Python support: unspecified - Install friction: low - Maintenance: dormant - Downloads: 3.4M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags signal dispatch system, event observer pattern, multi-producer multi-consumer, callback registration, in-memory event routing, publish subscribe pattern, signal sender receiver, event-driven, observer-pattern, decoupling [View on SkillFed](https://skillfed.io/packages/pydispatcher) · [View on PyPI](https://pypi.org/project/pydispatcher/)