From 82335331487c97f81f6a513eec2d72658f2d9945 Mon Sep 17 00:00:00 2001 From: Lina Tawfik Date: Mon, 30 Jun 2025 23:00:54 -0700 Subject: [PATCH] Add comment explaining JSON buffer accumulation logic --- src/claude_code_sdk/_internal/transport/subprocess_cli.py | 1 + 1 file changed, 1 insertion(+) diff --git a/src/claude_code_sdk/_internal/transport/subprocess_cli.py b/src/claude_code_sdk/_internal/transport/subprocess_cli.py index 982a85a..288b2e7 100644 --- a/src/claude_code_sdk/_internal/transport/subprocess_cli.py +++ b/src/claude_code_sdk/_internal/transport/subprocess_cli.py @@ -199,6 +199,7 @@ class SubprocessCLITransport(Transport): if not json_line: continue + # Keep accumulating partial JSON until we can parse it json_buffer += json_line if len(json_buffer) > _MAX_BUFFER_SIZE: