In Gemfile I had:
gem 'bootstrap-sass', '~> 3.0.3.0'
I have now changed it to the following, which is the latest version at the time of this writing:
gem 'bootstrap-sass', '~> 3.1.1.1'
Taking a look at both bootstrap-sass (3.0.3.0) and bootstrap-sass (3.1.1.1) on RubyGems.org, I see that both versions have runtime dependencies of:
sass ~> 3.2
Taking a look at sass itself, I see that it has no runtime dependencies, and that its latest version is:
gem 'sass', '~> 3.3.7'
After making the change mentioned above (to bootstrap-sass) I ran bundle, and saw the following:
...
Using sass 3.2.19
Installing bootstrap-sass 3.1.1.1 (was 3.0.3.0)
...
My question is why wasn't sass updated, and how can I update it without referencing it in Gemfile?
For what it's worth, here is some more info:
-bash> grep sass Gemfile.lock
bootstrap-sass (3.1.1.1)
sass (~> 3.2)
sass-rails (~> 4.0)
sass (3.2.19)
sass-rails (4.0.3)
sass (~> 3.2.0)
bootstrap-sass (~> 3.1.1.1)
sass-rails (~> 4.0.3)
As you noted, both bootstrap-sass versions (3.0.3.0 and 3.1.1.1) have a dependency of:
sass ~> 3.2
What this means is that they require the highest 3.2.x version of sass, but not 3.3. That's what the ~> means, and that is why your sass is 3.2.19.
So even if you explicitly say:
gem 'sass', '~> 3.3.7'
Bundler won't update it because it sees that bootstrap-sass depends on a lower version of sass.
Related
I am trying to install ruby gems and having the following issue. Please suggest. I am a novice in Ruby n Rails. Right now I am using Ruby 2.0.0.
Bundler could not find compatible versions for gem "nokogiri":
In Gemfile:
nokogiri (~> 1.5)
fog (~> 1.23.0) was resolved to 1.23.0, which depends on
nokogiri (~> 1.5, >= 1.5.11)
Bundler could not find compatible versions for gem "ruby":
In Gemfile:
ruby (~> 2.0.0.0)
nokogiri (~> 1.5) was resolved to 1.8.5, which depends on
ruby (>= 2.1.0)
Bundler could not find compatible versions for gem "sprockets":
In Gemfile:
activeadmin-wysihtml5 was resolved to 1.0.0, which depends on
activeadmin-dragonfly was resolved to 0.0.2, which depends on
activeadmin was resolved to 2.0.0.alpha, which depends on
sprockets (>= 3.0, < 4.1)
sass-rails (~> 4.0.3) was resolved to 4.0.3, which depends on
sprockets (~> 2.8, <= 2.11.0)
As the most easy solution I'd propose to remove versions from Gemfile i.e. instead of writing
gem 'nokogiri', '~> 1.5'
use just
gem 'nokogiri'
The same for all conflicting gems. And then try to rerun you bundle install. This would make Bundler more broad possibilities to find suitable versions. After all dependencies are installed correctly, just fix gem versions according to Gemfile.lock
I'm trying to bundle update nokogiri with gem 'nokogiri', '~> 1.7', '>= 1.7.1'
and Bundler gave me an error
Bundler could not find compatible versions for gem "nokogiri":
In Gemfile:
nokogiri (>= 1.7.1, ~> 1.7)
anemone was resolved to 0.7.2, which depends on
nokogiri (>= 1.3.0)
haml-rails was resolved to 0.9.0, which depends on
html2haml (>= 1.0.1) was resolved to 2.0.0, which depends on
nokogiri (~> 1.6.0)
quickbooks-ruby (~> 0.4.2) was resolved to 0.4.6, which depends on
nokogiri
haml-rails 0.9.0 is the latest version.. and I expected html2haml to resolve to 2.1.0 as well but it did not...
Could someone tell me what I'm missing here?
try requiring html2haml, '~> 2.1' in your gemfile. Seems like the requirements aren't smart enough to force it to upgrade from the cached version you have installed locally.
So i'm using ruby2/rails4 and trying to use the latest version of sass gem (currently 3.3.9) and i'm using compass gem to, that have a dependencie (sass 3.2.0)
so when i try to update gem i got it:
Bundler could not find compatible versions for gem "sass":
In Gemfile:
sass-rails (= 4.0.3) ruby depends on
sass (~> 3.2.0) ruby
sass (3.3.9)
i need the latest version cause sass now have a random() function it is very usefull
Install the current pre version of Compass:
gem install compass --pre
It has a Sass dependency of:
< 3.5, >= 3.3.0
so it should be compatible with that version of Sass and allow random(). See https://rubygems.org/gems/compass/versions/1.0.0.alpha.21 for more on the alpha version of Compass.
I'm trying to update my Rails 4.0 app to 4.1. The app uses sass-rails, and when I try to update it using bundle update rails I get the following error:
Bundler could not find compatible versions for gem "railties":
In Gemfile:
rails (= 4.1) ruby depends on
railties (= 4.1.0) ruby
sass-rails (~> 4.0) ruby depends on
railties (4.1.1)
Any idea how to work around it or fix it?
The latest version of sass rails solves this issue:
gem 'sass-rails', '~> 5.0.0.beta1'
From comments, update to:
gem 'rails', '~> 4.1.1'
Updating bundler solved this for me:
gem install bundler
Apparently there was a bug in older bundlers.
Taken from related question: sass-rails requires sprockets 2.0.0 but rails 4.1.0 requires sprockets 2.12.1
I just spent 1h trying to add susy 2 to my project... Thamn are those dependencies a bi*ch... To set up rails 4, sass-rails, compass-rails and susy I changed my Gemfile into:
gem 'rails', '~> 4.1.1'
gem 'sass-rails', '~> 5.0.0.beta1'
gem 'compass-rails'
gem 'susy'
What I didn't want to do, but ended up doing is updating rails from 4.0.3 to 4.1.1 and what bothers me even more is using sass-rails 5.0.0.beta1
My rails version is 3.2.12.
I am trying to implement gem "joyride-rails", "~> 0.0.14" in my application, but it clashes with some of my other gems. Already in my Gemfile:
gem "haml-rails", ">= 0.4"
gem 'activeadmin-mongoid', github: 'elia/activeadmin-mongoid', branch: 'active-admin-spec-suite'
When I run the bundle command, I get this error:
Bundler could not find compatible versions for gem "haml":
In Gemfile:
joyride-rails (~> 0.0.14) ruby depends on
haml (~> 3.1) ruby
haml-rails (>= 0.4) ruby depends on
haml (4.0.3)
So, if I add the gem "haml", "~> 4.0.3" the new bundle clash is:
Bundler could not find compatible versions for gem "bourbon":
In Gemfile:
joyride-rails (~> 0.0.14) ruby depends on
bourbon (~> 2.0) ruby
activeadmin-mongoid (>= 0) ruby depends on
bourbon (3.1.8)
And if I then add the gem "bourbon", "~> 3.1.8" I get this new clash:
Bundler could not find compatible versions for gem "bourbon":
In Gemfile:
joyride-rails (~> 0.0.14) ruby depends on
bourbon (~> 2.0) ruby
bourbon (3.1.8)
What to do?
Github Issue
The gem currently can't be used with the latest version of haml. (c)
I think, u can downgrade your haml version, if possible.