Natizyskunk / vscode-sftp

Super fast sftp/ftp extension for VS Code
Other
400 stars 78 forks source link

[error] Error: Config Not Found. (file: <filename>) lists the file being sent not the config file #522

Open cliff-in-auld-reekie opened 1 week ago

cliff-in-auld-reekie commented 1 week ago

Do you read the FAQ?

Describe the bug When I try to upload I get an error and that's fine as I'm setting up new targets. However, the stated filename is not the config file SFTP can't find but the file I'm trying to upload. That's a tad useless as I know what I'm trying to upload but I don't know which config file(s) it is looking for or where exactly it is looking.

To Reproduce Right click, Upload file

Expected behaviour The error message stating the name and location of the config file(s) it is not finding.

Screenshots Wouldn't really help

Desktop (please complete the following information):

Extension Logs from Startup - required [11-07 12:14:10] [trace] run command 'Upload File' [11-07 12:14:10] [error] Error: Config Not Found. (file:///Users/cliffwallace/Desktop/_VSCode/rpi/MagicMirror/docs/install.text) at Object.l (/Users/cliffwallace/.vscode/extensions/natizyskunk.sftp-1.16.3/dist/extension.js:2:296202) at t.default. (/Users/cliffwallace/.vscode/extensions/natizyskunk.sftp-1.16.3/dist/extension.js:2:221424) at Generator.next (:null:null) at /Users/cliffwallace/.vscode/extensions/natizyskunk.sftp-1.16.3/dist/extension.js:2:220593 at new Promise (:null:null) at n (/Users/cliffwallace/.vscode/extensions/natizyskunk.sftp-1.16.3/dist/extension.js:2:220338) at /Users/cliffwallace/.vscode/extensions/natizyskunk.sftp-1.16.3/dist/extension.js:2:221365 at Array.map (:null:null) at t.default. (/Users/cliffwallace/.vscode/extensions/natizyskunk.sftp-1.16.3/dist/extension.js:2:221357) at Generator.next (:null:null) at s (/Users/cliffwallace/.vscode/extensions/natizyskunk.sftp-1.16.3/dist/extension.js:2:220395)

MHagood commented 1 week ago

Possibly related, albeit on a Windows machine: I receive this exact error when I try to deploy using a network share, SMB or otherwise. As a control, I temporarily moved my entire vs code project onto my local disk to re-attempt deployment with the exact same config; it worked fine.

My consistent workaround while continuing to use network shares is to deploy manually via right-clicking my solution's root folder: Sync Local -> Remote. For some reason, that works fine even on a remote share.

I was looking around these forums for a network share related issues but couldn't find one. If your issue turns out to be unrelated, sorry to waste your time and I'll open a separate issue later.

Here's my config for reference. I use a UN:PW auth method since I couldn't get password-based PKI to work with this tool for the life of me:

{
    "name": "some_site",
    "host": "192.168.0.30",
    "context": "W:/Source/Sites",
    "protocol": "sftp",
    "username": "deployment",
    "password": "super_secret",
    "remotePath": "/var/www",
    "syncOption": {
        "update": true,
        "delete": true
    },
    "uploadOnSave": false
}

uploadOnSave: false disables the broken auto-save logic syncOption: {} helps keep the destination dir clean as I rename my deployment files trillions of times