claude-code - 💡(How to fix) Fix [BUG] Write/Edit tools hang for 10-20 minutes (infinetely before stoped manually) before returning result

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Error Message

Error Messages/Logs

Code Example

No errors and claude can't understand what is really going on. Not understand when he freezed.
RAW_BUFFERClick to expand / collapse

Preflight Checklist

  • I have searched existing issues and this hasn't been reported yet
  • This is a single bug report (please file separate reports for different bugs)
  • I am using the latest version of Claude Code

What's Wrong?

Claude Code version: 2.1.146
Platform: Linux 6.1.0-39-amd64 (Debian Bookworm)
Shell: bash / fish


Description

The Write and Edit built-in tools frequently hang for 10–20 minutes before i stoped it and
returning control to the conversation. The hang is not deterministic — it
affects files of any size (including small config files < 1 KB) and occurs across different directories and project types. After escaping it show diff instantly.


Observed behavior

  • The file is written successfully to disk (confirmed: canceling after the hang shows the correct diff of changes)
  • The hang occurs after the file write completes — the tool does not return its result to the conversation for an extended period
  • Bash tool with explicit timeout: 600000 works reliably; the issue is specific to Write/Edit built-in tools which have no timeout parameter
  • No git lock files present (.git/*.lock checked)
  • No other processes holding open file descriptors on the target directory
    (verified with lsof +D <dir>)
  • No Docker containers running during the hang
  • The issue was present before any third-party plugins (e.g. oh-my-claudecode) were installed, ruling out hook-related causes

What Should Happen?

Write/Edit tools should return immediately after the file is written to disk, consistent with the behavior of Bash tool operations.

Error Messages/Logs

No errors and claude can't understand what is really going on. Not understand when he freezed.

Steps to Reproduce

  1. Use Claude Code in a standard Linux terminal session
  2. Ask Claude to write or edit any file using the built-in Write or Edit tool
  3. Observe that the tool appears to freeze after the file is written to disk
  4. After 10–20 minutes the operation unblocks when user manually
    cancels via double ESC

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

No response

Claude Code Version

2.1.146

Platform

Anthropic API

Operating System

Ubuntu/Debian Linux

Terminal/Shell

Other

Additional Information

  • Terminal is terminator
  • The pattern is: tool executes → file written → hang → manually unblocks when user cancels → diff shown confirming write succeeded
  • The hang duration is variable: observed between 5 and 20 minutes
  • Reproducible on a plain ext4 filesystem, no NFS or network mounts involved
  • System load during hang is minimal (no heavy I/O or CPU activity)

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix [BUG] Write/Edit tools hang for 10-20 minutes (infinetely before stoped manually) before returning result