Cursor AI Agent Gets Stuck in Diagnostic Loop Instead of Completing Tasks

Hey, thanks for the detailed report. I can see the screenshot with the “Diagnosing…” and “Investigating what’s blocking progress” loop.

There are two related issues here:

  1. The terminal gets stuck on interactive prompts. When the agent runs gh auth login, git push over HTTPS, or anything that needs an SSH passphrase, the command waits for user input that the agent can’t provide. The terminal tool never returns a result and hangs.

  2. Self-diagnostic loop. When tool calls in a row don’t return a result, the model starts “investigating” its own stuck state, like scanning files or reading .cursor/settings.json, instead of aborting. This is known behavior on our side, and we don’t have an ETA for a fix yet.

Workaround for your case, pushing to GitHub:

  • Set up gh auth login ahead of time in a normal terminal, not via the agent, then check gh auth status
  • Or set up an SSH key with no passphrase, or add it to ssh-agent, and use an SSH remote instead of HTTPS
  • For large workspaces with .venv or node_modules, add them to .cursorignore to avoid bloating indexing

After auth is set up, retry the same task. The agent should be able to push without getting blocked.

This symptom is tracked in the canonical thread, you can subscribe for updates: My chats are just hanging with "Planning next moves" and "Taking longer than expected..."