Bundler is not compatible with Rubygems 2.0. Please upgrade to Bundler 1.3 or higher
Asked Answered
D

3

13

I am deploying a Ruby on Rails application and part of the startup script that I have when provisioning a new box is gem update --system.

This happened to upgrade Rubygems to version 2.0. however, it looks like bundler is not compatible with this newer version of Rubygems.

Bundler is not compatible with Rubygems 2.0.
Please upgrade to Bundler 1.3 or higher.

Has anyone seen this or found a workaround?

Daddy answered 25/2, 2013 at 2:58 Comment(0)
D
18

Updating to the prerelease of bundler fixed it.

gem install bundler --pre
Daddy answered 25/2, 2013 at 3:0 Comment(5)
That isn't working for me, installing "bundler --pre" hasn't solved the problem in my case. The app is using Rails 3.2.12 and Ruby 2.0.0p0.Intensify
What version of Bundler are you using? What version of gem?Daddy
gem version 2.0.0 and bundler version 1.3.0Intensify
Took this as an opportunity to install Rails 4 with Ruby 2.0.0 and no go, getting the error: $gem install rails --pre ERROR: While executing gem ... (Gem::DependencyError) Unable to resolve dependencies: rails requires activesupport (= 4.0.0.beta1), actionpack (= 4.0.0.beta1), activerecord (= 4.0.0.beta1), actionmailer (= 4.0.0.beta1), railties (= 4.0.0.beta1), sprockets-rails (~> 2.0.0.rc3)Intensify
Wow, I'm sure glad I have my Ruby 1.9.3p374 install to fall back on. A word of warning to all: DO NOT DO A "gem update --system", else you risk totally messing up your Ruby installation with no chance of recovery until this issue is solved. Wish I had the time to dig into it.Intensify
B
4

I had the same problem and, since I was using RVM, I fixed it with the following command:

rvm rubygems 1.8.25

If you are not using RVM, you could just try the following:

rubygems 1.8.25

This should remove your Rubygems 2.0 and allow Bundler to work again.

Balaam answered 26/2, 2013 at 16:59 Comment(0)
C
0

As it is written here, in order to install prereleases using RubyGems 2.0 you must specify the version and disable ri and rdoc:

gem install rails --version=4.0.0.beta1 --no-ri --no-rdoc

This works with bundler 1.3.0 too.

Clementeclementi answered 1/3, 2013 at 21:0 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.