Sam
2006-Feb-15 17:06 UTC
[Rails] file_column / Rmagick "invalid image" when image is valid
So I''ve recently finished up my first RoR application and made sure it all worked right on the windows machine i developed it on. then deployed it on GeekISP.com which runs Open/Free BSD. I had to jump through a few little hoops to get it working and set the permissions for rails to create directories, but it still doesnt work right. When i go to add a new item to the database and try adding a picture with the entry, even if the picture is valid (all lowercase, no special chars in the name), and i can verify it, the rmagick check for a valid image returns it invalid when i try to add it. i know it can upload the image becuase i can check it made a tmp directory and uploaded the picture through the shell, but it wont resize it or create a thumb nail like it should, and does on my machine. 1 error prohibited this equipment from being saved There were problems with the following fields: Image invalid im pretty sure that part was generated by this code from within file column. from "/file-column/lib/magick_file_column" <code> class BaseUploadedFile # :nodoc: def transform_with_magick if needs_resize? begin img = ::Magick::Image::read(absolute_path).first rescue ::Magick::ImageMagickError @magick_errors ||= [] @magick_errors << "invalid" return end </code> now im wondering what do i need to do or change to get this working right? it really bugs me becuase it works fine on my box, and the error it gives doesnt tell me much about what is happening, the logs dont seem to show anything helpful either. -Sam -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060215/2dfe3a78/attachment.html