Failed to install Cursor server: The "path" argument must be of type string. Received undefined

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

I get “Failed to install Cursor server: The “path” argument must be of type string. Received undefined” sometimes when connecting to an SSH remote and connecting into a Docker container. It may just be connecting to SSH is enough to trigger it…

I feel like I may have seen this a while ago but it started happening a lot a few weeks ago. I’ve had to use VSCode :frowning:

Steps to Reproduce

  1. Launch a docker container on a remote.
  2. Cursor → Connect to SSH remote and connect to that remote^
  3. In that SSH-connected window, attach to container => “Failed to install Cursor server: The “path” argument must be of type string. Received undefined”

Or, when it’s working, > Developer: Reload Window can produce the same error.

Expected Behavior

Clean connection.

Operating System

Windows 10/11

Version Information

Version: 2.6.19 (user setup)
VSCode Version: 1.105.1
Commit: 224838f96445be37e3db643a163a817c15b36060
Date: 2026-03-12T04:07:27.435Z
Build Type: Stable
Release Track: Default
Electron: 39.4.0
Chromium: 142.0.7444.265
Node.js: 22.22.0
V8: 14.2.231.22-electron.0
OS: Windows_NT x64 10.0.26100

Does this stop you from using Cursor

Sometimes - I can sometimes use Cursor

Hey, this is a known bug in the Dev Containers extension when using SSH remote. The same error was reported in this thread Dev Containers: can not attach to remote container and here Remote dev for container fail to open. The issue is that the extension can’t figure out the home directory on the remote host when it tries to read .gitconfig.

A workaround that sometimes helps is to make sure the SSH remote host, not the container, has a .gitconfig and that $HOME is set correctly:

echo $HOME
ls -la ~/.gitconfig
# If the file doesn't exist:
git config --global user.name "Your Name"
git config --global user.email "[email protected]"

To be honest, for some users this workaround doesn’t help because the root issue is in the extension itself. The team is aware, but there’s no ETA for a fix yet. I passed along another signal, your report helps with prioritization.

Let me know if the workaround helped.

I have check I have valid settting in host but still fail to open the container.

same issue with devcontainers remote

I have the same issue:

2026-03-23 08:22:15.125 [error] Failed to read .gitconfig: TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined
2026-03-23 08:22:15.127 [error] Error resolving dev container authority The "path" argument must be of type string. Received undefined

Running Cursor on a Windows 11 Host. Connecting via SSH to a Ubuntu 24.04 Host which runs the devcontainer (Yocto image).
A fix would be appreciated. Visual Studio Code runs without any problems.

Interestingly enough, I got it running at one point, but I’m not sure what I did exactly. I guess something like removing .cursor and .cursor-server as well as removing all docker images etc. But then after closing Cursor and re-opening, the error came up again.

This happens to me too. The workaround doesn’t have any effect. If I spam “Reinstall Server” enough times I can usually get in. Please fix!

This is the only thing that stops me from opting for the yearly max plan - not being able to use it, as remote containers are essential for me.

I see a few more users have joined with the same issue. The bug is logged and the team is aware. Your reports help us prioritize, especially when they include specific details like @StefanW’s.

@UnluckyForSome, repeatedly clicking Reinstall Server as a temporary workaround, yeah, unfortunately that’s still the only thing that reliably works for some users. Another option is to delete .cursor-server on the remote host and try again:

rm -rf ~/.cursor-server

There’s no ETA for a fix yet, but we’re tracking it. I’ll update this thread when we have news.

Would a work around be to either automatically or after a prompt, remove .cursor-server? Or at very least to add this suggestion to that error message?

It is curious that VSCode doesn’t have this problem at all. And that only recently did cursor start presenting this behavior. Also, for me it happens less now than it did a few weeks ago. It used to fail >80% of tries. Now it fails <30% I’d guess. Weird.

Hey @BenFrantzDale good idea on both the automatic cleanup of .cursor-server and improving the error text. Right now the error message really doesn’t give any useful hints.

The fact that the frequency dropped from about 80% to about 30% is an interesting signal. Something might have improved indirectly in recent versions, even if the root bug is still there.

I’ll update the thread as soon as there’s progress.

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

When running “Reopen in container,” the connection hangs indefinitely on the loading screen and never completes.

Steps to Reproduce

  1. Open Cursor on the host machine
  2. Press Ctrl+P and run “Connect Current Window to Host” to SSH into a remote Linux machine
  3. Open a folder that contains a devcontainer configuration
  4. Run “Reopen in Container”
  5. The loading screen appears and hangs indefinitely

Expected Behavior

Cursor should successfully install the Cursor Server inside the container and attach to it, completing the Dev Container setup without hanging.

Screenshots / Screen Recordings

Operating System

Windows 10/11
Linux

Version Information

Version: 3.0.13 (user setup)
VSCode Version: 1.105.1
Commit: 48a15759f53cd5fc9b5c20936ad7d79847d914b0
Date: 2026-04-07T03:05:17.114Z
Layout: editor
Build Type: Stable
Release Track: Default
Electron: 39.8.1
Chromium: 142.0.7444.265
Node.js: 22.22.1
V8: 14.2.231.22-electron.0
OS: Windows_NT x64 10.0.22631Connecting the dev container via SSH from Windows

Additional Information

Devcontainer Extension: 1.0.32

The following errors appear in the Developer Tools console:

Failed to install Cursor server: The "path" argument must be of type string. Received undefined
ERR [LocalProcess1][resolveAuthority(dev-container,1)][3868ms] returned an error {code: 'NoResolverFound', message: 'No remote extension installed to resolve ssh-remote.'}

repeatedly running “Reload Window” via Ctrl+P may eventually allow the connection to succeed, but this is not reliable and requires multiple attempts.

Does this stop you from using Cursor

Sometimes - I can sometimes use Cursor

I have tried it again with the newest Cursor/Dev Container extension:

Version: 3.1.17 (user setup)
VSCode Version: 1.105.1
Commit: fce1e9ab7844f9ea35793da01e634aa7e50bce90
Date: 2026-04-19T19:33:58.189Z
Layout: editor
Build Type: Stable
Release Track: Default
Electron: 39.8.1
Chromium: 142.0.7444.265
Node.js: 22.22.1
V8: 14.2.231.22-electron.0
OS: Windows_NT x64 10.0.26200

The error message has changed. Now I get:

Devcontainer Log:

2026-04-21 07:54:43.510 [info] Forwarding exec server locally via tcpForward method

2026-04-21 07:54:43.510 [info] Forwarding 127.0.0.1:35593 to 127.0.0.1:0 for container 5f415da307d5ef222dff689d373e686e859cc8118f404849db7e77cb7a46dcfc

2026-04-21 07:54:43.518 [error] Failed to forward port: failed to forward port, exit code 1

2026-04-21 07:54:43.518 [info] Port forwarding attempt 1 failed, retrying in 1 second...

2026-04-21 07:54:44.524 [info] Forwarding 127.0.0.1:35593 to 127.0.0.1:0 for container 5f415da307d5ef222dff689d373e686e859cc8118f404849db7e77cb7a46dcfc

2026-04-21 07:54:44.534 [error] Failed to forward port: failed to forward port, exit code 1

2026-04-21 07:54:44.534 [info] Port forwarding attempt 2 failed, retrying in 1 second...

2026-04-21 07:54:45.539 [info] Forwarding 127.0.0.1:35593 to 127.0.0.1:0 for container 5f415da307d5ef222dff689d373e686e859cc8118f404849db7e77cb7a46dcfc

2026-04-21 07:54:45.552 [error] Failed to forward port: failed to forward port, exit code 1

2026-04-21 07:54:45.556 [error] Error resolving dev container authority Port forwarding failed after 3 attempts. Last error: Error: Failed to forward port. Error: failed to forward port, exit code 1

Anyone?

I’m getting same issue after switching from MS Remote-SSH plugin to Cursor developed one.
Have to switch to VSCode as it has more stable interface.

Issue

  1. Connect to a remote server via Remote-SSH

  2. Attach to a running container using Dev Containers: Attach to Running Container

  3. /workspace opens normally

  4. When trying to open /workspace/A as a folder

:backhand_index_pointing_right: The following issues occur:

  • Infinite Opening Remote... loading

  • Or the following error:

    Failed to install Cursor server:
    The "path" argument must be of type string. Received undefined
    
    

What I’ve tried

  • Installed Node.js inside the container

  • Removed ~/.cursor-server and reinstalled

  • Verified $HOME and .gitconfig on the SSH host

  • Restarted Cursor / Reloaded Window

  • Changed attach → open folder order

:backhand_index_pointing_right: None of these resolved the issue


Observations

  • /workspace opens without any issues

  • The problem only occurs when re-opening a subfolder (/workspace/A)

  • The same setup works fine in VS Code


Additional context

  • Based on responses from the Cursor team, this issue is acknowledged but there is currently no ETA for a fix

Questions

  1. Can you confirm if this is a known bug?

  2. Is there a stable way to directly open /workspace/A as the workspace?

  3. Is there any official workaround for this issue when changing folders after attaching to a Dev Container?

:backhand_index_pointing_right: If anyone has encountered and resolved this issue, I would greatly appreciate it if you could share your solution.


Comment

At the moment, this issue significantly disrupts the development workflow.
If this remains unresolved, it raises serious concerns about whether Cursor is usable in this setup.

The problem is that it keep crashing if you trying to use “path” reference inside your workspace, and it’s a huge deal.
I may run multiple workspaces with different paths in order to isolate agents workloads to produce and test outcomes and if my job crashed in the middle - it has two issues.

  1. I need to start work over.

  2. The number of tokens company acquired with my work was thrown into trash ( hundreds of dollars).

I’m seeing what looks like the same bug with Cursor Dev Containers over Remote SSH.

Environment:

  • Cursor client: Windows
  • Remote host: Ubuntu 24.04.4 LTS via Remote SSH
  • Remote host kernel: Linux 6.8.0-110-generic
  • Docker Engine: 29.4.1
  • Dev Containers extension: anysphere.remote-containers-1.0.32
  • Topology: Windows Cursor client → Remote SSH Linux host → Dev Container

What works:

  • Starting the devcontainer manually with the devcontainers CLI works.
  • Attaching to the already running container from Cursor works.

Example:

npx --yes @devcontainers/cli up --workspace-folder /home/khughes/shq2 --remove-existing-container

Then Cursor → Dev Containers: Attach to Running Container succeeds.

What fails:

  • Dev Containers: Rebuild and Reopen in Container
  • Dev Containers: Open Folder in Container…
  • Opening directly into the devcontainer from the Remote SSH workspace

The devcontainer initialize step completes successfully, Docker works, and the container is healthy. Cursor then fails while installing the remote server in the container.

Relevant log:

2026-04-30 00:02:01.371 [info] Resolving dev container authority ‘dev-container+…’ container ‘{“settingType”:“container”,“containerId”:“849bcc1822fa”}’
2026-04-30 00:02:01.371 [info] Using exec server from resolve options. execServerRemoteAuthority: ssh-remote+…
2026-04-30 00:02:01.467 [info] [docker info]: Command completed with exit code 0
2026-04-30 00:02:01.493 [info] [docker inspect]: Command completed with exit code 0
2026-04-30 00:02:01.539 [info] Installing remote server in container…
2026-04-30 00:02:01.539 [error] Error resolving dev container authority The “path” argument must be of type string. Received undefined

This appears to be in the Windows client → Remote SSH host → devcontainer handoff, after the container has already been created/started. It does not appear to be a Docker or devcontainer.json lifecycle failure.

Cursor config


Version: 3.2.16

VSCode Version: 1.105.1

Commit: 3e548838cf824b70851dd3ef27d0c6aae371b3f0

Date: 2026-04-28T21:07:47.682Z (1 day ago)

Layout: editor

Build Type: Stable

Release Track: Default

Electron: 39.8.1

Chromium: 142.0.7444.265

Node.js: 22.22.1

V8: 14.2.231.22-electron.0

OS: Darwin arm64 25.4.0

Cursor extensions:


$ cursor --list-extensions --show-versions

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

[email protected]

Cursor log error:


2026-04-30 12:13:25.203 [error] [Window] Extension 'anysphere.remote-ssh' appears in product.json but enables LESS API proposals than the extension wants.

It shows that the extensions has no parity with the VSCode extensions.

Assume that the usage of the following settings is also not supported by Cursor anysphere.remote-ssh extension.


"folders": [

{

"name": "user-workspace",

"path": "/home/user/user-workspace/"

}

],

Same issue here
It’s been more than a year, and still no fix
I

Hey, I know it’s frustrating to watch this thread with no fix. We’re tracking the bug on our side, but I can’t share an exact ETA yet.

If it helps, @khughes shared a working workaround here https://forum.cursor.com/t/failed-to-install-cursor-server-the-path-argument-must-be-of-type-string-received-undefined/155076/22: start the container manually with the devcontainers CLI, then connect from Cursor using Dev Containers: Attach to Running Container (this path works, unlike Reopen in Container and Open Folder in Container):

npx --yes @devcontainers/cli up --workspace-folder /path/to/your/workspace --remove-existing-container

Not perfect, but it’s more stable than spamming Reinstall Server. We’ll post an update here once the team has news on a fix.