Error message: Bundler could not find compatible versions for gem "spree_core":
*In Gemfile:
spree_paypal_express (>= 0) ruby depends on
spree_core (>= 1.0.0) ruby
spree (= 0.50.2) ruby depends on
spree_core (0.50.2)*
When I do rails --version, I get:
git://github.com/shuber/sortable.git (at master) is not checked out. Please run `bundle install`
Have tinkered with the .bashrc profile as suggested by other StackOverflow posts, 'bundle update' gives the same error message as the first one above.
Mac OS X Lion
Rails 3.0.7
ruby 1.8.7 (2011-02-18 patchlevel 334) [i686-darwin11.3.0], MBARI 0x6770, Ruby Enterprise Edition 2011.03
'rvm gem list bundler' returns 1.1.3 and 1.1.3 only, on my working environment with this git clone I have bundler 1.1.3 and 1.0.22.
Thoughts? Not really sure what to do at this point. I tried deleting Gemfile.lock and running bundle install again, but no success.
How are you specifying the spree gem in your Gemfile? The error message seems to say you're specifying one version of 'spree' (possibly =0.50.2), while spree_paypal_express is requiring another version (>= 1.0.0).
I'm not too familiar with bundler, so I can't say for certain. Maybe posting your Gemfile can help us find more leads for you?
Good luck!
Related
I have an ROR application from which I am trying to execute vagrant up command in the following way system("vagrant up")
I am getting the below error
Vagrant experienced a version conflict with some installed plugins!
This usually happens if you recently upgraded Vagrant. As part of the
upgrade process, some existing plugins are no longer compatible with
this version of Vagrant. The recommended way to fix this is to remove
your existing plugins and reinstall them one-by-one. To remove all
plugins:
rm -r ~/.vagrant.d/plugins.json ~/.vagrant.d/gems
Note if you have an alternate VAGRANT_HOME environmental variable
set, the folders above will be in that directory rather than your
user's home directory.
The error message is shown below:
Bundler could not find compatible versions for gem "bundler":
In Gemfile:
vagrant (= 1.7.2) x86-mingw32 depends on
bundler (< 1.8.0, >= 1.5.2) x86-mingw32
Current Bundler version:
bundler (1.10.0.pre.2)
This Gemfile requires a different version of Bundler.
Perhaps you need to update Bundler by running `gem install bundler`?
Could not find gem 'bundler (< 1.8.0, >= 1.5.2) x86-mingw32', which is required by gem 'vagrant (= 1.7.2) x86-mingw32', in any of the sources.
I have tried to do gem install bundler , it always installs bundler 1.9.9
If i try to execute vagrant up from command line it works fine
Below are the versions which I am using
ruby -> 2.1.6p336 (2015-04-13 revision 50298) [x64-mingw32]
Vagrant -> 1.7.2
Rails -> 4.2.1
Any sort of help is much appreciated
I'm new to Rails, following Michael Hartl's textbook. When I run $ bundle install I get the following error:
Bundler could not find compatible versions for gem "bundler":
In Gemfile:
rails (= 3.0.1) ruby depends on
bundler (~> 1.0.0) ruby
Current Bundler version:
bundler (1.7.6)
This Gemfile requires a different version of Bundler.
Perhaps you need to update Bundler by running `gem install bundler`?
I then try $ gem install bundler which works fine:
Successfully installed bundler-1.7.6
Parsing documentation for bundler-1.7.6
1 gem installed
However, this doesn't solve the problem. I'm sensing this has something to do with version problems, but I'm not sure where to go with it...
The following :
In Gemfile:
rails (= 3.0.1) ruby depends on
bundler (~> 1.0.0) ruby
means the version of bundler required is greater than or equal to 1.0.0 but strictly less than 1.1.0. Rails 3 is depending on an old version of bundler. At this point of time, you should try out Rails 4 instead :)
You may read up more about the "version syntax" in http://guides.rubygems.org/patterns/#pessimistic_version_constraint
As #user3927334 has already stated the error you got is due to a version conflict between bundler and rails.
Most likely you have run rails new my_app with an outdated version of the rails gem.
gem install rails -v 4.2.0.beta4
Can be used to install a particular version of Rails. see Installing Rails.
You should then remove your old app and rerun the app generator:
rails _4.2.0.beta4_ new hello_app
If you indent to develop on your local machine I would recommend installing RVM (Ruby Version Manager) (as did previous versions of MH's Ruby on Rails Tutorial.)
It allows you to effortlessly switch between different versions of ruby and different sets of gems.
I'm having a dearly hard time getting my rails environment up. Here is the issue.
$ gem install rails --version 3.0.1
Successfully installed rails-3.0.1
1 gem installed
Installing ri documentation for rails-3.0.1...
Installing RDoc documentation for rails-3.0.1...
$ rails -v
/.rvm/rubies/ruby-1.9.2-p320/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:1637:in `raise_if_conflicts': **Unable to activate rails-3.0.1, because bundler-1.1.5 conflicts with bundler (~> 1.0.0) (Gem::LoadError)**
from /.rvm/rubies/ruby-1.9.2- p320/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:746:in `activate'
from /.rvm/rubies/ruby-1.9.2-p320/lib/ruby/site_ruby/1.9.1/rubygems.rb:1232:in `gem'
from /.rvm/gems/ruby-1.9.2-p320#rails3tutorial/bin/rails:18:in `<main>'
from /.rvm/gems/ruby-1.9.2-p320#rails3tutorial/bin/ruby_noexec_wrapper:14:in `eval'
from /.rvm/gems/ruby-1.9.2-p320#rails3tutorial/bin/ruby_noexec_wrapper:14:in `<main>'
Here in lies the issue. I've reinstalled ruby. I've installed 1.8.7, 1.9.2, 1.9.3 and still no luck across the board.
i've run
$ gem update bundler
But bundle is 'up to date', so still no luck
I've really poked at this all day now, and with no luck I open my palms to you all.
the issue is that in #global gemset you have higher version of bundler then the one required.
you can either specify the version on command line:
bundle _1.0.27_ exec rails -v
or use Gemfile:
printf 'source :rubygems\ngem "rails", "3.0.1"\n'
rails -v
this assumed you have the gem rubygems-bundler - but it comes by default with RVM so you should have it.
and last - remove bundler from #global:
rvm #global do gem uninstall bundler
but there is one caveat - while reinstalling ruby gem bundler will be installed again.
so I run:
$ gem install rails --version 3.0.1
Successfully installed rails-3.0.1
1 gem installed
Installing ri documentation for rails-3.0.1...
Installing RDoc documentation for rails-3.0.1...
then I get the error:
$ rails -v
/usr/local/rvm/rubies/ruby-1.9.3-p125/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:1637:in `raise_if_conflicts': Unable to activate rails-3.0.1, because bundler-1.1.4 conflicts with bundler (~> 1.0.0) (Gem::LoadError)
from /usr/local/rvm/rubies/ruby-1.9.3-p125/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:746:in `activate'
from /usr/local/rvm/rubies/ruby-1.9.3-p125/lib/ruby/site_ruby/1.9.1/rubygems.rb:1232:in `gem'
from /usr/local/rvm/gems/ruby-1.9.3-p125#rails3tutorial/bin/rails:18:in `<main>'
from /usr/local/rvm/gems/ruby-1.9.3-p125#rails3tutorial/bin/ruby_noexec_wrapper:14:in `eval'
from /usr/local/rvm/gems/ruby-1.9.3-p125#rails3tutorial/bin/ruby_noexec_wrapper:14:in `<main>'
So Rails 3.0.1 requires Bundler v1.0.0 - v1.0.22 (actually any 1.0.x version up to, but not including, 1.1.0), but you have a newer version of Bundler that's being loaded when Rails is started. You could uninstall the newer version(s) of Bundler (though this is a crappy way to deal with the issue) or since you're using RVM, just create a gemset for Rails 3.0.1.
$ rvm gemset create rails_3.0.1
$ rvm gemset use rails_3.0.1
$ gem install rails -v 3.0.1
$ rails -v
3.0.1
Note: this requires that Bundler not be in your global gemset for the Ruby version you're trying to use. If the global gemset contains a Bundler version equal to or higher than 1.1.0 then you'll get the same error as before.
Update: A little explanation about ~> and RubyGems versioning might be handy. The section on pessimistic version constraint in the RubyGems docs does a fantastic job of covering everything.
You may need to update to bundler 1.1.4.
gem update bundler
should do the trick.
This is possibly due to Ruby v1.9.2/3 uses bundler v1.1.4 while Rails v3.0.1 requires bundler v~1.0.0. Hence, by simply updating the Rails version to v3.2.6, the conflict is solved. This conflict can be easily solved by matching the Ruby and Rails version.
I had same problem with mysql. I uninstalled mysql gem and I installed the newest version of mysql gem. Is RVM ok?
EDIT:
I'm an idiot -- I figured out the problem. In a gem I had written a while back, I had VERSION='0.0.1', and for some reason that overrode the version number of bundler.
Won't do that again...
Some background information: on an OS X Lion computer I'm using RVM with Macruby on a Rails 3.0.7 project. I set Macruby and my current gemset to be the default. When I try to run bundle install, I get the following message:
Bundler could not find compatible versions for gem "bundler":
In Gemfile:
bundler (~> 1.0)
Current Bundler version:
bundler (0.0.1)
Your version of Bundler is older than the one requested by the Gemfile.
Perhaps you need to update Bundler by running `gem install bundler`.
When I run gem list bundle, it shows exactly one installation at version 1.0.18. I suspect that somehow the RVM default setting is not applied all the way through the system. But the system ruby does not have any bundler installed, much less this elusive 0.0.1.
Anybody know what might be going on here?
Could it be possible that your bundle executable is still pointing to an old version of the gem?