-
Notifications
You must be signed in to change notification settings - Fork 267
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
error 'no such file' during upload on save #915
Comments
I am getting the same issue. I've used this extension for over a year and it only stopped over the weekend. Worked perfectly on Friday, 4/23/2021, but failed first thing this morning. Possibly a VSCode update? I'm using Insiders Edition and haven't tried the regular edition. @davidesnc , are you on Insiders or regular edition of VSCode? |
+1 on insiders. Does seem like it does upload, so it's just a false positive. |
Not a false positive. I agree that some of the times it still writes the files but not others. If you Sync Local -> Remote on a directory for instance some files get wiped out on the remote or end up blank or cut short. My entire build fails after a Sync because of missing file contents on the remote. |
I'm using insider version too. |
I opened a bug report on VS Code but there have been a few hundred commits since last Friday. I wasn't able to find anything specific that is an obvious reason for this. I'm going to try installing the non Insiders edition to see if it still works and to check which Nodejs version is being used. The errors are in calls to stream which is internal to Nodejs. Otherwise, I might need to switch to using the Microsoft "Remote - SSH" extension which I didn't want to do since my remote doesn't use git. |
As expected, VS Code, non Insiders, works fine. It is also on Node 12.18.3 where Insiders is on 14.16.0. I'm not sure when Insiders updated but it might be a Node issue. |
@mbinette |
Hi. Just confirming that I get the same issue on Insiders. Didn't try normal edition. |
a stupid workaround, but it works for me. |
Just another "me too", but to add that switching to "FTP" protocol instead of "SFTP" still works (but very slow for some reason). Not ideal, but helped in a pinch. |
Cleaner approach to this would actually be to edit the line n°386 this from
to this
This way, you don't lose other error warnings, just the "no such file" one. Still, quite bad to have to resort to this kind of workaround... |
Same issue here. Just got updated today normal edition 1.56.0. So I guess they didn't fix the bug in the insider version and now the normal edition has the same problem. Regardless of the error, the files are still synced. |
This did not work for me. It stuck reporting it was uploading. I did just implement @davidesnc hack. That works fine on the surface. |
Hello, please overlook my fault if you find because this is the first time to post comment here github. I was getting same issue with probability normal edition v1.12.9.
And, restart VSCode. It seems working well for the present. |
Thanks! Hoping the vscode could officially fix this any time soon |
another workaround is to downgrade to 1.55 https://code.visualstudio.com/updates/v1_55 |
Another "me too". also getting this on normal version 1.56.0. however, the upload function does seem to be uploading correctly despite the "no such file" error toast |
It's almost work perfectly, but doesn't work when you sync from local -> remote |
well, i downgrade vscode to 1.55 and reinstall this ext fix this problem |
I'm also getting this error. I've noticed that it will successfully transfer some files and others will be transferred with zero bytes (resulting in an error). I've rolled back to 1.55 and turned off auto updates for now. Fingers crossed it gets resolved soon. |
Oops, just saw that myself, it stuck reporting the upload of the first file you uploaded in that session. Do it in line 388 instead : Of course, revert line 386 back. |
You may have another issue. Try using the fix in my previous message. If it still doesn't work, use #915 (comment) |
Sure update Issued this bug. I reinstalled version 1.55.2, and sftp extensions works well again. |
Actually, I've already done everything. It's fine when it's come to save file by file. But, when you trying to perform local sync to remote, it become infinite loading... or maybe it just me |
The final solution I do, is downgrade to 55 |
Since upload local -> remote also still works, you can apply this patch to avoid seeing the error.
to
That way you can still upload files, dont have to downgrade, and just dont see the annoying error. |
This does the same as my solution, except it discards all errors. |
@Webbeh I see that this discards all errrors, but your fix didnt solve the erorr on upload local -> remote for me. The error vscode throws me is 'Handle is invalid'. The error code is 4, corresponding to FAILURE. I reverted my previous patch on line 416, and made line 388:
However, this indeed still discards a lot of errors |
That didnt work for me, local -> remote still not uploading and getting popup error. But this did! |
You all need to start mentioning which OS you're using VSCode on... |
My apologies. I'm using Pop OS 20.10 and VS Code Insiders 1.57.0. And thank you for developing an extension that I use daily. I know it must be frustrating to fix bugs that vscode has caused. |
Should this issue be logged with the ssh2-streams or ssh2 projects? It seems like this extension only broke because those libraries are returning something different than expected. |
Sorry, I'm using Windows 10 Home 20H2 (build: 19042.964) VS Code: I use VSCode from WSL 2. In WSL I use Ubuntu 20.04. |
I'm getting the same issue but the files do seem to upload successfully despite the error message. I am using: Version: 1.56.1 |
Version: 1.55.2 (system setup) Still hold at 1.55 |
Where the patch at? |
It work fine for me ! Thanks. |
POSTED TO Stack Overflow: https://stackoverflow.com/questions/67506693/vscode-error-no-such-file-sftp-liximomo-extension/67524099#67524099 See post in Issue #934. |
Same here: |
For everyone implementing any of those fixes : please roll them back and use the fix in #919 (comment) It will work better for everyone, no matter your OS. And stop waiting for an update to this plugin, it's most likely not gonna happen :( |
yeah,this is a false negative = = |
Can confirm, I can upload/download from my remote path just fine but gives me a "No such file" error regardless. Rolling back to the previous version works fine with no error messages. |
@ZihaoZheng98 @mattizhu there's a fix 3 posts before this one. |
For me changing the protocol from |
Hey I found the fix... |
I have error too:
Version: 1.56.2 check any solution listing above - not work for me |
Have you ever tried solution from @rwildcard ? |
Just follow thoses steps to make it working again without any issues (temporary fix) : #919 (comment) |
I actually like to do this instead, thanks for the version number and link. |
Same issue for me. 1.56 -> no such File Message. Version: 1.57.0 |
Same problem
|
You can try my version, i've fixed a lot of bugs, maybe this will fix yours 🙂 |
Amazing. Thank you @Natizyskunk! |
Thanks for the efforts @Natizyskunk . Your version of the extension solved my issue. |
This help me. Thanks!! |
Work! Thank's! 👯 |
SOLUTION FOR "NO SUCH FILE" WHEN USING SFTP PROTOCOLThere's the solution that will solve the problem! If you get "No such file" error on SFTP (both branch) it can be because when using "protocol": "sftp" you're supposed to enter the absolute (like really absolute path), not like with FTP where the absolute path start at the "user root" There's example not working:{ There's a working exemple:{ Hope it will help some of you :) |
I have an error during the upload when saving file
this is the log on view->option->sftp
could you help me ?
thanks in advance
[04-26 14:48:02] [error] Error: No such file
at SFTPStream._transform (/Users/davide/.vscode-insiders/extensions/liximomo.sftp-1.12.9/node_modules/ssh2-streams/lib/sftp.js:412:27)
at SFTPStream.Transform._read (internal/streams/transform.js:205:10)
at SFTPStream._read (/Users/davide/.vscode-insiders/extensions/liximomo.sftp-1.12.9/node_modules/ssh2-streams/lib/sftp.js:183:15)
at SFTPStream.Transform._write (internal/streams/transform.js:193:12)
at writeOrBuffer (internal/streams/writable.js:358:12)
at SFTPStream.Writable.write (internal/streams/writable.js:303:10)
at Channel.ondata (internal/streams/readable.js:719:22)
at Channel.emit (events.js:315:20)
at addChunk (internal/streams/readable.js:309:12)
at readableAddChunk (internal/streams/readable.js:284:9)
at Channel.Readable.push (internal/streams/readable.js:223:10)
at SSH2Stream. (/Users/davide/.vscode-insiders/extensions/liximomo.sftp-1.12.9/node_modules/ssh2/lib/Channel.js:167:15)
at SSH2Stream.emit (events.js:315:20)
at parsePacket (/Users/davide/.vscode-insiders/extensions/liximomo.sftp-1.12.9/node_modules/ssh2-streams/lib/ssh.js:3288:10)
at SSH2Stream._transform (/Users/davide/.vscode-insiders/extensions/liximomo.sftp-1.12.9/node_modules/ssh2-streams/lib/ssh.js:694:13)
at SSH2Stream.Transform._read (internal/streams/transform.js:205:10)
at SSH2Stream._read (/Users/davide/.vscode-insiders/extensions/liximomo.sftp-1.12.9/node_modules/ssh2-streams/lib/ssh.js:253:15)
at SSH2Stream.Transform._write (internal/streams/transform.js:193:12)
at writeOrBuffer (internal/streams/writable.js:358:12)
at SSH2Stream.Writable.write (internal/streams/writable.js:303:10)
at Socket.ondata (internal/streams/readable.js:719:22)
at Socket.emit (events.js:315:20)
at addChunk (internal/streams/readable.js:309:12)
at readableAddChunk (internal/streams/readable.js:284:9)
at Socket.Readable.push (internal/streams/readable.js:223:10)
at TCP.onStreamRead (internal/stream_base_commons.js:188:23) when local ➞ remote /opt/data/iseo/progetti/v364/server/uti/internal_obfuscate.php
The text was updated successfully, but these errors were encountered: