Open erikandershed opened 6 years ago
was going to do a PR but, it seems this issue has been fixed on some pull request, but i guess, its not been updated in the npm, i just updated the ssh2 version number to "ssh2": "~0.5.5" and did a npm install again within the library and works.
I did remove gulp and reinstalled all, also updated ssh2 to 0.6.1. After this I get an other errow
eriks-mbp:app erik$ gulp -v
[15:42:00] CLI version 2.0.1
[15:42:00] Local version 3.9.1
[15:41:14] Starting 'default'...
[15:41:14] Authenticating with password.
buffer.js:207
throw new ERR_INVALID_ARG_TYPE(
^
TypeError [ERR_INVALID_ARG_TYPE]: The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type undefined
at Function.from (buffer.js:207:11)
at new Buffer (buffer.js:182:17)
at onNEWKEYS (/Users/erik/Desktop/Erik/code/dev/app/node_modules/gulp-sftp/node_modules/ssh2/lib/Connection.js:2366:29)
at Parser.<anonymous> (/Users/erik/Desktop/Erik/code/dev/app/node_modules/gulp-sftp/node_modules/ssh2/lib/Connection.js:129:5)
at Parser.emit (events.js:182:13)
at Parser.parsePacket (/Users/erik/Desktop/Erik/code/dev/app/node_modules/gulp-sftp/node_modules/ssh2/lib/Parser.js:468:12)
at Parser.execute (/Users/erik/Desktop/Erik/code/dev/app/node_modules/gulp-sftp/node_modules/ssh2/lib/Parser.js:249:14)
at Socket.<anonymous> (/Users/erik/Desktop/Erik/code/dev/app/node_modules/gulp-sftp/node_modules/ssh2/lib/Connection.js:536:18)
at Socket.emit (events.js:182:13)
at addChunk (_stream_readable.js:283:12)
the same problem is when I try Gulp 4
$ gulp -v
[16:27:13] CLI version 2.0.1
[16:27:13] Local version 4.0.0-alpha.3
Any update on this?
It seems that I can't update the gulp-sftp to 0.1.6 where the update dependencies is for "ssh2": "~0.5.5". Can you please helt me.
@erikandershed do you get any errors, did you try the method i told you.
1) remove the node folder "rm -rf node_modules"
2) reinstall all the packages npm install
3) goto the gulp-sftp folder inside the node_modules cd node_modules/gulp-sftp
4) open it in a text editor("subl .") and change the ssh2 package version to "~0.5.5"
before
after
5) go back up 2 steps. "cd .." , "cd .." and do a "npm install" again.
Yes it works! Thanks!
Np. Glad i could help. 😊
Is there any way to not manipulate the folders manually, in my case am using a DevOps pipeline and I don't have an enough rights on the remote server folders to modifiy node_modules .
So ho I can update the SSH2 version of Gulp-SFTP from package.json ?
Is there any way to not manipulate the folders manually, in my case am using a DevOps pipeline and I don't have an enough rights on the remote server folders to modifiy node_modules .
So ho I can update the SSH2 version of Gulp-SFTP from package.json ?
You able to modify the dev pipeline, if so, i think, after doing the npm install, if you add another step with something like npm remove ssh2 && npm install ssh2@0.5.5
, it should work ( haven't tested this, but it should work.)
if you can't modify the pipeline for some reason, i guess, the way would be to, download the gulp-sftp
source and then publish it to npm as a custom package. then you can use that custom package within the package.json :) (this would be the better way of doing it compared to the first method.)
I can't find a fix for this problem. I get this error (throw new TypeError(kFromErrorMsg);) it started a couple months back . I Can't upload any fils to SFTP see my settings and respons: