[BUG] Agent restarts work on its own, even after interruption

Resolved 💬 4 comments Opened Apr 14, 2026 by viraptor Closed May 25, 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?

Claude Code restarts working on its own if an old process finishes work, even after manually interrupting the work. This happens even if you stopped and restarted the process in the meantime.

Here's a case where I had a process running in the background in the previous session, interrupted the model, closed the app, restarted it and just waited without any input at all:

<img width="1184" height="414" alt="Image" src="https://github.com/user-attachments/assets/00b08a17-3ec6-469e-b706-e251e6956d0d" />

What Should Happen?

App shouldn't start any work on its own, ever.
Especially when idle, since that results in extra API costs without user input.

Error Messages/Logs

Steps to Reproduce

  1. Run a prompt that will result in a long-running background process
  2. Exit cloud code
  3. Start it again and wait
  4. When the process finishes, claude will start running more prompts on its own

Claude Model

Opus

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.76

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Other

Additional Information

_No response_

View original on GitHub ↗

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