mirror of
https://github.com/invariantlabs-ai/invariant-gateway.git
synced 2026-10-08 05:41:08 +02:00
line logging
This commit is contained in:
1 parent
9fc384d629
commit
c2e9745163
1 file changed
+3
@@ -396,6 +396,7 @@ def stream_and_forward_stdout(mcp_process: subprocess.Popen, ctx: McpContext) ->
|
||||
line_str = line.decode(UTF_8_ENCODING).strip()
|
||||
if not line_str:
|
||||
continue
|
||||
mcp_log(f"[INFO] Received line: {line_str}")
|
||||
|
||||
parsed_json = json.loads(line_str)
|
||||
processed_json = hook_tool_result(ctx, parsed_json)
|
||||
@@ -435,6 +436,8 @@ def run_stdio_input_loop(ctx: McpContext, mcp_process: subprocess.Popen) -> None
|
||||
if not line:
|
||||
break
|
||||
|
||||
mcp_log(f"[INFO] Received line: {line}")
|
||||
|
||||
# Try to decode and parse as JSON to check for tool calls
|
||||
try:
|
||||
text = line.decode(UTF_8_ENCODING)
|
||||
|
||||
Reference in new issue
Block a user