fix(test): Resolve visual orchestration test and prepare hook env injection
This commit is contained in:
@@ -79,7 +79,14 @@ class GeminiCliAdapter:
|
||||
# Use communicate to avoid pipe deadlocks with large input/output.
|
||||
# This blocks until the process exits, so we lose real-time streaming,
|
||||
# but it's much more robust. We then simulate streaming by processing the output.
|
||||
stdout_final, stderr_final = process.communicate(input=prompt_text)
|
||||
try:
|
||||
stdout_final, stderr_final = process.communicate(input=prompt_text, timeout=60.0)
|
||||
except subprocess.TimeoutExpired:
|
||||
process.kill()
|
||||
stdout_final, stderr_final = process.communicate()
|
||||
stderr_final += "\n\n[ERROR] Gemini CLI subprocess timed out after 60 seconds."
|
||||
# Mock a JSON error result to bubble up
|
||||
stdout_final += '\n{"type": "result", "status": "error", "error": "subprocess timeout"}\n'
|
||||
|
||||
for line in stdout_final.splitlines():
|
||||
line = line.strip()
|
||||
|
||||
Reference in New Issue
Block a user