Saturday, July 9, 2005

Are you running the final version of Ruby 1.8.2?

Posted by admin

A fair number of people have been having problems with Rails 0.13 because it relies on behavior present in the final version of Ruby 1.8.2. That’s the one released on December 25th, 2004. You can check if you have the proper version by doing ruby -v, which should return “ruby 1.8.2 (2004-12-25)”.

If it doesn’t, you need to upgrade. Releases from before December 25th are beta releases that are not ensure to be compatible with Rails. In particular, there’s the session exception like:

NoMethodError: undefined method `new_session' for #CGI::Session:0x259f6c0

…or Proc errors like this:

/gems/actionpack-1.9.0/lib/action_controller/
code_generation.rb:68:in `dup': allocator undefined for Proc (NoMethodError)

Both tell, tell signs that your Ruby beta has exceeded its expiration date.