johntitus / node-horseman

Run PhantomJS from Node
MIT License
1.45k stars 124 forks source link

Not able to downloading of Content-Disposition #311

Open mandakhsw opened 7 years ago

mandakhsw commented 7 years ago

It's not possible to download any content-disposition data sent by web site. When any content-disposition resource received, onLoadFinished throws an exception with message:

horseman phantomjs onLoadFinished triggered fail 7
Unhandled rejection Error: Failed to load url
    at checkStatus (D:\Sandbox\horseman\node_modules\node-horseman\lib\index.js:292:16)
    at tryCatcher (D:\Sandbox\horseman\node_modules\bluebird\js\release\util.js:16:23)
    at Function.Promise.attempt.Promise.try (D:\Sandbox\horseman\node_modules\bluebird\js\release\method.js:39:29)
    at Object.loadFinishedSetup [as onLoadFinished] (D:\Sandbox\horseman\node_modules\node-horseman\lib\index.js:290:43)
    at D:\Sandbox\horseman\node_modules\node-phantom-simple\node-phantom-simple.js:636:30
    at Array.forEach (native)
    at IncomingMessage.<anonymous> (D:\Sandbox\horseman\node_modules\node-phantom-simple\node-phantom-simple.js:617:17)
    at emitNone (events.js:91:20)
    at IncomingMessage.emit (events.js:185:7)
    at endReadableNT (_stream_readable.js:974:12)
    at _combinedTickCallback (internal/process/next_tick.js:74:11)
    at process._tickCallback (internal/process/next_tick.js:98:9)