mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-07-10 01:15:11 +00:00
Bugbot flagged that flow paths went straight from the memory drain to `FlowFinishedEvent`, while crew kickoff flushes the bus in between. Save completion events emitted during the drain could still have pending async handlers when flow-finished triggered trace teardown. Adds a `crewai_event_bus.flush()` after the drain at both flow runtime emit sites and in `finalize_session_traces`, mirroring `Crew._create_crew_output`.