Skip to content

fix(core): wiring_summary reports EDA event listeners (v26.06.09)#35

Merged
ancongui merged 1 commit into
mainfrom
fix/wiring-summary-eda-listeners
Jun 5, 2026
Merged

fix(core): wiring_summary reports EDA event listeners (v26.06.09)#35
ancongui merged 1 commit into
mainfrom
fix/wiring-summary-eda-listeners

Conversation

@ancongui
Copy link
Copy Markdown
Contributor

@ancongui ancongui commented Jun 5, 2026

Summary

The startup wiring_summary log (PyFlyApplication) surfaced event_listeners (@app_event_listener), message_listeners, cqrs_handlers, scheduled_tasks, async_methods, and post_processors — but omitted EDA @event_listener subscriptions, which _wire_event_listeners tracks under event_listeners_eda. So a service that wired EDA listeners saw them reported as absent in the summary — misleading when using the summary to diagnose noop-wiring (as debugging-async-services recommends).

The EDA listeners were correctly subscribed and dispatched (verified end-to-end during the implement-eda skill validation) — only the summary line under-reported them. The skill and the eda/messaging runtime were already correct; this is purely a startup-log accuracy fix.

Fix

Extracted the summary-field assembly into a pure, testable helper pyfly.core.application._wiring_summary_fields(wiring) and added event_listeners_eda. No behavioural change to event subscription or dispatch.

Tests

  • tests/core/test_wiring_summary.py — asserts the summary surfaces event_listeners_eda, maps scheduledscheduled_tasks, and includes every advertised counter (defaulting to 0).
  • tests/context/test_wiring.py::TestEdaEventListenerWiring — wires a real EDA @event_listener (memory provider) and asserts wiring_counts["event_listeners_eda"] >= 1.

Gates

mypy --strict (607 files) ✓ · ruff ✓ · full suite 3630 passed, 1 skipped.

Bumps v26.06.08 → v26.06.09 (pyproject / __init__ / README), CHANGELOG entry, uv.lock synced.

…ump v26.06.09

The startup bean/wiring summary logged event_listeners (@app_event_listener),
message_listeners, cqrs_handlers, scheduled_tasks, async_methods, post_processors
— but omitted EDA @event_listener subscriptions (tracked as event_listeners_eda),
so wired EDA listeners showed as absent in the summary (misleading when using it
to diagnose noop-wiring). Extracted _wiring_summary_fields() and added
event_listeners_eda. EDA subscription/dispatch unchanged. Regression tests:
tests/core/test_wiring_summary.py + an EDA-listener wiring test in
tests/context/test_wiring.py.

Found while validating implement-eda (skill + eda/messaging runtime already
correct). Gates: mypy --strict (607), ruff, full suite 3630 passed.
@ancongui ancongui merged commit ce46f13 into main Jun 5, 2026
5 checks passed
@ancongui ancongui deleted the fix/wiring-summary-eda-listeners branch June 5, 2026 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant