Devcontainer builds are failing due to what looks like an incorrect reference to download VS Code Server. Here is a section of log from an attempt to build a new vanilla devcontainer on a remote machine:
[14181 ms] Start: Downloading VS Code Server
[14183 ms] 769e57fc532d17f247b121cdf4b6c37f1cccb540 linux-x64 stable
[15150 ms] Failed to download VS Code Server (https://update.code.visualstudio.com/commit:769e57fc532d17f247b121cdf4b6c37f1cccb540/server-linux-x64/stable): HTTP 404 - Not Found
[15151 ms] Retrying to download VS Code Server.
And here is a similar excerpt for a failed attempt to build a vanilla container on using a local Docker host:
[24662 ms] Exit code 1
[24663 ms] Installing VS Code Server for commit 769e57fc532d17f247b121cdf4b6c37f1cccb540
[24665 ms] Start: Run in container: /bin/sh
[24671 ms] Start: Downloading VS Code Server
[24671 ms] 769e57fc532d17f247b121cdf4b6c37f1cccb540 linux-x64 stable
[25585 ms] Failed to download VS Code Server (https://update.code.visualstudio.com/commit:769e57fc532d17f247b121cdf4b6c37f1cccb540/server-linux-x64/stable): HTTP 404 - Not Found
[25585 ms] Retrying to download VS Code Server.
[25754 ms] Start: Run: docker rm -f 93a5a5b7acf35e74a1e77842c29dc86333bc235e0dbd30b6bef08ed36510c9b8
[25806 ms] Error: Server returned 404
at g (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:844:30682)
at e.DownloadService.download (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:845:1567)
I have the same issue. Digged a bit into it, it seems that the Docker extension is using the IDE commit hash to identify which version of vscode server to install on the devcontainer, but because cursor is a fork of vscode, it has its own git tree, thus a different commit hash than vscode.
Devcontainers are currently not supported in Cursor. Hopefully soon! In the meantime, in case anyone is interested in building an open-source devcontainer extension, this and this repo may be useful as inspiration
Just created a forum account to say pretty much the same. I was really interested in Cursor and I would happily pay if it supported Devcontainers. That’s because it is my only use of Vs Code and it is increasing by the day. I appreciate it may be a smaller user group, but my Cursor story ended when I realised it did not support Devcontainers. Just saying.
Thanks. This is good news I think: there is hope!
I have a .devcontainer folder with my own setup, which I’m unfortunately not able to share. I downloaded Cursor yesterday (though it tells me there is an update when I fired it up just now) .
When I repeat the same steps I follow with vanilla Vs Code, I get an error. Steps:
Ssh to remote machine (Ubuntu 20.04.6 LTS, Docker version 25.0.0-beta.1, build 2b521e4)
Open the repo folder with .devcontainer folder in it
Vs code (Cursor) suggests opening it in Devcontainer, or I invoke the Reopen in devcontainer command
Everything works as it should with Vs Code.
With Cursor, my IDE window’s bottom bar says: disconnected from devcontainer and my explorer side bar has the repo folder’s name with an exclamation mark next to it. The error is:
The editor could not be opened due to an unexpected error: Unable to resolve resource vscode-remote://dev-container%2B7b22686f737450617468223a222f746d702f74656d702d637572736f722d7473742f646f746e65742d7265706f2d74656d706c617465222c226c6f63616c446f636b6572223a66616c73652c2273657474696e6773223a7b22686f7374223a227373…02f74656d702d637572736f722d7473742f646f746e65742d7265706f2d74656d706c6174652f2e646576636f6e7461696e65722f646576636f6e7461696e65722e6a736f6e222c22736368656d65223a227673636f64652d66696c65486f7374227d7d@ssh-remote%2<DOMAIN NAME OF MY MACHINE GOES HERE>/workspaces/<REPO FOLDER'S NAME GOES HERE>
The error displayed when I hover over the folder name in the sidebar is slightly more informative, I could not find a way to copy that so I typed it:
Unable to resolve workspace folder (ENOPRO: No file system provider found for resource `<THE ABOVE vscode-remote URL GOES HERE>`)
I can try with a sample devcontainer repo from Microsoft later, but this is currently my situation.
The results are the same. I get disconnected from the devcontainer and docker ps on the server confirms that the container does not start. This is the latest version of Cursor, which I’ve just updated minutes ago. This behaviour should be reproducable. Can you or someone else just use that reference repo to open it in a devcontainer? Is it working for anyone?
[2024-07-05T07:02:48.948Z] Failed to download VS Code Server (https://cursor.blob.core.windows.net/remote-releases/5f9353ed8be369c4ac2b4d43596f5ff281746ec0/vscode-reh-linux-alpine.tar.gz): HTTP 404 - The specified blob does not exist.
[2024-07-05T07:02:48.948Z] Retrying to download VS Code Server.
[2024-07-05T07:02:49.564Z] Stop (1217 ms): Downloading VS Code Server
[2024-07-05T07:02:49.571Z] Error: Server returned 404
at u (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:1187:29331)
at S.download (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:1188:1737)
updated 0.36.0(brew install --cask cursor), same issue founds.
[2024-07-05T07:20:29.658Z] Failed to download VS Code Server (https://cursor.blob.core.windows.net/remote-releases/a915e3254b1192ce240c078da83fc1768a6e3e90/vscode-reh-linux-alpine.tar.gz): HTTP 404 - The specified blob does not exist.
[2024-07-05T07:20:29.659Z] Retrying to download VS Code Server.
[2024-07-05T07:20:30.335Z] Stop (1356 ms): Downloading VS Code Server
[2024-07-05T07:20:30.342Z] Error: Server returned 404
at h (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:1187:29331)
at S.download (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:1188:1737)
removed 0.36.0, and install from official installer(0.35.1), same issue founds…
Not ideal, but I got my cursor running on WSL2 by deleting ~/.vscode and then opening my target folder in VSCode to download the server again. Then opening the WSL2 workspace in cursor prompted the download (yet) again which worked.