File tree Expand file tree Collapse file tree
src/seclab_taskflow_agent Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -160,9 +160,6 @@ def main(
160160 ),
161161 debug = debug ,
162162 )
163- # Force-exit on success to prevent asyncio event loop spin on
164- # dangling connections/tasks that survive cleanup.
165- os ._exit (0 )
166163 except KeyboardInterrupt :
167164 typer .echo ("\n Interrupted." , err = True )
168165 raise typer .Exit (code = 130 )
Original file line number Diff line number Diff line change @@ -771,3 +771,8 @@ async def _deploy(ra: dict, pp: str) -> bool:
771771 if session is not None and not session .error :
772772 session .mark_finished ()
773773 await render_model_output (f"** 🤖✅ Session { session .session_id } completed\n " )
774+
775+ # Force-exit: asyncio.run() cleanup spins on dangling tasks/connections
776+ # from the responses API path. Exit here before the event loop hangs.
777+ import os
778+ os ._exit (0 )
You can’t perform that action at this time.
0 commit comments