Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Ruby

problem running rake following installation of simple forms

Hi,

I have been following the 'Build a SimpleRuby on Rails App' project. All was going well up until I encountered the follwing error message in the console following any rake command. Running bundle install makes no difference, I still get the same error message.

Could not find simple_form-2.1.0 in any of the sources Run bundle install to install missing gems.

Could anyone help please?

Thanks Dave.

Can you post your entire Gemfile?

-twiz

Yep, gonna need to see the gemfile. Can you paste it here?

Sorry for the delay.

<code> source 'https://rubygems.org'

gem 'rails', '3.2.13'

Bundle edge Rails instead:

gem 'rails', :git => 'git://github.com/rails/rails.git'

gem 'sqlite3' gem 'devise' gem "simple_form"

Gems used only for assets and not required

in production environments by default.

group :assets do gem 'sass-rails', '~> 3.2.3' gem 'coffee-rails', '~> 3.2.1'

# See https://github.com/sstephenson/execjs#readme for more supported runtimes # gem 'therubyracer', :platforms => :ruby

gem 'uglifier', '>= 1.0.3' end

gem 'jquery-rails'

To use ActiveModel has_secure_password

gem 'bcrypt-ruby', '~> 3.0.0'

To use Jbuilder templates for JSON

gem 'jbuilder'

Use unicorn as the app server

gem 'unicorn'

Deploy with Capistrano

gem 'capistrano'

To use debugger

gem 'debugger'

</code>

1 Answer

Sorry for the delay.

source 'https://rubygems.org'

gem 'rails', '3.2.13'

Bundle edge Rails instead:

gem 'rails', :git => 'git://github.com/rails/rails.git'

gem 'sqlite3' gem 'devise' gem "simple_form"

Gems used only for assets and not required

in production environments by default.

group :assets do gem 'sass-rails', '~> 3.2.3' gem 'coffee-rails', '~> 3.2.1'

# See https://github.com/sstephenson/execjs#readme for more supported runtimes # gem 'therubyracer', :platforms => :ruby

gem 'uglifier', '>= 1.0.3' end

gem 'jquery-rails'

To use ActiveModel has_secure_password

gem 'bcrypt-ruby', '~> 3.0.0'

To use Jbuilder templates for JSON

gem 'jbuilder'

Use unicorn as the app server

gem 'unicorn'

Deploy with Capistrano

gem 'capistrano'

To use debugger

gem 'debugger'

Well, first thing I'm noticing is that you're requiring two different versions of rails. The "edge" Rails is 4.1, which is a significant update to Rails 3.x.x.

Are you using a Ruby manager like RVM or rbenv to keep your versions of Ruby and gems organized? If not, I highly recommend rbenv for its relative simplicity.

One other thing, try running bundle update in Terminal to update all of the gems in your gemfile and create a new gemfile.lock.

Let us know how it goes!

I need to clarify on the Rails version. Unless you are specifically ready to update to Rails 4, stick with the version of Rails you know or the version of Rails that the tutorial uses. Also, it's good practice to include your Ruby version in the gemfile as well.

Many thanks for your reply Scott. I think the root of the problem is my lack of knowledge! I am complete newbie where Ruby and Rails are concerned. I am trying to run before I can walk and need to get back to basics.

My pleasure David. Keep it up. And if you need more assistance, just ping me on Twitter.

Thanks Scott. Have a good weekend. ;)