Cursor can't build/open dev container

Describe the Bug

I have a development environment that uses dev containers. This works totally fine in vscode, but ever since the cursor 1.2 update I’ve been having lots of issues with them.

Whenever I open the folder now and choose ‘reopen in dev container’ I am now getting the following error:
"Failed to read devcontainer config Unexpected token ‘A’, "Agent pid “… is not valid JSON”

The same project works flawlessly in vscode.
Rebuilding the project also doesn’t work

I am running the dev containers via WSL2

Steps to Reproduce

  • Open a folder with a dev container environment setup
  • Command pallette > ‘Reopen in container’

Operating System

Windows 10/11

Current Cursor Version (Menu → About Cursor → Copy)

Version: 1.2.4 (user setup)
VSCode Version: 1.99.3
Commit: a8e95743c5268be73767c46944a71f4465d05c90
Date: 2025-07-10T17:09:01.383Z
Electron: 34.5.1
Chromium: 132.0.6834.210
Node.js: 20.19.0
V8: 13.2.152.41-electron.0
OS: Windows_NT x64 10.0.26100

Additional Information

2025-07-11 10:32:53.036 [info] Searching for devcontainer.json files
2025-07-11 10:32:53.111 [info] Found 1 devcontainer.json files: \home<redacted>.devcontainer\devcontainer.json
2025-07-11 10:32:53.111 [info] Reading devcontainer config with command: read-configuration --workspace-folder /home/ --config /home//.devcontainer/devcontainer.json
2025-07-11 10:32:53.114 [info] Running devcontainer CLI command: /tmp/devcontainer-cli-914248bc-3843-4d1e-8ca3-c1d86f915a83/cli/dist/spec-node/devContainersSpecCLI.js read-configuration --workspace-folder /home/–config /home//.devcontainer/devcontainer.json --docker-path docker
2025-07-11 10:32:53.114 [info] [read-configuration]: Running command: node
2025-07-11 10:32:53.183 [info] [read-configuration][stderr]: your 131072x1 screen size is bogus. expect trouble
2025-07-11 10:32:53.183 [info] [read-configuration][stderr]: your 131072x1 screen size is bogus. expect trouble
2025-07-11 10:32:53.191 [info] [read-configuration][stderr]: Identity added: /home//.ssh/id_ed25519 (@)
2025-07-11 10:32:53.299 [info] [read-configuration][stderr]: [2025-07-11T08:32:53.316Z] @devcontainers/cli 0.75.0. Node.js v20.18.2. linux 5.15.153.1-microsoft-standard-WSL2 x64.
2025-07-11 10:32:53.355 [info] [read-configuration]: Command completed with exit code 0
2025-07-11 10:32:53.355 [error] Failed to read devcontainer config Unexpected token ‘A’, "Agent pid "… is not valid JSON
2025-07-11 10:32:53.355 [error] Failed to reopen folder in container Failed to read devcontainer configuration

Does this stop you from using Cursor

Yes - Cursor is unusable

2 Likes

me too

Hi @Elwin and @Li_Jingyuan, could you upgrade to version 1.0.6 of the Anysphere Remote WSL extension?

We changed how we establish the connection to support SSH_AUTH_SOCK forwarding into the container in 1.0.5, but that got tripped up by the output from starting the SSH agent. Version 1.0.6 should ignore this output so it can establish the connection.

I can now build and run my containers again after updating :slight_smile:

I still have this issue with version 1.0.7

Hi @jongon, could you share your logs from the “Remote - Dev Containers” output window so we can take a closer look? Thanks!

I’m not getting so much information i think.

I’m using Windows 11 and WSL2

Hi @jongon , could you double check which version of the Remote WSL extension you’re using? If you’re using the VSCode extension, could you switch to the Anysphere Remote WSL extension? Our dev containers extension is not compatible with the VSCode WSL extension.

I currently have the anysphere extensions. I did a clean instalation, removed cursor-server directory and still have the issue


Reverting Dev Containers to 1.0.13 made things start working again.

How lucky you are @chocoelho. It didn’t work for me :frowning:

This topic was automatically closed 22 days after the last reply. New replies are no longer allowed.