galetahub/ckeditor — Issue #96: image uploads: carrierwave/minimagick problem with tmp files
Author: mark100net
Created: 2012-03-03 22:14:14+00:00
State: open

I am trying to upload files from the ckeditor gem in a rails 3.2.1 app using Carrierwave/minimagic.

I am on OSX 10.6

If I try to use MiniMagick, I get the following error:

Errno::ENOENT (No such file or directory - identify -ping /var/folders/wK/wKG0M7udG5K7cAjGxTF86k+++TI/-Tmp-/mini_magick20120303-72546-1sg4xlv.jpeg):

It appears to be expecting the tmp file to be in that location, but it is putting them in public/uploads/tmp (the file is still there after this happens).

If I turn off MiniMagick (by commenting out the include in ckeditor_picture_uploader and removing the resizing code), I get a different error:

ArgumentError (Version content doesn't exist!):
app/models/ckeditor/asset.rb:4:in `url'
app/models/ckeditor/picture.rb:5:in `url_content'

In the latter case the file actually ends up in the public/uploads directory, but I am still not able to use it due to:

I also get the "Version content doesn't exist" error if I just open the image link dialog and press "Browse Server" (meaning I get the error as soon as I hit the button, not after I select a file, which I can't do because of the error).

I have not modified the asset.rb and picture.rb created by the generator.

Any help would be appreciated.