feat(sdk): add event bus for inter-addon communication (#382) #398

Merged
forbes merged 1 commits from feat/sdk-event-bus into main 2026-03-04 15:48:19 +00:00

1 Commits

Author SHA1 Message Date
forbes
54b926a925 feat(sdk): add event bus for inter-addon communication (#382)
All checks were successful
Build and Test / build (pull_request) Successful in 28m56s
New module kindred_sdk/events.py provides lightweight publish-subscribe
so addons can signal each other without direct imports.

New public API:
- sdk.on(event, handler) — subscribe to a named event
- sdk.off(event, handler) — unsubscribe
- sdk.emit(event, data) — publish event with dict payload

Pure Python, synchronous dispatch, snapshot-safe iteration.
Handlers that raise are logged and skipped without breaking the chain.
2026-03-04 09:47:43 -06:00