[Locomotive-users] RMagick -> Ruby crashes

Sander Heilbron sanderheilbron at wanadoo.nl
Thu Jun 1 17:27:46 GMT 2006


Hi Ryan,

I created the same application without any problems by using  
Locomotive 1.0.0. and Rails 1.1.1 Max.

When I make use of Locomotive 2, the Console app gives me the same  
errors which Steve reported:

Jun  1 19:14:24 sander-heilbrons-powerbook-g4-15 crashdump[465]: ruby  
crashed
Jun  1 19:14:24 sander-heilbrons-powerbook-g4-15 crashdump[465]:  
crash report written to: /Users/sanderheilbron/Library/Logs/ 
CrashReporter/ruby.crash.log

Enjoy your holiday and I hope to hear from you soon.

Cheers,
Sander





On May 27, 2006, at 1:40 PM, Ryan Raaum wrote:



On 5/26/06, Sander Heilbron <sanderheilbron at wanadoo.nl> wrote:
Hi Ryan,

Hi Sander,

I'll look into this at my first opportunity, but I'm packing up and  
moving to Florida this weekend, so I might not be able to sit down  
and really look at it until next weekend...

Best,

-r

This is what I have:

controller:
class ExamplesController < ApplicationController
     def list
       @images = Image.find_all
     end

     def new
       if request.method == :post
         @image = Image.create params[:image]
       elsif request.method == :get
         @image = Image.new
       end
     end
   end

model:
class Image < ActiveRecord::Base
   file_column :file, :magick => { :geometry => "640x480",
          :versions => { "thumb" => "128x64", "medium"=>"320x240"}
        }
end

view:
<%= form_tag({ :action => "new"}, :multipart => true) %>
<fieldset>
<legend>Add an image</legend>
<label for="image[title]">Title: </label><%= text_field :image,:title %>
<label for="image[file]">Image: </label><%= file_column_field 
('image','file')%>
<%= submit_tag 'Add image'%>
</fieldset>
<%= end_form_tag %>
<%= link_to "View images", :action => "list" %>

Without the code below in the model it works ok:
, :magick => { :geometry => "640x480",
          :versions => { "thumb" => "128x64", "medium"=>"320x240"}
        }

Maybe I'm doing something wrong, hope you can tell me.

Thanks,
Sander



On May 26, 2006, at 1:26 AM, Ryan Raaum wrote:



On 5/25/06, Sander Heilbron < sanderheilbron at wanadoo.nl> wrote:
Have no idea how to do it just with Ruby, but everything I try does  
not work. Nothing shows up and the CPU usage (Ruby process) rises up  
to 90%  or more.


I believe that solving your problem will be substantially easier if  
you are able to use RMagick in a simple ruby script that does what  
you want instead of trying to debug an entire rails stack + plugins.

What exactly are you trying to do?

-r

On May 25, 2006, at 8:23 PM, Ryan Raaum wrote:



On 5/25/06, Sander Heilbron < sanderheilbron at wanadoo.nl> wrote:
I had the first version installed, but then I downloaded and tried  
the second one, unfortunately without success.

rgds,
Sander

On May 25, 2006, at 5:04 PM, Ryan Raaum wrote:



On 5/25/06, Sander Heilbron < sanderheilbron at wanadoo.nl> wrote:
Hi,

I'm building a simple file upload app by using file_column. But when  
I want to resize the images by using RMagick, Ruby crashes. What  
could be wrong? When I add the necessary code for RMagick to my model  
and reload the 'upload page' the page cannot load. Without this code,  
uploading works fine.

Can you do the RMagick transformations from regular ruby code? (i.e.  
not rails)


I'm using OSX 10.4.6, Locomotive 2.0.7 and Framework 1.1.2 + RMagick

Is it the most recent +RMagick bundle?  (There is a 1st and 2nd  
version.)

-r

Hope you can help me.

Thanks,
Sander


_______________________________________________
Locomotive-users mailing list
Locomotive-users at lists.raaum.org
http://lists.raaum.org/mailman/listinfo/locomotive-users





-- 
Ryan Raaum
http://www.rockefeller.edu -- Bacterial Pathogenesis and Immunology
http://www.worldmartial.com -- Black Belt Instructor
http://locomotive.raaum.org -- Self contained one-click Rails for Mac  
OS X
_______________________________________________
Locomotive-users mailing list
Locomotive-users at lists.raaum.org
http://lists.raaum.org/mailman/listinfo/locomotive-users


_______________________________________________
Locomotive-users mailing list
Locomotive-users at lists.raaum.org
http://lists.raaum.org/mailman/listinfo/locomotive-users





-- 
Ryan Raaum
http://www.rockefeller.edu -- Bacterial Pathogenesis and Immunology
http://www.worldmartial.com -- Black Belt Instructor
http://locomotive.raaum.org -- Self contained one-click Rails for Mac  
OS X
_______________________________________________
Locomotive-users mailing list
Locomotive-users at lists.raaum.org
http://lists.raaum.org/mailman/listinfo/locomotive-users


_______________________________________________
Locomotive-users mailing list
Locomotive-users at lists.raaum.org
http://lists.raaum.org/mailman/listinfo/locomotive-users





-- 
Ryan Raaum
http://www.rockefeller.edu -- Bacterial Pathogenesis and Immunology
http://www.worldmartial.com -- Black Belt Instructor
http://locomotive.raaum.org -- Self contained one-click Rails for Mac  
OS X
_______________________________________________
Locomotive-users mailing list
Locomotive-users at lists.raaum.org
http://lists.raaum.org/mailman/listinfo/locomotive-users


_______________________________________________
Locomotive-users mailing list
Locomotive-users at lists.raaum.org
http://lists.raaum.org/mailman/listinfo/locomotive-users





-- 
Ryan Raaum
http://www.rockefeller.edu -- Bacterial Pathogenesis and Immunology
http://www.worldmartial.com -- Black Belt Instructor
http://locomotive.raaum.org -- Self contained one-click Rails for Mac  
OS X
_______________________________________________
Locomotive-users mailing list
Locomotive-users at lists.raaum.org
http://lists.raaum.org/mailman/listinfo/locomotive-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://one.textdrive.com/pipermail/locomotive-users/attachments/20060601/e48eeb0a/attachment.htm


More information about the Locomotive-users mailing list