Rubygems 0.9.5 and Rails 1.2.6 – uninitialized constant Gem::GemRunner

This morning I update my Rails installation to 1.2.6 and that is why I need to have a new local copy of Rails 1.2.6 API documentation. I usually get my local API documentation using these steps:

  1. rails dummy
  2. cd dummy
  3. rake rails:freeze:gems
  4. rake doc:rails
  5. mv doc/api ~/docs/ruby/rails/

and then I have my local API docs at $HOMOE/docs/ruby/rails/api/

That was when everything worked fine. This morning, those steps result error which I suspect from gem:

uninitialized constant Gem::GemRunner

So I began searching. Luckily I found this:

Then I edited this file:


and add require ‘rubygems/gem_runner’ between these lines:

      deps = %w(actionpack activerecord actionmailer activesupport actionwebservice)
      require 'rubygems'
      require 'rubygems/gem_runner'

Everything runs well now 🙂

7 comments so far

  1. Andry on

    I have found that I need to re-create dummy app (e.g complete remove dummy and recreate dummy again) after having framework.rake edited.

    Apparently issuing rake:freeze:gems without edited framework.rake will create empty dummy/vendor/rails/ and that’s how the problem start.

    I run rails 1.2.6 and rubygems 0.9.5 also on LinuxMint 4.0.

  2. […] isn’t required automatically now, which breaks the freezing of Rails. Florian Aßmann, bpdp have the fix: adding the require to […]

  3. Steve Harris on

    Newbie question:

    Why do you ‘rails:freeze:gems’ before ‘doc:rails’ ?


    – Steve

  4. tedster on

    Andry, I also saw that problem after editing my framework.rake file.

    I deleted the vender/rails subdirectory and fixed it (messes up my svn, but that’s easily fixed).

  5. A thankful person on

    Thanks – this helped me a ton!

  6. Jared on

    Thanks, that saved me. I did have to delete the empty vendor/rails directory before it would work.

  7. Dirceu Jr. on


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: