views:

77

answers:

3

I just recently switched to Rails 3. I have been through several installation problems and still is unable to do the stuff that I could do in Rails 2. Right now for some reason when I want to do

rake db:migrate

I get the following error

rake aborted!
uninitialized constant ActiveSupport::CoreExtensions
/Users/denniss/Sites/mp/Rakefile:4:in `require'

My Rakefile looks like this

require File.expand_path('../config/application', __FILE__)

require 'rake'
require 'rake/testtask'
require 'rake/rdoctask'

Moolah::Application.load_tasks
A: 

From the error you get I would say that you have a problem with activesupport gem. Either it's not installed (at least proper version is not installed) or it's not loaded for some reason.

Try listing your gems with "gem list" and see what versions of activesupport gem you have and if they match Rails gem versions.

Slobodan Kovacevic
+2  A: 

Also be careful with the ruby version you have. I had ruby 1.9.2 preview (I installed it before a year) when I was first tried rails 3 and nothing was working as I expected... I updated to the new version and now everything is working smooth.

JohnDel
Good point. To add to that: ruby 1.9.1 is not supported in Rails3! So you either need to use ruby 1.8.7 or ruby 1.9.2.
nathanvda
+1  A: 

I don't think the problem is related to the db:migrate rask -- I think your rails environment isn't fully setup yet. Things to try:

Confirm that your config/application.rb looks somewhat like the following

require File.expand_path('../boot', __FILE__)

require 'rails/all'

Bundler.require(:default, Rails.env) if defined?(Bundler)

module Moolah
  class Application < Rails::Application
...

Do a bundle install from your root directory

bundle install

Then try to get into your console

rails console

Once that all works, your app is "rails 3" and can then rake db:migrate

Jesse Wolgamott