From 7e48b82b22078b3c09ae20a0baa6492bbb58469b Mon Sep 17 00:00:00 2001 From: Claudius Magicus Date: Fri, 7 Aug 2026 16:02:34 +0200 Subject: [PATCH] fix: repair IndentationError in claude_agent_pipe.py import block The rate-limit-surfacing feature (RateLimitEvent handling) added in ee6fc4c/4387685 left a stray leading space on the claude_agent_sdk import block, causing a module-level IndentationError that broke the whole pipe. Also cleans up two orphaned whitespace-only lines left between the RateLimitEvent and ResultMessage branches. --- claude_agent_pipe.py | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) diff --git a/claude_agent_pipe.py b/claude_agent_pipe.py index 7fc4019..426466c 100644 --- a/claude_agent_pipe.py +++ b/claude_agent_pipe.py @@ -44,20 +44,20 @@ _ARTIFACT_EXTENSIONS = _IMAGE_EXTENSIONS | _DOWNLOAD_EXTENSIONS # when large — this is only a "don't accidentally ship a DVD ISO" guard. _MAX_ARTIFACT_BYTES = 50 * 1024 * 1024 # 50 MiB - from claude_agent_sdk import ( - AssistantMessage, - ClaudeAgentOptions, - ClaudeSDKClient, - RateLimitEvent, - ResultMessage, - StreamEvent, - SystemMessage, - ToolResultBlock, - ToolUseBlock, - UserMessage, - create_sdk_mcp_server, - tool, - ) +from claude_agent_sdk import ( + AssistantMessage, + ClaudeAgentOptions, + ClaudeSDKClient, + RateLimitEvent, + ResultMessage, + StreamEvent, + SystemMessage, + ToolResultBlock, + ToolUseBlock, + UserMessage, + create_sdk_mcp_server, + tool, +) log = logging.getLogger(__name__) @@ -1724,8 +1724,7 @@ class Pipe: if info.status in ("allowed_warning", "rejected"): yield f"\n\n_{line}_\n" continue - - + if isinstance(message, ResultMessage): await emit_status("Done.", done=True) for chunk in _inline_new_artifacts(