Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stream file size read incorrectly #139

Closed
crobinson42 opened this issue Apr 25, 2016 · 2 comments
Closed

Stream file size read incorrectly #139

crobinson42 opened this issue Apr 25, 2016 · 2 comments

Comments

@crobinson42
Copy link

We're experiencing an issue with the file size being incorrect for the FIRST file when multiple files are uploaded. The issue can be reference here: https://github.com/balderdashy/skipper/issues/109

Basically, the first file size stream.byteCount is the aggregate size of all the files in the upload request. Then, all following file sizes are accurate on stream.byteCount after the first file stream. (NOTE: this happens when we use the same key when uploading multiple files)

Here is a console.log from index line 502 of the headers:

Fileupload, multiparty headers:
{ 'content-disposition': 'form-data; name="file"; filename="IMG_20151110_0001.pdf"',
  'content-type': 'application/pdf' }
Fileupload, multiparty headers:
{ 'content-disposition': 'form-data; name="file"; filename="Farnsworth Resume 2015.docx"',
  'content-type': 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' }

This behavior exists in the current v4.1.2 w/ node v4.4.0

@crobinson42 crobinson42 changed the title Headers file size read incorrectly Stream file size read incorrectly Apr 25, 2016
@dougwilson
Copy link
Contributor

Hi @carbonrobot I'm not sure what is happening. I can certainly take a look, but would need to get something in hand to debug through. Could you provide all the following?

  1. A complete server that I can startup and run to reproduce the issue (rather than a code snippet). If you're using other modules, please note down their exact versions as well.
  2. Complete instructions for how to run your server code and how to make the offending request to the server.

Thank you!

@carbonrobot
Copy link
Contributor

Tagging @crobinson42 instead of me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants