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 trialOsgaldor Storm
1,119 PointsRails: Weird error/problem with bundler
Hi everyone! I'm having a very odd problem. I have tried to install several gems from the command line with gem install, It goes through its stuff and says it installed the gem, but when I type bundle show for them I just installed it sayd it can't find that gem in any repository. When I try to invoke a generator for an installed gem like devise, It errors out saying it can't find the generator or the gem. Have you ever seen this before? What is the problem. it was all working fine before on earlier practice projects, but now that i'm ready to build my 'real' projects, I'm having this freaky problem.
25 Answers
Tuan Pham
11,207 PointsHi Osgaldor. That is not a odd problem. A lot of people get that error. Ok, let me explain about your error. I have 2 things to say about it. First, when you typed gem install " name_gem" or here is Devise gem, you actually didn't install on your project. You installed on your RVM library. Second, when you try to use gems, you should add gems you want in your Gemfile. So, now you should try to add gems to your Gemfile like gem 'devise' or gem 'cancan' and run bundle install and you can get back to your project.
Osgaldor Storm
1,119 PointsI put it in the gem file too, same error!
Tuan Pham
11,207 PointsMake sure you run bundle install or bundle up.
Osgaldor Storm
1,119 PointsI get errors saying that it can't find simple_file I've even tried to install that gem, it says it installed it, but it doesn't turn up in my system.
Osgaldor Storm
1,119 PointsWhen I ran bundle up I got the error message that said "DL is deprecated, please use fiddle" I tried to install Fiddle and got the same success message, but it isn't here.
Tuan Pham
11,207 Points' DL is deprecated, please use Fiddle ' is actually a warning. The warning message comes out when you require 'irb' ( because irb require 'readline' ) or anything else wants to require 'readline'. If you feel it's annoying, you can comment out it at C:\Ruby200\lib\ruby\2.0.0\dl.rb.
Osgaldor Storm
1,119 PointsWhen I ran bundle up I got the error message that said "DL is deprecated, please use fiddle" I tried to install Fiddle and got the same success message, but it isn't here.
Osgaldor Storm
1,119 Points DL is deprecated, please use Fiddle
Fetching gem metadata from https://rubygems.org/.........
Fetching additional metadata from https://rubygems.org/..
Resolving dependencies...
Could not find gem 'simple_file (>= 0) x86-mingw32' in the gems available on
this machine.
Tuan Pham
11,207 PointsLet's try this: sudo gem update --system
Osgaldor Storm
1,119 Pointsthat's the error I get.
Osgaldor Storm
1,119 PointsI'm on Windows, does sudo work?
Osgaldor Storm
1,119 PointsNope, it does not.
Osgaldor Storm
1,119 Points ERROR: While executing gem ... (OptionParser::AmbiguousOption)
ambiguous option: -system
Tuan Pham
11,207 PointsCan you paste your Gemfile?
Tuan Pham
11,207 PointsCan you paste your Gemfile?
Osgaldor Storm
1,119 PointsI tried:
gem update -system
Tuan Pham
11,207 Pointsgem update --system
Osgaldor Storm
1,119 PointsI tried running it without the flag, just as gem update system
and I got ```
Updating installed gems
Nothing to update
```
Tuan Pham
11,207 Pointstry this: gem update --system (with two flag)
Osgaldor Storm
1,119 PointsThis is so crazy! What's wrong?
Osgaldor Storm
1,119 PointsGemfile ```ruby source 'https://rubygems.org'
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '4.0.3'
# Use sqlite3 as the database for Active Record
gem 'sqlite3'
# Use SCSS for stylesheets
gem 'sass-rails', '~> 4.0.0'
# Use Uglifier as compressor for JavaScript assets
gem 'uglifier', '>= 1.3.0'
# Use CoffeeScript for .js.coffee assets and views
gem 'coffee-rails', '~> 4.0.0'
gem 'devise'
gem 'simple_file'
gem 'thesilverspoon'
# See https://github.com/sstephenson/execjs#readme for more supported runtimes
# gem 'therubyracer', platforms: :ruby
# Use jquery as the JavaScript library
gem 'jquery-rails'
# Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
gem 'turbolinks'
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
gem 'jbuilder', '~> 1.2'
group :doc do
# bundle exec rake doc:rails generates the API under doc/api.
gem 'sdoc', require: false
end
# Use ActiveModel has_secure_password
# gem 'bcrypt-ruby', '~> 3.1.2'
# Use unicorn as the app server
# gem 'unicorn'
# Use Capistrano for deployment
# gem 'capistrano', group: :development
# Use debugger
# gem 'debugger', group: [:development, :test]
```
Tuan Pham
11,207 PointsOh, I saw it. In your gemfile, gem 'simple_file', I've checked on rubygems.org. It doesn't have simple_file gem. Gemfile is looking for simple_file gem on rubygems.org but Gemfile couldn't find it.
Osgaldor Storm
1,119 Pointshow do I check for rubygems and devkit? I know I have rails because I can start the rails server and run the generators.
Osgaldor Storm
1,119 PointsI definitely have ruby version 2
ruby 2.0.0p247 (2013-06-27) [i386-mingw32]
Tuan Pham
11,207 PointsSorry for correcting too much. Ok, you should follow this: http://rubyinstaller.org/. This website in Download section has Devkit for Windows.
Osgaldor Storm
1,119 PointsI'm re-downloading it now.
Tuan Pham
11,207 PointsOk, follow rubyinstaller.org and make sure you have Devkit on your Windows.
Osgaldor Storm
1,119 PointsThank you. I have also had fatal problems trying to install twitter-bootstrap-rails, it fails over the libv8 gem.
Osgaldor Storm
1,119 PointsThank you. I have also had fatal problems trying to install twitter-bootstrap-rails, it fails over the libv8 gem.
Osgaldor Storm
1,119 PointsThank you. I have also had fatal problems trying to install twitter-bootstrap-rails, it fails over the libv8 gem.
Osgaldor Storm
1,119 PointsThank you. I have also had fatal problems trying to install twitter-bootstrap-rails, it fails over the libv8 gem.
Vic G
Courses Plus Student 390 Pointshi do you guys know if there are any tracks that focus on web ui test automation? ie, clicking on buttons, entering text fields etc??