EPIPE: broken pipe
Claude Code wrote to a pipe whose reader had already gone away.
57 issues · 2 open · 55 resolved (96%) · first seen Feb 24, 2025
First response · local
What to do now
Most likely: The operating system rejected a file or directory operation.
- Read the first path in the error and verify that it exists and belongs to the expected user.
- Check disk space, permissions, symlinks and whether another process holds the target.
- Reproduce with the smallest affected path before changing project-wide permissions.
These are conservative triage steps, not an official Anthropic fix. Use the issue and workaround evidence below before making a destructive configuration change.
Is this getting better or worse?
This class of problem is converging. 3 new reports in the last 90 days vs 8 in the 90 before — -62%. The open backlog peaked at 4 in 2025-07 and sits at 2 today.
Derived by counting each matching issue from its creation date until it closed. First-party
computation over the anthropics/claude-code tracker — the trend is not published
anywhere upstream.
Which builds report this
10 of these reports name the Claude Code build they were running, spanning 10 releases. Heaviest reporters:
- Claude Code v2.1.226
- Claude Code v2.1.128
- Claude Code v2.1.142
- Claude Code v2.1.87
- Claude Code v2.1.78
- Claude Code v2.1.45
- Claude Code v2.1.39
- Claude Code v2.1.37
Report volume, not a defect count: an issue can mention a build without that build having caused the failure. Versions come from the version string in the bug-report template, matched against real published tags.
Do these get fixed?
Median time to close is 3 days across 55 closures. Of the 55 closures with a recorded reason, 36% were closed as completed and 35 as not-planned or duplicate. The most recent completed fix landed in 2026-08.
Workarounds reported by the community
11 of these issues post a workaround someone says worked. The highest-engagement ones:
- Node.js EPIPE Error on Bash Command Execution
- …ng to 1.0.54 seems fine. For other suffering the pain (temp workaround):
Found in the thread of #3881 · resolved - Unhandled EPIPE Error Causing Node.js Application Crash
- …bove - crashes during operation with work in progress lost. Temporary fix applied: Following the suggestion in this thread, I've disabled PostToolUse hooks in and will test if this resolves the issue. Status: Testing the…
Found in the thread of #2834 · resolved - [BUG] Cowork on macOS 1.8555.2 — zero MCP tools bind in any install path (.mcpb + SDK bridge + Custom Connectors + project .mcp.json); spawn pipeline missing --mcp-config since 2026-05-23 auto-update
- Update — workaround validated empirically, regression boundary confirmed Following up after running the same-machine, same-config A/B comparison to nail down whether 1.8555.2 is genuinely the regression point. Method - O…
Found in the thread of #62072 · still open - Error: write EPIPE
- Found the a workaround: Seems caused because I'm using FISH, which the isn't supported?
Found in the thread of #47 · resolved - EPIPE Crash When Running Claude Code in Python Project Directory
- …adding some logic to fix the case that is addressed by the workaround I posted. For the folks who need to run sudo, I'm adding some logging that hopefully help us track this down. On Tue, Feb 25, 2025 at 1:52 PM Darin @…
Found in the thread of #31 · resolved
Excerpts are quoted from the linked issue so you can judge relevance before opening it. Threads that only ask for a workaround, or report that there is none, are excluded. These are community suggestions, not official guidance from Anthropic — read the full thread before applying one.
Matching issues 1–57
Ranked by community engagement (reactions weighted over comments).
- Node.js EPIPE Error on Bash Command Execution
- Unhandled EPIPE Error Causing Node.js Application Crash
- "Error: write EPIPE" error During Bash Command Execution
- Unhandled EPIPE Error in Node.js Socket Write Operation
- [BUG] Connection-level errors (ECONNRESET, EPIPE, ETIMEDOUT) are never retried — immediate failure with zero recovery
- [BUG] Cowork on macOS 1.8555.2 — zero MCP tools bind in any install path (.mcpb + SDK bridge + Custom Connectors + project .mcp.json); spawn pipeline missing --mcp-config since 2026-05-23 auto-update
- Error: write EPIPE
- EPIPE Crash When Running Claude Code in Python Project Directory
- Unhandled EPIPE Error Causing Node.js Process Crash
- [BUG]
- Unhandled EPIPE Error in Socket Write Operation
- [BUG] node:events:496 throw er; // Unhandled 'error' event ^ Error: write EPIPE
- [Bug] Unhandled Promise Rejection in Async Functions 2.1.1
- [BUG] Claude code is crashing
- Unhandled EPIPE Error Causing CLI Crash During Task Execution
- Unhandled EPIPE Socket Error in Node.js Stream
- [Feature] OnApiRetry hook event for observability and control over internal retry behavior
- telegram plugin: infinite CPU loop on EPIPE (broken pipe causes uncaughtException storm)
- [BUG] Error: write EPIPE
- Claude Code cant run because it cant auto-update
- EPIPE Error When Running /clear Command in Ghostty Terminal
- Claude Desktop: Local Claude Code sessions crash immediately with exit code 1 (429 on OAuth endpoint)
- Unhandled EPIPE Error in Node.js Socket Stream
- Error: write EPIPE
- 100% CPU spin after terminal disconnect - stdio revocation not handled
- Unhandled EPIPE Error in Node.js Stream Processing
- Unhandled EPIPE Error in Node.js Socket Write Operation
- Bug: `tengu_disable_keepalive_on_econnreset` heuristic never triggers on Bun's native fetch errors
- Bug: ECONNRESET ('terminated') during streaming with partial data kills the session — no retry, no fallback
- Unhandled EPIPE Error in Socket Write Operation
- [BUG] Excessive settings.json file I/O (1000x/sec) after tool calls causes performance degradation in WSL
- [BUG] Claude Code CLI crashes with unhandled EPIPE error during normal usage
- [BUG] Windows 11 + WSL2 + Debian: can no longer run 'bash' commands with output (?)
- Intermittent Claude Code CLI Startup Failure This sounds like a potential issue with the Claude Code CLI where: 1. The tool becomes non-functional in specific project directories 2. Restarting or changing directories temporarily resolves the issue 3. The
- [Bug] claude CLI silently exits on transient network errors during tool-use turns (no retry, no backoff)
- [Bug] Continuous EPIPE errors preventing API communication
- [Windows] Bash tool: MSYS2 builtins and POSIX-compiled binaries cannot write to stdout; native Windows exes work fine
- [BUG] Native binary REPL immediately exits on Terminus SSH terminal (SIGPIPE/EPIPE on stdout)
- [BUG] EPIPE when LSP crashes during startup
- [BUG] Claude code Error: write EPIPE in visual studio code
- [BUG] Claude Desktop no expone herramientas MCP aunque el servidor las registra correctamente
- [BUG] Log stream error: bufio.Scanner: token too long
- GitHub CLI Interaction Fails with EPIPE Write Error
- NPM Installation Failure: EPIPE Socket Write Error
- [BUG] Claude Code leaves the chat
- Claude issue in Bedrock
- [chrome-native-host] Unhandled EPIPE error on browser close crashes native host process
- [BUG] LSP servers shut down on session resume but never restarted
- [BUG] crash on grep
- [BUG] claude crashes when wanting sudo after start
- EPIPE Error in Websocket Connection Handling
- [BUG] Claude Cowork keeps crashing
- Getting errno: -32, code: 'EPIPE', syscall: 'write' when using Opus 4
- Unhandled EPIPE Error Causing Command Execution Failures
- Unhandled EPIPE Error in Node.js Socket Write Operation
- Unhandled EPIPE Error in Node.js Socket Write Operation
- Killed sandboxed command leaks its SOCKS socket; main thread then spins on EPIPE at 100%+ CPU