From a16ed4b1ae80127f0f53821ae1a313521720a9bb Mon Sep 17 00:00:00 2001 From: Ed_ Date: Fri, 6 Mar 2026 12:05:24 -0500 Subject: [PATCH] sigh --- .gemini/skills/mma-tier2-tech-lead/SKILL.md | 4 ++-- config.toml | 2 +- src/app_controller.py | 4 +++- src/gemini_cli_adapter.py | 10 +++++++++- 4 files changed, 15 insertions(+), 5 deletions(-) diff --git a/.gemini/skills/mma-tier2-tech-lead/SKILL.md b/.gemini/skills/mma-tier2-tech-lead/SKILL.md index ad569c3..694b3da 100644 --- a/.gemini/skills/mma-tier2-tech-lead/SKILL.md +++ b/.gemini/skills/mma-tier2-tech-lead/SKILL.md @@ -7,9 +7,9 @@ description: Focused on track execution, architectural design, and implementatio You are the Tier 2 Tech Lead. Your role is to manage the implementation of tracks (`/conductor:implement`), ensure architectural integrity, and oversee the work of Tier 3 and 4 sub-agents. -## Architecture Fallback +## Architecture -When implementing tracks, consult these docs for threading, data flow, and module interactions: +YOU MUST READ THE FOLLOWING BEFORE IMPLEMENTING TRACKS: - All immediate files in ./conductor. - AST Skeleton summaries of: ./src, ./simulation, ./tests, ./scripts python files. diff --git a/config.toml b/config.toml index efe7da0..22677ac 100644 --- a/config.toml +++ b/config.toml @@ -15,7 +15,7 @@ paths = [ "C:\\projects\\manual_slop\\tests\\artifacts\\temp_livetoolssim.toml", "C:\\projects\\manual_slop\\tests\\artifacts\\temp_liveexecutionsim.toml", ] -active = "C:\\projects\\manual_slop\\tests\\artifacts\\temp_project.toml" +active = "C:\\projects\\manual_slop\\tests\\artifacts\\temp_livetoolssim.toml" [gui.show_windows] "Context Hub" = true diff --git a/src/app_controller.py b/src/app_controller.py index f10b88c..53c8cb4 100644 --- a/src/app_controller.py +++ b/src/app_controller.py @@ -851,7 +851,9 @@ class AppController: "action": "handle_ai_response", "payload": payload }) - + if self.test_hooks_enabled: + with self._api_event_queue_lock: + self._api_event_queue.append({"type": "response", "payload": payload}) def _handle_request_event(self, event: events.UserRequestEvent) -> None: """Processes a UserRequestEvent by calling the AI client.""" ai_client.current_tier = None # Ensure main discussion is untagged diff --git a/src/gemini_cli_adapter.py b/src/gemini_cli_adapter.py index c0818f1..8ec937d 100644 --- a/src/gemini_cli_adapter.py +++ b/src/gemini_cli_adapter.py @@ -88,6 +88,7 @@ class GeminiCliAdapter: # Mock a JSON error result to bubble up stdout_final += '\n{"type": "result", "status": "error", "error": "subprocess timeout"}\n' + last_decode_error = None for line in stdout_final.splitlines(): line = line.strip() if not line: continue @@ -108,6 +109,8 @@ class GeminiCliAdapter: stream_callback(content) elif msg_type == "result": self.last_usage = data.get("stats") or data.get("usage") + if data.get("status") == "error": + raise Exception(data.get("error", "Unknown CLI error")) if "session_id" in data: self.session_id = data.get("session_id") elif msg_type == "tool_use": @@ -118,10 +121,15 @@ class GeminiCliAdapter: } if tc["name"]: tool_calls.append(tc) - except json.JSONDecodeError: + except json.JSONDecodeError as e: + last_decode_error = e continue current_latency = time.time() - start_time + if process.returncode != 0 and not accumulated_text and not tool_calls: + if last_decode_error: + raise Exception(f"Gemini CLI failed (exit {process.returncode}) with JSONDecodeError: {last_decode_error}\nOutput: {stdout_final}") + raise Exception(f"Gemini CLI failed with exit {process.returncode}\nStderr: {stderr_final}") session_logger.open_session() session_logger.log_cli_call( command=command,