Private
Public Access
0
0

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.
This commit is contained in:
2026-06-19 17:38:23 -04:00
parent b72f291cf3
commit a4b966c327
+1 -1
View File
@@ -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]]: