Chat stalls on "Taking longer than expected...", integrated terminal stucks and agent endlessly waiting for the command result

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

This is when using remote SSH connection.
During the Agent answer it gets very often stuck while waiting for the issued command result.
It detects the problem and tries to execute some dummy commands like ‘echo ok’, ‘date’ etc. After 5-10-20 minutes it may finally receive a response and say “Ok, the server is back” and will continue its work.

During this terminal tab may (or may not) be also unresponsive. But my local terminal connection with LXterminal keeps working with no issues.

Second problem is usually nearly every second answer gets stalled with message “Taking longer than expected…”.

Despite this on Cursor’s account Usage tab it still takes 1 credit while showing no tokens were used for these unresponsive answers.

What helps is to restart window/extensions host for several times.

Last week on 2.4.3 version it was working on but today it started like this, upgrade to 2.5.20 didn’t help. In Network settings I have HTTP/1.1 and diagnostics are all fine.

PS. When I try to resubmit the stalled answer, I need to wait for about 30 seconds (!) till “Submit from a previous message?” popup will appear. Despite taking this long to wait, obviously no changes were made to any of the files as there was even no response. After resubmitting it will start with “Planning next moves” and will then turn into “Taking longer than expected…” forcing me to restart window.

PS2. During these “echo ok” commands, when I click on “Open in external terminal” button, it seems to be actually receiving the ok response (first time still with like 10 seconds delay) but likely not capturing straight away.

Steps to Reproduce

Open Cursor IDE and ask agent to perform a task which uses cli commands.

Expected Behavior

Commands executed fast and next questions answered.

Screenshots / Screen Recordings

Operating System

Linux

Version Information

IDE 2.5.20

For AI issues: which model did you use?

Opus 4.6

Does this stop you from using Cursor

Sometimes - I can sometimes use Cursor

Hey, thanks for the report.

A couple things stand out:

  • remote extension-host is using 24% CPU and 299 MB. That’s pretty high if the screenshot was taken while idle (not during active agent work). This could mean some extension on the remote side is using resources and might be interfering with the terminal.
  • ptyHost on the remote side looks fine (0% CPU, 38 MB), so the terminal process itself doesn’t look like the bottleneck.

To narrow this down:

  1. Was the screenshot taken during one of the “freezes”, or when everything was working normally? This really changes how we read the data.

  2. Enable Extension Monitor to see which extension is causing that 24% CPU on the remote side:

    • Settings > Application > Experimental > Extension Monitor Enabled
    • Then Ctrl+Shift+P > “Developer: Open Extension Monitor”
    • Share a screenshot of the results (ideally during a freeze)
  3. Quick test: try starting a session with extensions disabled:

    cursor --disable-extensions
    

    Connect over SSH and try to reproduce the issue. If the freezes go away, an extension is the likely cause.

  4. Request ID from one of the “Taking longer than expected” messages. Chat menu (top right) > Copy Request ID.

Also, which SSH extension are you using?