Skip to content

Instantly share code, notes, and snippets.

@jhawthorn
Last active July 4, 2018 18:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jhawthorn/480dab06ade950161d3bd0db0018538e to your computer and use it in GitHub Desktop.
Save jhawthorn/480dab06ade950161d3bd0db0018538e to your computer and use it in GitHub Desktop.
bundler vs bundler-explain: A real world Gemfile during an upgrade to Rails 5 https://github.com/jhawthorn/bundler-explain
Because quiet_assets 1.0.1 depends on railties ~> 3.1
and quiet_assets 1.0.0 depends on rails ~> 3.1,
quiet_assets 1.0.0 OR 1.0.1 requires railties ~> 3.1 or rails ~> 3.1.
And because quiet_assets >= 1.0.2, <= 1.1.0 depends on railties < 5.0, >= 3.1,
either railties < 5.0, >= 3.1 or rails ~> 3.1.
So, because rails >= 5.0.0, <= 5.0.7 depends on railties ~> 5.0.0
and root depends on rails ~> 5.0.0,
version solving has failed.
Bundler could not find compatible versions for gem "actionpack":
In test1.rb:
rails (~> 5.0.0) was resolved to 5.0.0, which depends on
actionpack (= 5.0.0)
rails-controller-testing was resolved to 1.0.1, which depends on
actionpack (~> 5.x)
rspec-rails (~> 3.7.2) was resolved to 3.7.2, which depends on
actionpack (>= 3.0)
simple_form (~> 3.2) was resolved to 3.5.1, which depends on
actionpack (< 5.2, > 4)
Bundler could not find compatible versions for gem "activemodel":
In test1.rb:
paperclip (~> 4.2.0) was resolved to 4.2.4, which depends on
activemodel (>= 3.2.0)
rails (~> 5.0.0) was resolved to 5.0.0, which depends on
activemodel (= 5.0.0)
simple_form (~> 3.2) was resolved to 3.5.1, which depends on
activemodel (< 5.2, > 4)
Bundler could not find compatible versions for gem "activerecord":
In test1.rb:
discard (~> 1.0) was resolved to 1.0.0, which depends on
activerecord (< 6, >= 4.2)
paper_trail was resolved to 9.2.0, which depends on
activerecord (< 5.3, >= 4.2)
rails (~> 5.0.0) was resolved to 5.0.0, which depends on
activerecord (= 5.0.0)
Bundler could not find compatible versions for gem "activesupport":
In test1.rb:
paperclip (~> 4.2.0) was resolved to 4.2.4, which depends on
activesupport (>= 3.2.0)
pundit was resolved to 1.1.0, which depends on
activesupport (>= 3.0.0)
rails (~> 5.0.0) was resolved to 5.0.0, which depends on
activesupport (= 5.0.0)
rails-controller-testing was resolved to 1.0.1, which depends on
activesupport (~> 5.x)
rspec-rails (~> 3.7.2) was resolved to 3.7.2, which depends on
activesupport (>= 3.0)
webpacker (~> 3.4.1) was resolved to 3.4.3, which depends on
activesupport (>= 4.2)
Bundler could not find compatible versions for gem "rails":
In test1.rb:
rails (~> 5.0.0)
Could not find gem 'rails (~> 5.0.0)' in any of the sources.
Bundler could not find compatible versions for gem "railties":
In test1.rb:
quiet_assets was resolved to 1.0.1, which depends on
railties (~> 3.1)
rails (~> 5.0.0) was resolved to 5.0.0, which depends on
railties (= 5.0.0)
source 'https://rubygems.org'
gem 'rails', '~> 5.0.0'
# Soft-deletion
gem 'paper_trail'
gem 'discard', '~> 1.0'
# auth
gem 'pundit'
gem 'devise', '~> 4.1.1'
# Forms and uploads
gem 'simple_form', '~> 3.2'
gem 'paperclip', '~> 4.2.0'
# assets
gem 'font-awesome-rails', '~> 4.7.0'
gem 'jquery-rails'
gem 'quiet_assets' # <-- comment this out to fix it
gem 'sass-rails', '~> 5.0'
gem 'webpacker', '~> 3.4.1'
group :test do
gem 'factory_bot_rails'
gem 'rails-controller-testing'
gem 'rspec-rails', '~> 3.7.2'
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment