[BUG] Multiple critical issues on Windows - Claude Code 2.1.5

Resolved 💬 5 comments Opened Jan 12, 2026 by Sixwatch1 Closed Feb 26, 2026

Preflight Checklist

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

What's Wrong?

Multiple critical issues affecting Windows reliability:

  1. Temp file pollution: Task agents create tmpclaude-XXXX-cwd files in the current working directory instead of system %TEMP%. Files are never deleted after agent completes. A single session created 30+ orphan files in my repo.
  1. Cannot kill Task agents: No mechanism to terminate a running Task agent. KillShell returns "Task is not a local bash task". Only way to stop a runaway agent is closing the entire terminal window.
  1. False completion status: Task agent reported "complete" but made zero file edits. TaskOutput showed success, file was unchanged. No error thrown - silent failure.
  1. Empty agent output files: Agent used 41+ tools (per progress notifications) but output file was empty. Work performed but results completely lost.
  1. Path handling inconsistencies: Bash commands fail due to Windows vs Unix path confusion. Windows type command fails, cat requires /c/ prefix path format.

What Should Happen?

  1. Temp files should be created in %TEMP% and auto-deleted when agent completes
  2. Running Task agents should be killable via KillShell or similar mechanism
  3. Task completion status should reflect actual work done - failures should throw errors
  4. Agent output should be reliably captured in output files
  5. Path handling should work consistently on Windows

Error Messages/Logs

KillShell attempt:
  "Task a5a453f is not a local bash task"
  Bash path error:
  "/usr/bin/bash: line 1: type: C:\Users\...\tasks\a5a453f.output: not found"

  Temp files found (example):
  tmpclaude-2bc8-cwd (13 bytes, contains: /c/momaitest)
  tmpclaude-03f2-cwd
  tmpclaude-4a32-cwd
  [...30+ more]

Steps to Reproduce

  1. Open Claude Code in a project directory on Windows
  2. Spawn a Task agent: "Task an agent to read and summarize files in this directory"
  3. Observe tmpclaude-XXXX-cwd file created in project root
  4. Wait for agent to complete
  5. Check: temp file still exists, never cleaned up
  6. Spawn another Task agent
  7. Attempt to kill it with KillShell while running
  8. Observe: "Task is not a local bash task" error - cannot kill
  9. Check agent output file after completion - may be empty despite tool usage

Claude Model

Opus

Is this a regression?

I don't know

Last Working Version

2.15

Claude Code Version

2.15 (Claude Code)

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

PowerShell

Additional Information

These issues compound to make Windows usage unreliable. The combination of:

  • Agents that can't be stopped
  • Temp files polluting the repo
  • Silent failures with false success status
  • Lost output despite work being done

...makes Task agents essentially unusable on Windows for production work.

The temp file naming pattern tmpclaude-XXXX-cwd suggests these are meant to track working directories for agents, but they're being written to cwd instead of a temp location and cleanup never happens.

View original on GitHub ↗

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