Internet connection issue when using Cursor

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

When I try to use Cursor, it’s showing me that it has an internet connection failure. Every command I try is showing me this message.

Steps to Reproduce

Every time I use it.

Operating System

Windows 10/11

Current Cursor Version (Menu → About Cursor → Copy)

Version: 2.2.44 (user setup)
VSCode Version: 1.105.1
Commit: 20adc1003928b0f1b99305dbaf845656ff81f5d0
Date: 2025-12-24T21:41:47.598Z
Electron: 37.7.0
Chromium: 138.0.7204.251
Node.js: 22.20.0
V8: 13.8.258.32-electron.0
OS: Windows_NT x64 10.0.26200

For AI issues: add Request ID with privacy disabled

Request ID: 9fb91f4a-d5af-4412-9d67-232dcf65d48c
ConnectError: [internal] Serialization error in aiserver.v1.StreamUnifiedChatRequestWithTools
at vscode-file://vscode-app/c:/Users//AppData/Local/Programs/cursor/resources/app/out/vs/workbench/workbench.desktop.main.js:12375:452121

Does this stop you from using Cursor

Yes - Cursor is unusable

I realized that it starts to fail after running the following command:

cd Src/.Tests; dotnet build --no-restore 2>&1 | Select-Object -First 50

Hey, thanks for the report.

This is a known bug. When a PowerShell command uses Select-Object -First N in a pipeline, it can return exit code -1, which triggers a serialization error. The team is aware of the issue.

Workaround: Avoid truncating pipelines like | Select-Object -First N. Instead, you can do this:

dotnet build --no-restore 2>&1 | Out-String | ForEach-Object { $_.Split("`n") | Select-Object -First 50 }

Or run the command without truncation, then trim the output separately afterward.

Let me know if the workaround helps!

1 Like

Thanks for replying!

How do I change the command built by Cursor and edit it?

I managed to do what you’ve mentioned. It worked like a charm.

Thank you so much!

1 Like