Skip to content

🌟 The Multi-Agent Framework: First AI Software Company, Towards Natural Language Programming

terminal async reporter

shenchucheng5a1387499128
diff --git a/metagpt/tools/libs/terminal.py b/metagpt/tools/libs/terminal.py
index 8d44c13e6..c2010ed6f 100644
--- a/metagpt/tools/libs/terminal.py
+++ b/metagpt/tools/libs/terminal.py
@@ -123,12 +123,12 @@ class Terminal:
if ix >= 0:
line = line[0:ix]
if line:
- observer.report(line, "output")
+ await observer.async_report(line, "output")
# report stdout in real-time
cmd_output.append(line)
return "".join(cmd_output)
# log stdout in real-time
- observer.report(line, "output")
+ await observer.async_report(line, "output")
cmd_output.append(line)
if daemon:
await self.stdout_queue.put(line)