vscode-remote-release icon indicating copy to clipboard operation
vscode-remote-release copied to clipboard

Cannot copy files from remote SSH workspace to local workspace

Open jmdacruz opened this issue 5 years ago • 39 comments

  • VSCode Version: 1.41.0-insider (commit: 9579eda04fdb3a9bba2750f15193e5fafe16b959)
  • OS Version: macOS 10.15.1 Catalina

Steps to Reproduce:

  1. Open a remote SSH workspace
  2. Open a local workspace (in a new window)
  3. Select a file on the local workspace and "copy" it (either with contextual menu, or ctrl+C)
  4. Paste the file on the remote workspace (either with contextual menu, or ctrl+V)
  5. Result: The file is copied correctly
  6. Now the reverse: Select a file on the remote workspace and "copy" it (either with contextual menu, or ctrl+C)
  7. Paste the file on the local workspace (either with contextual menu, or ctrl+V)
  8. Result: The file is not copied, and an error message is shown: The file to paste has been deleted or moved since you copied it. No file system provider found for vscode-remote://ssh-remote...
  9. Also, pasting the remote file into Finder yields an empty (zero byte) file (with the correct name)

Does this issue occur when all extensions are disabled?: Yes

jmdacruz avatar Dec 11 '19 04:12 jmdacruz

The identical problem in my case.

frothywater avatar Feb 24 '20 12:02 frothywater

Same issue with dockers image

PierreMarchand20 avatar Jun 09 '20 14:06 PierreMarchand20

The identical problem in my case.

luckydog1996 avatar Jul 12 '20 09:07 luckydog1996

The identical problem in my case.

carmurio avatar Aug 21 '20 00:08 carmurio

Same issue here.

eduardkieser avatar Sep 22 '20 16:09 eduardkieser

Also cannot copy between multiple remote workspaces.

Using remote containers: The file(s) to paste have been deleted or moved since you copied them. Unable to resolve non-existing file 'vscode-remote://attached-container+7b22636f6e7461696e65724e616d65223a222f616d2d6e6578745f6261636b656e645f31227d/files/test.ts'

Note that there is a way to get copy and paste working between remote containers. If you mount the same files on multiple containers (mount both containers files to /files/ for example) and use use different vscode workspaces for each container (eg /files/frontend for one and /files/backend for the other) you can copy/paste no problem.

Example docker-compose file:

backend: build: ./containers/backend volumes: - ./source_folder_with_both_repos/:/files

frontend: build: ./containers/frontend ports: - 8080:80 volumes: - ./source_folder_with_both_repos/:/files

aaron-manning avatar Oct 05 '20 09:10 aaron-manning

Same issue here.

monkeyWie avatar Jan 13 '21 02:01 monkeyWie

I've got the same issue - would be so nice to have this working when debugging issues of a project on a remote server which uses external files are sources - my current workaround: select the files to copy, click download - download them manually to the right location

ThaDaVos avatar Feb 08 '21 10:02 ThaDaVos

I've got the same issue - would be so nice to have this working when debugging issues of a project on a remote server which uses external files are sources - my current workaround: select the files to copy, click download - download them manually to the right location

but we can't see right progress in status bar with current/total and disconnection from remote folder appears always until I'm trying to download a file with large size (~130Mb)

the-homeless-god avatar Mar 06 '21 09:03 the-homeless-god

same

APassbyDreg avatar May 10 '21 16:05 APassbyDreg

same issue

ludenus avatar May 25 '21 14:05 ludenus

same issue

francoisguibourt-punch avatar May 27 '21 13:05 francoisguibourt-punch

same

kenjichanhkg avatar Jun 10 '21 01:06 kenjichanhkg

same

garet90 avatar Jul 11 '21 09:07 garet90

I also have the same problem can anyone confirm that the server that they're trying to connect to has IPv6? Also, is everyone using a key or a password to login?

georgcmef avatar Jul 29 '21 23:07 georgcmef

I found this useful:- Select the files you need to copy > right-click "Download"

Found the solution here:- https://github.com/microsoft/vscode-docs/blob/master/remote-release-notes/v1_36.md#drag-and-drop-to-and-from-the-explorer

spShashankGit avatar Aug 16 '21 02:08 spShashankGit

This was working for me (copy from ssh session to local, and copy from wsl to local) but suddenly it stopped working. Is this a bug or a configuration issue?

mikedoy avatar Dec 29 '21 16:12 mikedoy

Is there a short way like 'right-click "Download"' to upload( or copy) file from local to remote server(ssh or wsl)?

zhangmx avatar Feb 09 '22 07:02 zhangmx

Is there a short way like 'right-click "Download"' to upload( or copy) file from local to remote server(ssh or wsl)?

You should be able to drag a file from the OS file-manager into vscode's file-tree window to upload it (or to the editor pane to open it in-place).

avivey avatar Feb 09 '22 19:02 avivey

@avivey Thank you 😄

zhangmx avatar Feb 10 '22 01:02 zhangmx

You can drag a single file from the remote VS Code File Explorer to your local machine. Due to an upstream limitation, we cannot support this on Linux or for multiple files.

This doesn't seem to work on Windows either (anymore).

OlafvdSpek avatar Apr 10 '22 20:04 OlafvdSpek

would be great if there would be a workaround. I am using an sftp client for now.

jamblejoe avatar May 18 '22 09:05 jamblejoe

I tried both dragging to a local VSC window and copying/pasting. Neither worked.

ggilley avatar Jun 04 '22 23:06 ggilley

Use cases (I'm presuming codespaces and SSH have similar mechanisms?):

  • container to host
  • host to container
  • container to container
  • codespace to codespace
  • codespace to container
  • container to codespace
  • codespace to host
  • host to codespace

Both file and directory

JamesHutchisonCarta avatar Aug 20 '22 00:08 JamesHutchisonCarta

Same here:

Cannot copy-paste remotely

SetTrend avatar Nov 17 '22 22:11 SetTrend

vscode remote ssh paste file support from explorer.exe ?

QGB avatar Jan 11 '23 07:01 QGB

would still like this!

hagen6835 avatar Mar 29 '23 14:03 hagen6835

There is a download button in the menu

VisheshIrasus avatar May 01 '23 19:05 VisheshIrasus

Hoping that it will be available some day.

ranit43 avatar Jun 30 '23 23:06 ranit43

+1 for this feature to be available

aafaque33 avatar Feb 12 '24 19:02 aafaque33