tmpclaude-*-cwd temporary files not cleaned up on Windows

Resolved 💬 3 comments Opened Jan 16, 2026 by Dev-Technizer-Edge Closed Jan 20, 2026

Description

Temporary files with the pattern tmpclaude-XXXX-cwd are being created in the working directory when using Claude Code, but they are not automatically cleaned up on Windows.

Environment

  • OS: Windows
  • Claude Code: Latest version (as of January 2026)

Steps to Reproduce

  1. Use Claude Code in a project directory on Windows
  2. Trigger subagent/Task tool usage (e.g., codebase exploration)
  3. Observe tmpclaude-*-cwd files created in the working directory
  4. Files persist after the session ends

Expected Behavior

Temporary files should be automatically cleaned up after the subagent process completes.

Actual Behavior

Files remain in the working directory and accumulate over multiple sessions. Example:

tmpclaude-427a-cwd
tmpclaude-4872-cwd
tmpclaude-d947-cwd
... (20+ files)

Workaround

Add tmpclaude-* to .gitignore and manually delete with rm -f tmpclaude-*

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗