OS: Linux (Mint linux xfce), kernel 5.15.0-140-generic)
Cursor Version: 0.50.4
AppImage Launch Method: Standard AppImage execution
Issue Description
When launching Cursor on Linux, terminal functionality is severely impacted by persistent “No ptyHost heartbeat after 6 seconds” errors. These errors occur regardless of configuration tweaks, rendering the integrated terminal essentially unusable with constant freezes every 6 seconds.
Symptoms
Terminal freezes/hangs periodically with “No ptyHost heartbeat after 6 seconds” messages
Initial errors about “Unable to resolve your shell environment in a reasonable time”
Terminal becomes non-responsive after several minutes of use
Issue persists even with completely clean shell configurations
Attempted Solutions
I’ve tried literally everything short of rewriting Cursor’s source code myself:
Modified .bashrc to remove slow-loading components (conda/nvm)
Created clean minimal launcher scripts that bypass shell initialization
Set environment variables to disable shell resolution (VSCODE_SKIP_RESOLVING_SHELL_ENV=1)
Completely purged all Cursor/VSCode data directories
Launched with custom flags (--no-sandbox, --disable-gpu, etc.)
Used isolated environments with controlled environment variables
Extracted the AppImage and ran the binary directly
The Absurd Reality
It’s 2025, and somehow an Electron-based text editor still can’t reliably manage a pseudo-terminal on Linux. While VS Code handles this with ease, Cursor—based on the same codebase—somehow manages to fall over spectacularly when faced with the complex task of… running bash.
Perhaps the ptyHost is taking scheduled 6-second breaks to contemplate its existence? Maybe it’s actually working perfectly, and those “heartbeat” messages are just its way of saying “I’m still here, just choosing not to respond”?
Impact
This issue makes Cursor practically unusable for Linux developers who (shockingly) occasionally need a working terminal. The irony of an AI-powered development tool that can’t maintain basic terminal functionality isn’t lost on me.
I downloaded the oldest version of the AppImage. Does not really solve the “no ptyhost heartbeat” bug, but it makes it bearable to work on. As it only happens after 45 minutes or so, not like in the new version, whenever I would like to use the chat or the terminal, it starts.
Same here. I tried launching the AppImage with --disable-gpu but to no avail.
I suspect a graphics card issue however. Which card do you have (AMD or NVidia?)
Where did you download an older Version of the AppImage?
The bug is super annoying.
I have changed my graphics card, from Nvidia to an AMD Radeon RX 6400 (not hi-end, just working). It seems this solved my “pty-host heartbeat” issue.
I followed recommendation of chatgpt after analyzing my setup and chatgpt told me that nvidia proprietary drivers may cause the electron issues.
I still have seen one “No ptyHost heartbeat after 6 seconds” in the last 20mins but it seems to be reduced.
UPDATE: It seems I was too quick to rejoice. Same issue as before. But at least we’ve ruled out another possible source of error.
Well, I’m still experimenting. It’s irregular; sometimes I can work for 30mins without being molested, then it kills me literally.
I’m currently trying a 100% fresh install (all .cursor config backupped, .config/Cursor backupped, no extensions … actually I don’t need all that stuff) and currently it works, but I’ve seen that message of death again lurking in the logs … I’ll report
I had the same error on MacOS ARM versions 0.43.0 and on, and just today miraculously discovered something that worked for me.[1] Simply locate the file ptyHostMain.js in the application bundle and add the following line to the top:
process.on('SIGTERM', () => {});
For me, this was: /Applications/Cursor.app/Contents/Resources/app/out/vs/platform/terminal/node/ptyHostMain.js. In my case, analyzing Cursor’s logs revealed that the ptyHost process kept getting killed with code 15 (SIGTERM).
Suggested by 4o after hours of fruitless debugging with o3! ↩︎
I tried this but didn’t work for me - I replaced () => {} with (it) => {console.log(it); } to see if there’s something happening, but obviously this function never got called.
Any ideas? Do you have confirmation that this function is actually called?
When I did that, I was told that my ptyHost was dying with exit code 15 (SIGTERM) – that’s why my code above is the way it is. You and I could potentially have different errors.
Hello everyone, just wanted to let you know that the team is already investigating the issue. Hopefully, we’ll have a solution soon. If anyone else encounters related problems, feel free to share the details.
I didn’t face this problem after reinstalling version 0.48. I don’t know whether there is a difference in AI capabilities between version 0.48 and the latest version, but I decided to use version 0.48 because I feel more comfortable with it.
I think I have found a fix for the issue. I am programming in Rust, and so there is a huge “target” folder in the repository root getting updated with newly built binaries all the time. The file watcher is monitoring the folder, so Cursor must be setup to ignore the target folder file watching by adding **/target/** to the Watcher Exclude paths.