Dev Containers: can not attach to remote container

Describe the Bug

I need to reload window multiple times each time to reconnect to the remote container.

2025-12-25 10:19:04.098 [info] No remote exec server found for authority: dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d@ssh-remote+7b22686f73744e616d65223a2234303930227d; using local
2025-12-25 10:19:12.749 [info] Resolving dev container authority 'dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d' (attempt #1) container '{"settingType":"container","containerId":"3d6e9811f6be"}'
2025-12-25 10:19:12.749 [info] Using exec server from resolve options. execServerRemoteAuthority: ssh-remote+7b22686f73744e616d65223a2234303930227d
2025-12-25 10:19:12.760 [info] Starting Dev Containers dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d
2025-12-25 10:19:12.762 [info] [docker info]: Running command: docker
2025-12-25 10:19:12.771 [info] Copying devcontainer CLI from /Users/lizhengjia/.cursor/extensions/anysphere.remote-containers-1.0.29/dist/@devcontainers to /tmp/devcontainer-cli-c1b4d31a-6c8f-4cbe-bf9e-536353ab3ecc
2025-12-25 10:19:12.804 [info] [docker info]: Command completed with exit code 0
2025-12-25 10:19:12.804 [info] docker version: Client:
 Version:    24.0.5
 Context:    default
 Debug Mode: false

Server:
 Containers: 1
  Running: 1
  Paused: 0
  Stopped: 0
 Images: 140
 Server Version: 24.0.5
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Using metacopy: false
  Native Overlay Diff: true
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: systemd
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: inactive
 Runtimes: io.containerd.runc.v2 nvidia runc
 Default Runtime: nvidia
 Init Binary: docker-init
 containerd version: 
 runc version: cb82e29c75d387992bf59eb6eadf5d96cb6d4747
 init version: 
 Security Options:
  apparmor
  seccomp
   Profile: builtin
  cgroupns
 Kernel Version: 6.8.0-49-generic
 Operating System: Ubuntu 22.04.1 LTS
 OSType: linux
 Architecture: x86_64
 CPUs: 32
 Total Memory: 62.61GiB
 Name: server-4090
 ID: 7d3cd6a6-baf5-4322-9694-270c920e1391
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 Experimental: false
 Insecure Registries:
  10.108.0.3:15080
  127.0.0.0/8
 Registry Mirrors:
  https://docker.1ms.run/
  https://hub.rat.dev/
  https://docker.1panel.live/
 Live Restore Enabled: false
2025-12-25 10:19:12.805 [info] Inspecting docker container 3d6e9811f6be (fallback name: product_i2v)
2025-12-25 10:19:12.805 [info] [docker inspect]: Running command: docker
2025-12-25 10:19:12.824 [info] Devcontainer CLI written to /tmp/devcontainer-cli-c1b4d31a-6c8f-4cbe-bf9e-536353ab3ecc
2025-12-25 10:19:12.830 [info] Copying forwarder.js to /tmp/devcontainer-cli-c1b4d31a-6c8f-4cbe-bf9e-536353ab3ecc
2025-12-25 10:19:12.841 [info] Copying devcontainerShutdownMonitor.js to /tmp/devcontainer-cli-c1b4d31a-6c8f-4cbe-bf9e-536353ab3ecc
2025-12-25 10:19:12.846 [info] [docker inspect]: Command completed with exit code 0
2025-12-25 10:19:12.848 [info] Getting config for image product_i2v:25-01-24 from vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%253A25-01-24.json
2025-12-25 10:19:12.850 [info] No container configuration file found for image vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%253A25-01-24.json Unable to read file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%3A25-01-24.json' (Error: Unable to resolve nonexistent file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%3A25-01-24.json')
2025-12-25 10:19:12.850 [info] Getting config for container product_i2v from vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json
2025-12-25 10:19:12.851 [info] No container configuration file found for container product_i2v Unable to read file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json' (Error: Unable to resolve nonexistent file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json')
2025-12-25 10:19:12.851 [info] Returning config: {}
2025-12-25 10:19:12.851 [info] Found attached container configuration: {}
2025-12-25 10:19:12.851 [info] Installing remote server in container...
2025-12-25 10:19:12.851 [error] Failed to read .gitconfig: TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined
2025-12-25 10:19:12.851 [error] Error resolving dev container authority The "path" argument must be of type string. Received undefined
2025-12-25 10:22:35.453 [info] Reloading window
2025-12-25 10:22:36.575 [info] No remote exec server found for authority: dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d@ssh-remote+7b22686f73744e616d65223a2234303930227d; using local
2025-12-25 10:22:36.927 [info] Resolving dev container authority 'dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d' (attempt #1) container '{"settingType":"container","containerId":"3d6e9811f6be"}'
2025-12-25 10:22:36.927 [info] Using exec server from resolve options. execServerRemoteAuthority: ssh-remote+7b22686f73744e616d65223a2234303930227d
2025-12-25 10:22:36.939 [info] Starting Dev Containers dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d
2025-12-25 10:22:36.943 [info] [docker info]: Running command: docker
2025-12-25 10:22:36.953 [info] Copying devcontainer CLI from /Users/lizhengjia/.cursor/extensions/anysphere.remote-containers-1.0.29/dist/@devcontainers to /tmp/devcontainer-cli-239804c9-4ae3-4a39-8438-e70bed7a4095
2025-12-25 10:22:36.998 [info] [docker info]: Command completed with exit code 0
2025-12-25 10:22:36.998 [info] docker version: Client:
 Version:    24.0.5
 Context:    default
 Debug Mode: false

Server:
 Containers: 1
  Running: 1
  Paused: 0
  Stopped: 0
 Images: 140
 Server Version: 24.0.5
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Using metacopy: false
  Native Overlay Diff: true
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: systemd
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: inactive
 Runtimes: nvidia runc io.containerd.runc.v2
 Default Runtime: nvidia
 Init Binary: docker-init
 containerd version: 
 runc version: cb82e29c75d387992bf59eb6eadf5d96cb6d4747
 init version: 
 Security Options:
  apparmor
  seccomp
   Profile: builtin
  cgroupns
 Kernel Version: 6.8.0-49-generic
 Operating System: Ubuntu 22.04.1 LTS
 OSType: linux
 Architecture: x86_64
 CPUs: 32
 Total Memory: 62.61GiB
 Name: server-4090
 ID: 7d3cd6a6-baf5-4322-9694-270c920e1391
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 Experimental: false
 Insecure Registries:
  10.108.0.3:15080
  127.0.0.0/8
 Registry Mirrors:
  https://docker.1ms.run/
  https://hub.rat.dev/
  https://docker.1panel.live/
 Live Restore Enabled: false
2025-12-25 10:22:36.998 [info] Inspecting docker container 3d6e9811f6be (fallback name: product_i2v)
2025-12-25 10:22:36.998 [info] [docker inspect]: Running command: docker
2025-12-25 10:22:37.009 [info] Devcontainer CLI written to /tmp/devcontainer-cli-239804c9-4ae3-4a39-8438-e70bed7a4095
2025-12-25 10:22:37.014 [info] Copying forwarder.js to /tmp/devcontainer-cli-239804c9-4ae3-4a39-8438-e70bed7a4095
2025-12-25 10:22:37.024 [info] Copying devcontainerShutdownMonitor.js to /tmp/devcontainer-cli-239804c9-4ae3-4a39-8438-e70bed7a4095
2025-12-25 10:22:37.028 [info] [docker inspect]: Command completed with exit code 0
2025-12-25 10:22:37.031 [info] Getting config for image product_i2v:25-01-24 from vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%253A25-01-24.json
2025-12-25 10:22:37.033 [info] No container configuration file found for image vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%253A25-01-24.json Unable to read file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%3A25-01-24.json' (Error: Unable to resolve nonexistent file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%3A25-01-24.json')
2025-12-25 10:22:37.033 [info] Getting config for container product_i2v from vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json
2025-12-25 10:22:37.034 [info] No container configuration file found for container product_i2v Unable to read file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json' (Error: Unable to resolve nonexistent file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json')
2025-12-25 10:22:37.034 [info] Returning config: {}
2025-12-25 10:22:37.034 [info] Found attached container configuration: {}
2025-12-25 10:22:37.034 [info] Installing remote server in container...
2025-12-25 10:22:37.034 [error] Failed to read .gitconfig: TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined
2025-12-25 10:22:37.034 [error] Error resolving dev container authority The "path" argument must be of type string. Received undefined
2025-12-25 10:23:04.927 [info] No remote exec server found for authority: dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d@ssh-remote+7b22686f73744e616d65223a2234303930227d; using local
2025-12-25 10:23:05.296 [info] Resolving dev container authority 'dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d' (attempt #1) container '{"settingType":"container","containerId":"3d6e9811f6be"}'
2025-12-25 10:23:05.296 [info] Using exec server from resolve options. execServerRemoteAuthority: ssh-remote+7b22686f73744e616d65223a2234303930227d
2025-12-25 10:23:05.309 [info] Starting Dev Containers dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d
2025-12-25 10:23:05.310 [info] [docker info]: Running command: docker
2025-12-25 10:23:05.320 [info] Copying devcontainer CLI from /Users/lizhengjia/.cursor/extensions/anysphere.remote-containers-1.0.29/dist/@devcontainers to /tmp/devcontainer-cli-3f114d75-3804-45d8-85af-2dfff3698853
2025-12-25 10:23:05.353 [info] [docker info]: Command completed with exit code 0
2025-12-25 10:23:05.353 [info] docker version: Client:
 Version:    24.0.5
 Context:    default
 Debug Mode: false

Server:
 Containers: 1
  Running: 1
  Paused: 0
  Stopped: 0
 Images: 140
 Server Version: 24.0.5
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Using metacopy: false
  Native Overlay Diff: true
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: systemd
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: inactive
 Runtimes: io.containerd.runc.v2 nvidia runc
 Default Runtime: nvidia
 Init Binary: docker-init
 containerd version: 
 runc version: cb82e29c75d387992bf59eb6eadf5d96cb6d4747
 init version: 
 Security Options:
  apparmor
  seccomp
   Profile: builtin
  cgroupns
 Kernel Version: 6.8.0-49-generic
 Operating System: Ubuntu 22.04.1 LTS
 OSType: linux
 Architecture: x86_64
 CPUs: 32
 Total Memory: 62.61GiB
 Name: server-4090
 ID: 7d3cd6a6-baf5-4322-9694-270c920e1391
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 Experimental: false
 Insecure Registries:
  10.108.0.3:15080
  127.0.0.0/8
 Registry Mirrors:
  https://docker.1ms.run/
  https://hub.rat.dev/
  https://docker.1panel.live/
 Live Restore Enabled: false
2025-12-25 10:23:05.354 [info] Inspecting docker container 3d6e9811f6be (fallback name: product_i2v)
2025-12-25 10:23:05.355 [info] [docker inspect]: Running command: docker
2025-12-25 10:23:05.376 [info] Devcontainer CLI written to /tmp/devcontainer-cli-3f114d75-3804-45d8-85af-2dfff3698853
2025-12-25 10:23:05.382 [info] Copying forwarder.js to /tmp/devcontainer-cli-3f114d75-3804-45d8-85af-2dfff3698853
2025-12-25 10:23:05.398 [info] [docker inspect]: Command completed with exit code 0
2025-12-25 10:23:05.398 [info] Copying devcontainerShutdownMonitor.js to /tmp/devcontainer-cli-3f114d75-3804-45d8-85af-2dfff3698853
2025-12-25 10:23:05.399 [info] Getting config for image product_i2v:25-01-24 from vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%253A25-01-24.json
2025-12-25 10:23:05.401 [info] No container configuration file found for image vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%253A25-01-24.json Unable to read file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%3A25-01-24.json' (Error: Unable to resolve nonexistent file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%3A25-01-24.json')
2025-12-25 10:23:05.402 [info] Getting config for container product_i2v from vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json
2025-12-25 10:23:05.402 [info] No container configuration file found for container product_i2v Unable to read file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json' (Error: Unable to resolve nonexistent file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json')
2025-12-25 10:23:05.402 [info] Returning config: {}
2025-12-25 10:23:05.402 [info] Found attached container configuration: {}
2025-12-25 10:23:05.402 [info] Installing remote server in container...
2025-12-25 10:23:05.402 [error] Failed to read .gitconfig: TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined
2025-12-25 10:23:05.403 [error] Error resolving dev container authority The "path" argument must be of type string. Received undefined

Key error message

2025-12-25 10:23:05.402 [error] Failed to read .gitconfig: TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined
2025-12-25 10:23:05.403 [error] Error resolving dev container authority The "path" argument must be of type string. Received undefined

The VSCode never had this connection problem. I think it is caused by the Dev Containers extension developed by cursor team.

Steps to Reproduce

Every time the machine is disconnected from the network, it needs to be reconnected.

Expected Behavior

Only need to reload window once to connect successfully.

Screenshots / Screen Recordings

Operating System

MacOS

Current Cursor Version (Menu → About Cursor → Copy)

Version: 2.2.43
VSCode Version: 1.105.1
Commit: 32cfbe848b35d9eb320980195985450f244b3030
Date: 2025-12-19T06:06:44.644Z (5 days ago)
Electron: 37.7.0
Chromium: 138.0.7204.251
Node.js: 22.20.0
V8: 13.8.258.32-electron.0
OS: Darwin arm64 24.5.0

Does this stop you from using Cursor

Yes - Cursor is unusable

Hey, thanks for the report.

This is a known issue with the Dev Containers extension when connecting via Remote SSH. The team is already working on a fix.

The error happens when the extension tries to read .gitconfig, but the path is undefined on the remote host.

Possible workaround:

  1. Make sure ~/.gitconfig exists on the remote SSH server (not inside the container):
ls -la ~/.gitconfig
  1. If it doesn’t exist, create a minimal config:
git config --global user.name "Your Name"
git config --global user.email "[email protected]"
  1. Then try reconnecting to the container.

Let me know whether the workaround helps or if the issue persists. I’ll pass any additional info to the team.

Sorry for the late reply. I just tried your temporary solution (create .gitconfig in remote server, not remote container), but I still get the same problem.

2025-12-30 11:15:47.937 [info] No remote exec server found for authority: dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d@ssh-remote+7b22686f73744e616d65223a2234303930227d; using local
2025-12-30 11:15:48.301 [info] Resolving dev container authority 'dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d' (attempt #1) container '{"settingType":"container","containerId":"3d6e9811f6be"}'
2025-12-30 11:15:48.301 [info] Using exec server from resolve options. execServerRemoteAuthority: ssh-remote+7b22686f73744e616d65223a2234303930227d
2025-12-30 11:15:48.314 [info] Starting Dev Containers dev-container+7b2273657474696e6754797065223a22636f6e7461696e6572222c22636f6e7461696e65724964223a22336436653938313166366265227d
2025-12-30 11:15:48.314 [info] [docker info]: Running command: docker
2025-12-30 11:15:48.325 [info] Copying devcontainer CLI from /Users/lizhengjia/.cursor/extensions/anysphere.remote-containers-1.0.29/dist/@devcontainers to /tmp/devcontainer-cli-cd123d51-8549-43b1-a791-0a41ee0b6aad
2025-12-30 11:15:48.366 [info] [docker info]: Command completed with exit code 0
2025-12-30 11:15:48.366 [info] docker version: Client:
 Version:    24.0.5
 Context:    default
 Debug Mode: false

Server:
 Containers: 1
  Running: 1
  Paused: 0
  Stopped: 0
 Images: 140
 Server Version: 24.0.5
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Using metacopy: false
  Native Overlay Diff: true
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: systemd
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: inactive
 Runtimes: io.containerd.runc.v2 nvidia runc
 Default Runtime: nvidia
 Init Binary: docker-init
 containerd version: 
 runc version: cb82e29c75d387992bf59eb6eadf5d96cb6d4747
 init version: 
 Security Options:
  apparmor
  seccomp
   Profile: builtin
  cgroupns
 Kernel Version: 6.8.0-49-generic
 Operating System: Ubuntu 22.04.1 LTS
 OSType: linux
 Architecture: x86_64
 CPUs: 32
 Total Memory: 62.61GiB
 Name: server-4090
 ID: 7d3cd6a6-baf5-4322-9694-270c920e1391
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 Experimental: false
 Insecure Registries:
  10.108.0.3:15080
  127.0.0.0/8
 Registry Mirrors:
  https://docker.1ms.run/
  https://hub.rat.dev/
  https://docker.1panel.live/
 Live Restore Enabled: false
2025-12-30 11:15:48.366 [info] Inspecting docker container 3d6e9811f6be (fallback name: product_i2v)
2025-12-30 11:15:48.366 [info] [docker inspect]: Running command: docker
2025-12-30 11:15:48.377 [info] Devcontainer CLI written to /tmp/devcontainer-cli-cd123d51-8549-43b1-a791-0a41ee0b6aad
2025-12-30 11:15:48.382 [info] Copying forwarder.js to /tmp/devcontainer-cli-cd123d51-8549-43b1-a791-0a41ee0b6aad
2025-12-30 11:15:48.389 [info] Copying devcontainerShutdownMonitor.js to /tmp/devcontainer-cli-cd123d51-8549-43b1-a791-0a41ee0b6aad
2025-12-30 11:15:48.394 [info] [docker inspect]: Command completed with exit code 0
2025-12-30 11:15:48.396 [info] Getting config for image product_i2v:25-01-24 from vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%253A25-01-24.json
2025-12-30 11:15:48.398 [info] No container configuration file found for image vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%253A25-01-24.json Unable to read file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%3A25-01-24.json' (Error: Unable to resolve nonexistent file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/imageConfigs/product_i2v%3A25-01-24.json')
2025-12-30 11:15:48.400 [info] Getting config for container product_i2v from vscode-userdata:/Users/lizhengjia/Library/Application%20Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json
2025-12-30 11:15:48.401 [info] No container configuration file found for container product_i2v Unable to read file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json' (Error: Unable to resolve nonexistent file 'vscode-userdata:/Users/lizhengjia/Library/Application Support/Cursor/User/globalStorage/anysphere.remote-containers/nameConfigs/product_i2v.json')
2025-12-30 11:15:48.401 [info] Returning config: {}
2025-12-30 11:15:48.401 [info] Found attached container configuration: {}
2025-12-30 11:15:48.401 [info] Installing remote server in container...
2025-12-30 11:15:48.401 [error] Failed to read .gitconfig: TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined
2025-12-30 11:15:48.402 [error] Error resolving dev container authority The "path" argument must be of type string. Received undefined

1 Like

In addition, I found some strange content in the ~/.gitconfig inside the container, I deleted the content, but the problem still exists.

image

1 Like

Hey @378610 I am Tarun from the extension team.

Can you check the version of the remote extension and dev container extension.
Try updating them to latest and lmk if the error persists.

I tried reproducing the error, but the best i got was 2025-12-30 17:21:56.338 [error] Failed to read /home/ubuntu/.gitconfig: EntryNotFound (FileSystemError): /home/ubuntu/.gitconfig

This is what i followed - connect to remote host > spin up a container (i did docker run -d --name my-test-container ubuntu:latest sleep infinity) > attach to a running container > close window > attach again

@Tarun_Kumar_S

Hi, the version of (remote ssh / dev containers) in my docker is already latest.

But the issue still exists.

To be honest, I don’t know how I can get you to reproduce this problem. Maybe this problem is related to my machine or system version. But I can provide any logs you need to help troubleshoot this problem.

Seems like it Izj.

If you find anything interesting happening in between, feel free to hit us up.

Maybe if you can share the image that your are using, i can prob give one last shot, not sure if its gonna reveal anything tho.

btw this happens on vscode created containers too so nothing unusual / not related to the issue at hand.

I am still failing to reproduce, and noticed this while working on something else, dropping it here for future reference

@Tarun_Kumar_S I noticed that there is also this error message. Is this problem caused by this error? I really can’t find this file on the local machine.

I believe this is a caching thing.
But will look into it more, can u share the entire log if u still have it / the next you see this error.

HI @Tarun_Kumar_S

I’ve just run into this bug today and spent 90 minutes reproducing/debugging before finding this thread, I’m happy to provide a full log privately, but cannot attach it to this public thread.

The symptoms I observe are that cursor can correctly connect to my workspace/devcontainer when run locally, but if I try and connect using a remote SSH connection then container setup fails as per the attached log snippet (from which I’ve elided all my personal details).

cursor-fail-snippet.txt (10.0 KB)

If I open the devcontainer locally first, then subsequent remote connections succeed (once the ~/.gitconfig exists), likewise simply touching ~/.gitconfig in the broken container allows cursor to continue and successfully opens the container, but in this case the .gitconfig is never populated.

In the same setup, vscode with the default devcontainers extension can successfully load a fresh devcontainer (with no ~/.gitconfig) and correctly populates it, so the issue/bug seems specific to the cursor fork.

In all my testing, I’m starting from a blank slate (e.g. docker rm -f PREVIOUS_CONTAINER; docker image rm PREVIOUS_CONTAINER) so cursor/vscode are building and starting a fresh container.

If there are further details that would help get this fixed please let me know.

Versions in Use:

Cursor > Help > About:
Version: 2.3.41
VSCode Version: 1.105.1
Commit: 2ca326e0d1ce10956aea33d54c0e2d8c13c58a30
Date: 2026-01-16T19:14:00.150Z
Electron: 37.5.1
Chromium: 138.0.7204.251
Node.js: 22.19.0
V8: 13.8.258.32-electron.0
OS: Linux x64 6.18.3-arch1-1

Cursor > Extensions > Dev Containers
Identifier: anysphere.remote-containers
Version: 1.0.31
Last Updated: 2026-01-27, 10:34:44

Hey @MattBrown thanks for going through the trouble of triaging it, appreciate it!

A couple of questions -

  1. [clarification] - You connect to the remote instance (which is a linux arch ?) first then clone the project their and then open it in container correct ?
    a. what happens when you do something like git config --list while connected to the remote but not inside the container
    b. What’s the host / local machine from which you are connecting ?

  2. If I open the devcontainer locally first, then subsequent remote connections succeed

    This is super weird, cuz the local devcontainer is based on the folder that’s on your local machine, but when u open a remote one – that lives inside the remote machine, so technically they are isolated / shouldn’t affect each other.
    Or did you mean something else ?

Can u share the repo / folder that you are using if its public / sharable – so i can try to recreate, if not, even just the devconfig file should be good.
Also do send the logs to my id ([email protected]).
If you can get the logs from remote ssh one that would be great! (output > remote ssh server)

[clarification] - You connect to the remote instance (which is a linux arch ?) first then clone the project their and then open it in container correct ?
a. what happens when you do something like git config --list while connected to the remote but not inside the container
b. What’s the host / local machine from which you are connecting ?

My local machine (hostname: inert) is linux arch (Omarchy to be precise); the remote host (hostname: argon) is an Ubuntu 25.10 machine, both machines are connected to a KVM on my desktop, so I have the ability to be “local” on either one for testing purposes, but in normal day-to-day operation and when the problem occurs, “inert” is the local host I’m using and “argon” is the remote machine hosting my devcontainers.

Connecting Cursor running on inert to argon and then running git config –list while not inside any container shows my standard git configuration from /home/matt, e.g.

user.name=Matt Brown
user.email=ELIDED
init.defaultbranch=main
pull.rebase=true
push.autosetupremote=true
push.default=simple
branch.sort=-committerdate
tag.sort=version:refname
diff.algorithm=histogram
diff.colormoved=plain
diff.mnemonicprefix=true
diff.renames=true
fetch.prune=true
fetch.prunetags=true
fetch.all=true
merge.conflictstyle=zdiff3

This is super weird, cuz the local devcontainer is based on the folder that’s on your local machine, but when u open a remote one – that lives inside the remote machine, so technically they are isolated / shouldn’t affect each other.
Or did you mean something else ?

I mean if I switch the KVM to argon, open Cursor locally on argon, and then build/open the devcontainer with cursor locally on argon; then I can switch back to inert, and successfully make remote connections into the now initialized devcontainer on argon.

If I remove the devcontainer on argon (docker rm -f <container id) and then try to reconnect from inert the error recurs - the devcontainer is left running on argon, but Cursor will not enter it successfully from inert; if I manually SSH to argon, enter the devcontainer and touch /home/vscode/.gitconfig then cursor will successfully connect/enter the devcontainer, but the file remains empty/unconfigured.

I have emailed the logs as requested. I would appreciate if they are not shared publicly.

Thanks.

1 Like