Events
Bringing the elegance of C# EventHandler to Python
Install
events on PyPI
pip
pip install eventsuv
uv add eventspoetry
poetry add eventsPackage facts
| License | BSD (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | abandoned — 1,109 days since the last release |
| Last repo commit | |
| First released | |
| Popularity | one of the top 1,000 most-downloaded packages on PyPI (30-day window, as of 2026-08-13) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-13) |
Evidence: Events-0.5-py3-none-any.whl
About Events
from the package's own PyPI description — quoted content, verbatim
Events
The C# language provides a handy way to declare, subscribe to and fire events. Technically, an event is a "slot" where callback functions (event handlers) can be attached to - a process referred to as subscribing to an event. Here is a handy package that encapsulates the core to event subscription and event firing and feels like a "natural" part of the language.
::
>>> def something_changed(reason):
... print "something changed because %s" % reason
>>> from events import Events
>>> events = Events()
>>> events.on_change += something_changed
Multiple callback functions can subscribe to the same event. When the event is fired, all attached event handlers are invoked in sequence. To fire the event, perform a call on the slot:
::
>>> events.on_change('it had to happen')
'something changed because it had to happen'
By default, Events does not check if an event can be subscribed to and fired. You can predefine events by subclassing Events and listing them. Attempts to subscribe to or fire an undefined event will raise an EventsException.
::
>>> class MyEvents(Events):
... __events__ = ('on_this', 'on_that', )...
Read as markdown · JSON record · Source repository · Homepage
AI interpretation — verify before relying
AI-generated interpretation of the package facts above; every digit, version, license, or vulnerability id it cites is grounded in the facts already shown on this page
Events provides a publish-subscribe pattern for Python, letting you attach callback functions to named events and fire them to notify all subscribers—similar to C# event handlers.
Installation is frictionless with low friction and no runtime dependencies, but the package has been abandoned since its last release on 2023-07-31, with no maintenance activity.
BSD license permits commercial and private use with minimal restrictions, requiring only license and copyright notice retention.
Usage
pip install events
from events import Events
events = Events()
events.on_change += lambda reason: print(f'Changed: {reason}')
events.on_change('test')
Verdict: Events is a lightweight, dependency-free event dispatcher suitable for simple pub-sub patterns, but its abandoned status and Beta development classification mean it carries maintenance risk. No known vulnerabilities exist, and the permissive BSD license poses no legal barrier.
Needs verification
- Whether the package remains compatible with Python 3.9+ despite classifiers only listing up to 3.8
- Whether memory leaks from held references (mentioned in docs) have been addressed or remain a known issue
- Current community adoption and whether alternatives have superseded this package
Similar packages
permissive · top 1,000 on PyPI
zope.eventunclear · top 1,000 on PyPI
aiosignalpermissive · top 100 on PyPI
debugpypermissive · top 1,000 on PyPI
jupyter-eventspermissive · top 1,000 on PyPI
blinkerpermissive · top 1,000 on PyPI
realtimepermissive · top 1,000 on PyPI
more-itertoolspermissive · top 1,000 on PyPI
amqppermissive · top 1,000 on PyPI
gcloud-aio-bigquerypermissive · top 1,000 on PyPI