Skip to content
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

Cannot set property closed of #<Writable> which has only a getter #1032

Open
2 tasks done
jianfengye opened this issue Sep 19, 2024 · 7 comments
Open
2 tasks done

Cannot set property closed of #<Writable> which has only a getter #1032

jianfengye opened this issue Sep 19, 2024 · 7 comments

Comments

@jianfengye
Copy link

jianfengye commented Sep 19, 2024

Do you read the FAQ?

Describe the bug
i use sftp, show error : Cannot set property closed of # which has only a getter
but my .sftp has been checked.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Run command '....'
  3. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. Mac, Win, Linux]
  • VSCode Version [e.g. 1.27.0]
  • Extension Version [e.g. 1.7.0]

Extension Logs from Startup - required

  1. Open User Settings.

    • On Windows/Linux - File > Preferences > Settings
    • On macOS - Code > Preferences > Settings
  2. Set sftp.debug to true and reload vscode.

  3. Reproduce the problem, get the logs from View > Output > sftp.

@jianfengye
Copy link
Author

{
    "name": "My dev Server",
    "host": "xxx",
    "protocol": "sftp",
    "port": 36000,
    "username": "root",
    "remotePath": "/home/xxxx",
    "uploadOnSave": false,
    "privateKeyPath": "/Users/xxx/.ssh/id_rsa"
}

@jianfengye
Copy link
Author

-19 15:12:56] [error] TypeError: Cannot set property closed of # which has only a getter
at new WriteStream (/Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/node_modules/ssh2/lib/protocol/SFTP.js:3585:15)
at SFTP.createWriteStream (/Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/node_modules/ssh2/lib/protocol/SFTP.js:311:12)
at /Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/dist/extension.js:70:131256
at new Promise ()
at a._put (/Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/dist/extension.js:70:131218)
at a. (/Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/dist/extension.js:70:129943)
at Generator.next ()
at s (/Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/dist/extension.js:70:128197)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5) when local ➞ remote /Users/xxxx/static_not_start.go

@jianfengye
Copy link
Author

this is my debug info :

[09-19 22:15:37] [debug] Inbound: CHANNEL_SUCCESS (r:0)
[09-19 22:15:37] [debug] Outbound: Sending CHANNEL_DATA (r:0, 9)
[09-19 22:15:37] [debug] Inbound: CHANNEL_DATA (r:0, 154)
[09-19 22:15:37] [debug] SFTP: Inbound: Received VERSION (v3, exts:[email protected],[email protected],[email protected],[email protected],[email protected])
[09-19 22:15:37] [debug] Outbound: Sending CHANNEL_DATA (r:0, 72)
[09-19 22:15:37] [debug] SFTP: Outbound: Buffered MKDIR
[09-19 22:15:37] [debug] Inbound: CHANNEL_DATA (r:0, 28)
[09-19 22:15:37] [debug] SFTP: Inbound: Received STATUS (id:0, 4, "Failure")
[09-19 22:15:37] [debug] Outbound: Sending CHANNEL_DATA (r:0, 68)
[09-19 22:15:37] [debug] SFTP: Outbound: Buffered LSTAT
[09-19 22:15:37] [debug] Inbound: CHANNEL_DATA (r:0, 41)
[09-19 22:15:37] [debug] SFTP: Inbound: Received ATTRS (id:1)
[09-19 22:15:37] [debug] Outbound: Sending CHANNEL_DATA (r:0, 103)
[09-19 22:15:37] [debug] SFTP: Outbound: Buffered OPEN
[09-19 22:15:37] [debug] Inbound: CHANNEL_DATA (r:0, 17)
[09-19 22:15:37] [debug] SFTP: Inbound: Received HANDLE (id:2)
[09-19 22:15:37] [debug] Outbound: Sending CHANNEL_DATA (r:0, 17)
[09-19 22:15:37] [debug] SFTP: Outbound: Buffered FSTAT
[09-19 22:15:38] [debug] Inbound: CHANNEL_DATA (r:0, 41)
[09-19 22:15:38] [debug] SFTP: Inbound: Received ATTRS (id:3)
[09-19 22:15:38] [debug] Outbound: Sending CHANNEL_DATA (r:0, 25)
[09-19 22:15:38] [debug] SFTP: Outbound: Buffered FSETSTAT
[09-19 22:15:38] [debug] Inbound: CHANNEL_DATA (r:0, 28)
[09-19 22:15:38] [debug] SFTP: Inbound: Received STATUS (id:4, 0, "Success")
[09-19 22:15:38] [debug] Outbound: Sending CHANNEL_DATA (r:0, 17)
[09-19 22:15:38] [debug] SFTP: Outbound: Buffered CLOSE
[09-19 22:15:38] [debug] Inbound: CHANNEL_DATA (r:0, 28)
[09-19 22:15:38] [debug] SFTP: Inbound: Received STATUS (id:5, 0, "Success")
[09-19 22:15:38] [error] TypeError: Cannot set property closed of # which has only a getter
at new WriteStream (/Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/node_modules/ssh2/lib/protocol/SFTP.js:3585:15)
at SFTP.createWriteStream (/Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/node_modules/ssh2/lib/protocol/SFTP.js:311:12)
at /Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/dist/extension.js:70:131256
at new Promise ()
at a._put (/Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/dist/extension.js:70:131218)
at a. (/Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/dist/extension.js:70:129943)
at Generator.next ()
at s (/Users/jianfengye/.cursor/extensions/liximomo.sftp-1.12.10/dist/extension.js:70:128197)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5) when local ➞ remote /Users/jianfengye/Documents/UGit/.../static_record_not_start.go

@zhixuanli
Copy link

I have the same problem.

1 similar comment
@Liuchunyangboy
Copy link

I have the same problem.

@shr00mie
Copy link

what they said

@shr00mie
Copy link

...well. solution was rather simple. uninstall this extension and install the version by Kreare.

Kreare.kreare-sftp

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants