evanplaice / node-ftpsync

Intelligent file syncronization over FTP
http://evanplaice.github.io/node-ftpsync
MIT License
74 stars 21 forks source link

TypeError: Cannot read property 'on' of undefined #32

Closed kuncevic closed 7 years ago

kuncevic commented 8 years ago

Getting error wen running ftpsync.

Setup
Setup complete.

Collecting
C:\Users\Me\AppData\Roaming\nvm\v5.8.0\node_modules\ftpsync\node_modules\jsftp\lib\jsftp.js:374
      socket.on("data", function(data) {
            ^

TypeError: Cannot read property 'on' of undefined
    at C:\Users\Me\AppData\Roaming\nvm\v5.8.0\node_modules\ftpsync\node_modules\jsftp\lib\jsftp.js:374:13
    at C:\Users\Me\AppData\Roaming\nvm\v5.8.0\node_modules\ftpsync\node_modules\jsftp\lib\jsftp.js:54:24
    at Array.<anonymous> (C:\Users\Me\AppData\Roaming\nvm\v5.8.0\node_modules\ftpsync\node_modules\jsftp\lib\jsftp.js:556:14)
    at Ftp.parse (C:\Users\Me\AppData\Roaming\nvm\v5.8.0\node_modules\ftpsync\node_modules\jsftp\lib\jsftp.js:237:13)
    at Ftp.parseResponse (C:\Users\Me\AppData\Roaming\nvm\v5.8.0\node_modules\ftpsync\node_modules\jsftp\lib\jsftp.js:148:8)
    at Stream.<anonymous> (C:\Users\Me\AppData\Roaming\nvm\v5.8.0\node_modules\ftpsync\node_modules\jsftp\lib\jsftp.js:119:24)
    at emitOne (events.js:90:13)
    at Stream.emit (events.js:182:7)
    at Stream.reemit (C:\Users\Me\AppData\Roaming\nvm\v5.8.0\node_modules\ftpsync\node_modules\duplexer\index.js:70:25)
    at emitOne (events.js:90:13)

Windows 10 Node 5.8 (Also tried with 4.x versions and got same error)

evanplaice commented 8 years ago

This error os thrown by JSFTP, the Node.js FTP client library used by node-ftpsync.

It would be best to file the bug there and create a reference to this issue.

fily55 commented 7 years ago

jsftp seems to be okay now but this still seems to be an issue. It looks like this package is dependant on an old version of jsftp.

evanplaice commented 7 years ago

The JSFTP dependency was updated in PR #39