put fails with "Unknown command"
Opened this issue · 4 comments
barrydrink commented
When putting a file on an ftp server, an error is thrown.
To reproduce, run the example put
code:
var fs = require('fs');
var ftp = new PromiseFtp();
ftp.connect({host: host, user: user, password: password})
.then(function (serverMessage) {
return ftp.put('foo.txt', 'foo.remote-copy.txt');
}).then(function () {
return ftp.end();
});
Stack trace:
Unhandled rejection Error: Unknown command
at makeError (/Users/projects/ftpProject/node_modules/@icetee/ftp/lib/connection.js:1128:13)
at Parser.<anonymous> (/Users/projects/ftpProject/node_modules/@icetee/ftp/lib/connection.js:122:25)
at emitTwo (events.js:126:13)
at Parser.emit (events.js:214:7)
at Parser._write (/Users/projects/ftpProject/node_modules/@icetee/ftp/lib/parser.js:61:10)
at doWrite (_stream_writable.js:397:12)
at writeOrBuffer (_stream_writable.js:383:5)
at Parser.Writable.write (_stream_writable.js:290:11)
at Socket.ondata (/Users/projects/ftpProject/node_modules/@icetee/ftp/lib/connection.js:298:20)
at emitOne (events.js:116:13)
at Socket.emit (events.js:211:7)
at addChunk (_stream_readable.js:263:12)
at readableAddChunk (_stream_readable.js:250:11)
at Socket.Readable.push (_stream_readable.js:208:10)
at TCP.onread (net.js:597:20)
sptutusukanta commented
Hello, is there any update on this. Because I'm still getting this error.
barrydrink commented
Hello, is there any update on this. Because I'm still getting this error.
Any joy @sptutusukanta ?
sptutusukanta commented
@barrydrink No. I searched through the core of it. Internally it is using a library (class) which is old and possibly buggy. I just moved to the original FTP module & made a wrapper to use promises.
Later I may release some code for everyone to use. But at this moment it's not complete to be released.
janwidmer commented
I am getting the same error.. any update on it?