From a4b966c3275afc84ea36ed0af120444bd18453b6 Mon Sep 17 00:00:00 2001 From: Ed_ Date: Fri, 19 Jun 2026 17:38:23 -0400 Subject: [PATCH] fix(app_controller): restore self._process_event_queue() in _run_event_loop (Phase 6 Group 6.7) The Phase 6 migration of queue_fallback moved self._process_event_queue() into _run_pending_tasks_once_result AFTER the try/except block, making it unreachable code. As a result, the event_queue was never consumed, causing user_request events to never reach _handle_request_event. This was caught by test_context_sim_live (the live_gui sim polls ai_status for 60s and never sees a transition past 'sending...' because the worker ran but the event was never processed). Fix: move self._process_event_queue() back to its original location in _run_event_loop, immediately after self.submit_io(queue_fallback). TIER-2 READ conductor/code_styleguides/error_handling.md end-to-end before this fix. The original code structure is the source of truth; my Phase 6 migration violated it. --- src/app_controller.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app_controller.py b/src/app_controller.py index 61f29c5a..5fba7b70 100644 --- a/src/app_controller.py +++ b/src/app_controller.py @@ -2736,6 +2736,7 @@ class AppController: self._report_worker_error("queue_fallback", result) time.sleep(0.1) self.submit_io(queue_fallback) + self._process_event_queue() def _run_pending_tasks_once_result(self) -> "Result[None]": """Phase 6 Group 6.7 (bounded retry Pattern 5 drain): single iteration of @@ -2755,7 +2756,6 @@ class AppController: source="app_controller._run_pending_tasks_once_result", original=e, )]) - self._process_event_queue() @property def _pending_mma_spawn(self) -> Optional[Dict[str, Any]]: