Some Notes about Problems I Had Updating Ruby Gems on Debian GNU Linux

March 26th, 2009

I kept on getting:

/usr/bin/gem:14: undefined method `ruby_version' ...

on a debian machine whenever I tried using gem. I ended up commenting out a few lines, then installing the latest version of rubygems-update from here with:

gem install rubygems-update-1.3.1.gem

Looks like it worked, but not for the real problem I was trying to solve. This was to try and solve this problem:

ActionView::TemplateError (undefined method `[]'

Which was solved thanks to these pages:

Re: [SOVED] AJAX error: ActionView::TemplateError (undefined method `[]'..


undefined method for enumerable

The actual fix was to put:

unless '1.9'.respond_to?(:force_encoding)  String.class_eval do    begin      remove_method :chars    rescue NameError      # OK    end  end

at the beginning of config/environment.rb.

Yearly Indexes: 2003 2004 2006 2007 2008 2009 2010 2011 2012 2013 2015 2019 2020 2022