Closed laCour closed 8 years ago
@all, eagerly waiting for the solution.
@laCour Is there any progress on this issue? Anyone is working on this issue?
@gkunwar I haven't investigated the issue mentioned in my update further, I should have time tonight to look into it more. All I know currently is that there's an issue with the relation between the file model and the chunk model. This could be a bug with Mongoid, I'm not sure. When you call chunks#build
on a file object it does not have a relation like it should.
@laCour thanks for solving the issue. :+1:
@laCour Thank you. It works fine now. :)
Just merged #61. I'll work on getting a new release out soon.
A new 2.3.0 release was published this morning. Thanks all! 🍻
Mongoid seems to have small breaking changes that affect mongoid-grid_fs, if I have the time I'll make a PR for compatibility. Rails 5 doesn't seem to introduce any breaking changes here, but I may be wrong.
Changes in Mongoid 6: https://jira.mongodb.org/browse/MONGOID-4268
Update:
The only issue currently seems to be here: grid_fs.rb:154
Chunk/file associations are acting improperly, a validation error is raised upon saving chunks (i.e. "File can't be blank"). This can be hackishly fixed by forcing the association with
chunk.file = file
. I'll have to dig deeper, the issue might be caused by a breaking change but I've been unable to find any cause.