'gem install rails' error

M

Mark Hubbart

Hi,
I finally decided I had the time to try out the Rails framework, so I
went to install it via rubygems. All the dependencies installed fine,
but I got an error when it tried to install the rails gem itself. I
searched the mailing list, but didn't find any solutions to this
particular problem. Here is the output of 'gem install' and 'gem
list':

mark@eMac% sudo gem install rails
Password:
Attempting local installation of 'rails'
Local gem file not found: rails*.gem
Attempting remote installation of 'rails'
Updating Gem source index for: http://gems.rubyforge.org
Install required dependency rake? [Yn] y
Install required dependency activerecord? [Yn] y
Install required dependency actionpack? [Yn] y
ERROR: While executing gem ... (NameError)
(eval):1:in `class_eval': uninitialized class variable
@@inheritable_attributes_for_base in
CGI::Session::ActiveRecordStore::Session


mark@eMac% gem list --local

*** LOCAL GEMS ***

actionpack (0.8.5)
Web-flow and rendering framework putting the VC in MVC.

activerecord (0.9.5)
Implements the ActiveRecord pattern for ORM.

rake (0.4.8)
Ruby based make-like utility.

sources (0.0.1)
This package provides download sources for remote gem installation

<some irrelevant items snipped from this list>

Any help would be appreciated.

Thanks,
Mark
 
D

David Heinemeier Hansson

I finally decided I had the time to try out the Rails framework, so I
went to install it via rubygems. All the dependencies installed fine,
but I got an error when it tried to install the rails gem itself.

Are you running Ruby 1.9? Rails 0.7 has a problem that. It should be
fixed in the upcoming release among a thousand other things. It's okay
to hold your breath. "Real soon now", he said :)
--
David Heinemeier Hansson,
http://www.basecamphq.com/ -- Web-based Project Management
http://www.rubyonrails.org/ -- Web-application framework for Ruby
http://macromates.com/ -- TextMate: Code and markup editor (OS X)
http://www.loudthinking.com/ -- Broadcasting Brain
 
G

Gavin Sinclair

Are you running Ruby 1.9? Rails 0.7 has a problem that. It should be
fixed in the upcoming release among a thousand other things. It's okay
to hold your breath. "Real soon now", he said :)

You can make that clear in the gemspec (untested):

spec.required_ruby_version = ['> 1.8.1', '< 1.9.0']

That would help avoid the problem, if that's the cause here.

Cheers,
Gavin
 
M

Mark Hubbart

Are you running Ruby 1.9? Rails 0.7 has a problem that.

Well, that would be the problem :) 1.9 is so stable that I keep
forgetting that it's not :) I should probably move back to 1.8.2
stable, but I'm addicted to some of 1.9's features.
It should be
fixed in the upcoming release among a thousand other things. It's okay
to hold your breath. "Real soon now", he said :)

Oooh! Okay, I'll wait for that. :)

Thanks,
Mark
 
G

Gavin Sinclair

Well, that would be the problem :) 1.9 is so stable that I keep
forgetting that it's not :) I should probably move back to 1.8.2
stable, but I'm addicted to some of 1.9's features.

What features?

Gavin
 
M

Mark Hubbart

What features?

Almost missed this one :)

Really, now that I think about it, there isn't that much. The big one
is the new hash literal syntax, which I would hate to lose. (I use irb
as my shell a lot, and end ups typing in hashes more often than you
might expect :) The new regexp engine is very nice, but that's not
really a reason, since you *can* compile it into older versions of
ruby...

I know there were some other changes, but I can't think of them right
now. I'll probably discover them as I begin working with 1.8 again.

cheers,
Mark
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,770
Messages
2,569,584
Members
45,075
Latest member
MakersCBDBloodSupport

Latest Threads

Top