Skip to content
This repository has been archived by the owner on Mar 14, 2019. It is now read-only.

Binary File Transfers Corrupted? Truncated? #41

Closed
petrocket opened this issue May 3, 2013 · 7 comments
Closed

Binary File Transfers Corrupted? Truncated? #41

petrocket opened this issue May 3, 2013 · 7 comments

Comments

@petrocket
Copy link

I'm using meteorite 0.4.9, meteor 0.6.x and the latest collectionFS and when I upload any files (.jpg and .png tested) the resulting files are corrupt and shorter. Could this be an encoding issue? I did a file comparison and besides being a bit shorter the saved file also had a lot of characters that were different (in hex).

I'm hoping coffeescript doesn't have something to do with it because all my server code uses that and meteor 0.6.x got rid of global variables so it has caused some minor issues declaring collection instances.

@raix
Copy link

raix commented May 3, 2013

Please try uploading a small text file? I suspect it could be an issue in ejson base64 decoder meteor issue #1001 - I'll try to replicate

@petrocket
Copy link
Author

Small text file works fine!

@petrocket
Copy link
Author

Oh, just looked into that meteor issue - I bet you're right.

Meteor? I barely know her!

@raix
Copy link

raix commented May 3, 2013

I think its an issue with the latest option for setting encoding - the store + retrieve works (the data is fine in db and can retrieve via ddp) - but when the filehandler wants to save the data its not encoded correct when saving to the filesystem. The files are generated, but not correct (so no corruption in transport - guess methods/ddp is not using ejson.base64Decode - which would be another issue)

I've been using the deprecating 'binary' encoding but I guess this might be a good time to adapt.

I'll give it 15min more - getting late in my timezone :)

raix pushed a commit that referenced this issue May 4, 2013
* Minor fix due to new option `encoding`
@raix
Copy link

raix commented May 4, 2013

@petrocket Should work now, on mrt version 0.2.3

@raix raix closed this as completed May 4, 2013
@petrocket
Copy link
Author

Yay appears to be fixed! Gotta love livin on the bleeding edge of technology.

@maitrid
Copy link

maitrid commented Oct 12, 2015

i'm using Meteor 1.2, and have the same problem. i'm using 'binary' as encoding,

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

No branches or pull requests

3 participants