4

I'm using skipper with skipper-s3 adapter to handle file uploads in my sails application.

It works fine when the file is sent normally, yet when the request is aborted I got an unhandled error message and sails crashes.

events.js:85
  throw er; // Unhandled 'error' event
        ^
Error: Request aborted
at IncomingMessage.onReqAborted (/Users/olivierroche/Dev/loopIt/API/node_modules/skipper/node_modules/multiparty/index.js:175:17)
at IncomingMessage.emit (events.js:104:17)
at abortIncoming (_http_server.js:279:11)
at Socket.socketOnEnd (_http_server.js:393:7)
at Socket.emit (events.js:129:20)
at _stream_readable.js:908:16
at process._tickDomainCallback (node.js:381:11)

I had a look at this subject : Aborted upload causes Sails js/Skipper to crash

However the problem does not seem to be solved in my case. I'm using skipper v0.5.5. Any clue on this error and how to handle this case ? It's is quite problematic as every time a user close his tab the server will simply crash.

Community
  • 1
  • 1
adc06
  • 793
  • 8
  • 23
  • 1
    As your error looks exactly what is int the same link you shared, I would post in that github issue looking for help. https://github.com/balderdashy/skipper/issues/49 – Meeker Mar 12 '15 at 16:38
  • Ok apparently it is a problem with the package. I'll post in this issue and try the workaround using the domain api proposed by jessearmand. If the problem isn't solved in the package i'll post the code for the workaround here if I manage to get it work. Thank you @Meeker. – adc06 Mar 13 '15 at 09:17
  • 1
    The [sails gitter room](https://gitter.im/balderdashy/sails) is also a good place to chat. – Travis Webb Mar 15 '15 at 00:41

1 Answers1

1

There is an open Pull Request with a fix to this bug: https://github.com/balderdashy/skipper/pull/78. Once it's merged, your question should be answered :)

Travis Webb
  • 14,688
  • 7
  • 55
  • 109