rubygems / bundler

Manage your Ruby application's gem dependencies
https://bundler.io
MIT License
4.88k stars 2k forks source link

Bundle Install Issue #5861

Closed chijoy closed 7 years ago

chijoy commented 7 years ago

I've been using Rails for about a year now. I just cloned a repository that I've been asked to take over. After cloning, I ran rake db:setup, per the README instructions. I received an error that version 2.3.1 wasn't installed. I used rbenv to install 2.3.1, than I set it up locally. I tried rake db:setup again and received the following error : LoadError: cannot load such file -- bundler/setup. Ran gem install bundler and tried running rake db:setup. I got this error: Could not find rake-12.0.0 in any of the sources Run bundle install to install missing gems. So I ran bundle install and got this.

--- ERROR REPORT TEMPLATE -------------------------------------------------------

Error Report

Questions

Please fill out answers to these questions, it'll help us figure out why things are going wrong.

Backtrace

RuntimeError: Unable to find a spec satisfying qa (>= 0) in the set. Perhaps the lockfile is corrupted?
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/spec_set.rb:39:in `block in for'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/spec_set.rb:24:in `loop'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/spec_set.rb:24:in `for'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/spec_set.rb:79:in `materialize'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/definition.rb:199:in `missing_dependencies'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/installer.rb:219:in `block in resolve_if_need'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/ui/shell.rb:127:in `with_level'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/ui/shell.rb:86:in `silence'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/installer.rb:216:in `resolve_if_need'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/installer.rb:78:in `run'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/installer.rb:24:in `install'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/cli/install.rb:70:in `run'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/cli.rb:186:in `block in install'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/settings.rb:100:in `temporary'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/cli.rb:185:in `install'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/vendor/thor/lib/thor.rb:369:in `dispatch'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/cli.rb:20:in `dispatch'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/vendor/thor/lib/thor/base.rb:444:in `start'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/cli.rb:10:in `start'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/exe/bundle:35:in `block in <top (required)>'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/lib/bundler/friendly_errors.rb:121:in `with_friendly_errors'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/bundler-1.15.1/exe/bundle:27:in `<top (required)>'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/bin/bundle:23:in `load'
  /Users/joymccaffrey/.rbenv/versions/2.3.1/bin/bundle:23:in `<main>'

Environment

Bundler   1.15.1
Rubygems  2.5.1
Ruby      2.3.1p112 (2016-04-26 revision 54768) [x86_64-darwin16]
GEM_HOME  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0
GEM_PATH  /Users/joymccaffrey/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0:/Users/joymccaffrey/.gem/ruby/2.3.0
Git       2.11.0
Platform  x86_64-darwin-16
OpenSSL   OpenSSL 1.0.2l  25 May 2017

Bundler settings

gem.test
  Set for the current user (/Users/joymccaffrey/.bundle/config): "rspec"
gem.mit
  Set for the current user (/Users/joymccaffrey/.bundle/config): "false"
gem.coc
  Set for the current user (/Users/joymccaffrey/.bundle/config): "false"

Gemfile

Gemfile

source 'https://rubygems.org'

gem 'devise'
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '~> 5.0.0'
# Use postgresql as the database for Active Record
gem 'pg', '~> 0.18'
# Use Puma as the app server
gem 'puma', '~> 3.0'
# Use SCSS for stylesheets
gem 'sass-rails', '~> 5.0'
# Use Uglifier as compressor for JavaScript assets
gem 'uglifier', '>= 1.3.0'
# Use CoffeeScript for .coffee assets and views
gem 'coffee-rails', '~> 4.2'

gem 'carrierwave'

gem 'rmagick'

gem 'fog'

gem 'twitter'
gem 'json'

# See https://github.com/rails/execjs#readme for more supported runtimes
# gem 'therubyracer', platforms: :ruby

# Use jquery as the JavaScript library
gem 'jquery-rails'
# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
gem 'turbolinks', '~> 5'
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
gem 'jbuilder', '~> 2.5'
gem 'font-awesome-rails'

# Use Redis adapter to run Action Cable in production
# gem 'redis', '~> 3.0'
# Use ActiveModel has_secure_password
# gem 'bcrypt', '~> 3.1.7'

# Use Capistrano for deployment
# gem 'capistrano-rails', group: :development
gem 'faker', '~> 1.6'
gem 'angular-rails-templates'
gem 'roo'
# gem 'searchkick'

group :development, :test do
  # Call 'byebug' anywhere in the code to stop execution and get a debugger console
  gem 'byebug', platform: :mri
  gem "rspec-rails", "3.5.0"
  gem "factory_girl_rails", "~> 4.0"
  gem 'pry-rails'
  gem 'dotenv-rails'
  gem 'shoulda-matchers', '~> 3.1'

end

group :test do
  gem "capybara", "2.7.1"
  gem "database_cleaner"
  gem 'phantomjs', :require => 'phantomjs/poltergeist'
  gem 'poltergeist'
  gem 'teaspoon-jasmine'
  gem 'launchy', '~> 2.4'

end

group :development do
  # Access an IRB console on exception pages or by using <%= console %> anywhere in the code.
  gem 'web-console'
  gem 'listen', '~> 3.0.5'
  # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
  gem 'spring'
  gem 'spring-watcher-listen', '~> 2.0.0'
end

# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]

Gemfile.lock

GEM
  remote: https://rubygems.org/
  specs:
    CFPropertyList (2.3.4)
    actioncable (5.0.1)
      actionpack (= 5.0.1)
      nio4r (~> 1.2)
      websocket-driver (~> 0.6.1)
    actionmailer (5.0.1)
      actionpack (= 5.0.1)
      actionview (= 5.0.1)
      activejob (= 5.0.1)
      mail (~> 2.5, >= 2.5.4)
      rails-dom-testing (~> 2.0)
    actionpack (5.0.1)
      actionview (= 5.0.1)
      activesupport (= 5.0.1)
      rack (~> 2.0)
      rack-test (~> 0.6.3)
      rails-dom-testing (~> 2.0)
      rails-html-sanitizer (~> 1.0, >= 1.0.2)
    actionview (5.0.1)
      activesupport (= 5.0.1)
      builder (~> 3.1)
      erubis (~> 2.7.0)
      rails-dom-testing (~> 2.0)
      rails-html-sanitizer (~> 1.0, >= 1.0.2)
    activejob (5.0.1)
      activesupport (= 5.0.1)
      globalid (>= 0.3.6)
    activemodel (5.0.1)
      activesupport (= 5.0.1)
    activerecord (5.0.1)
      activemodel (= 5.0.1)
      activesupport (= 5.0.1)
      arel (~> 7.0)
    activesupport (5.0.1)
      concurrent-ruby (~> 1.0, >= 1.0.2)
      i18n (~> 0.7)
      minitest (~> 5.1)
      tzinfo (~> 1.1)
    addressable (2.5.0)
      public_suffix (~> 2.0, >= 2.0.2)
    angular-rails-templates (1.0.2)
      railties (>= 4.2, < 6)
      sprockets (>= 3.0, < 5)
      tilt
    arel (7.1.4)
    bcrypt (3.1.11)
    buftok (0.2.0)
    builder (3.2.2)
    byebug (9.0.6)
    capybara (2.7.1)
      addressable
      mime-types (>= 1.16)
      nokogiri (>= 1.3.3)
      rack (>= 1.0.0)
      rack-test (>= 0.5.4)
      xpath (~> 2.0)
    carrierwave (1.0.0)
      activemodel (>= 4.0.0)
      activesupport (>= 4.0.0)
      mime-types (>= 1.16)
    cliver (0.3.2)
    coderay (1.1.1)
    coffee-rails (4.2.1)
      coffee-script (>= 2.2.0)
      railties (>= 4.0.0, < 5.2.x)
    coffee-script (2.4.1)
      coffee-script-source
      execjs
    coffee-script-source (1.12.2)
    concurrent-ruby (1.0.4)
    database_cleaner (1.5.3)
    debug_inspector (0.0.2)
    devise (4.2.0)
      bcrypt (~> 3.0)
      orm_adapter (~> 0.1)
      railties (>= 4.1.0, < 5.1)
      responders
      warden (~> 1.2.3)
    diff-lcs (1.2.5)
    domain_name (0.5.20161129)
      unf (>= 0.0.5, < 1.0.0)
    dotenv (2.1.1)
    dotenv-rails (2.1.1)
      dotenv (= 2.1.1)
      railties (>= 4.0, < 5.1)
    equalizer (0.0.11)
      qa
    erubis (2.7.0)
    excon (0.54.0)
    execjs (2.7.0)
    factory_girl (4.8.0)
      activesupport (>= 3.0.0)
    factory_girl_rails (4.8.0)
      factory_girl (~> 4.8.0)
      railties (>= 3.0.0)
    faker (1.7.2)
      i18n (~> 0.5)
    faraday (0.10.1)
      multipart-post (>= 1.2, < 3)
      qa
    ffi (1.9.14)
    fission (0.5.0)
      CFPropertyList (~> 2.2)
    fog (1.38.0)
      fog-aliyun (>= 0.1.0)
      fog-atmos
      fog-aws (>= 0.6.0)
      fog-brightbox (~> 0.4)
      fog-cloudatcost (~> 0.1.0)
      fog-core (~> 1.32)
      fog-dynect (~> 0.0.2)
      fog-ecloud (~> 0.1)
      fog-google (<= 0.1.0)
      fog-json
      fog-local
      fog-openstack
      fog-powerdns (>= 0.1.1)
      fog-profitbricks
      fog-rackspace
      fog-radosgw (>= 0.0.2)
      fog-riakcs
      fog-sakuracloud (>= 0.0.4)
      fog-serverlove
      fog-softlayer
      fog-storm_on_demand
      fog-terremark
      fog-vmfusion
      fog-voxel
      fog-vsphere (>= 0.4.0)
      fog-xenserver
      fog-xml (~> 0.1.1)
      ipaddress (~> 0.5)
    fog-aliyun (0.1.0)
      fog-core (~> 1.27)
      fog-json (~> 1.0)
      ipaddress (~> 0.8)
      xml-simple (~> 1.1)
    fog-atmos (0.1.0)
      fog-core
      fog-xml
    fog-aws (1.1.0)
      fog-core (~> 1.38)
      fog-json (~> 1.0)
      fog-xml (~> 0.1)
      ipaddress (~> 0.8)
    fog-brightbox (0.11.0)
      fog-core (~> 1.22)
      fog-json
      inflecto (~> 0.0.2)
    fog-cloudatcost (0.1.2)
      fog-core (~> 1.36)
      fog-json (~> 1.0)
      fog-xml (~> 0.1)
      ipaddress (~> 0.8)
    fog-core (1.43.0)
      builder
      excon (~> 0.49)
      formatador (~> 0.2)
    fog-dynect (0.0.3)
      fog-core
      fog-json
      fog-xml
    fog-ecloud (0.3.0)
      fog-core
      fog-xml
    fog-google (0.1.0)
      fog-core
      fog-json
      fog-xml
    fog-json (1.0.2)
      fog-core (~> 1.0)
      multi_json (~> 1.10)
    fog-local (0.3.1)
      fog-core (~> 1.27)
    fog-openstack (0.1.18)
      fog-core (>= 1.40)
      fog-json (>= 1.0)
      ipaddress (>= 0.8)
    fog-powerdns (0.1.1)
      fog-core (~> 1.27)
      fog-json (~> 1.0)
      fog-xml (~> 0.1)
    fog-profitbricks (3.0.0)
      fog-core (~> 1.42)
      fog-json (~> 1.0)
    fog-rackspace (0.1.2)
      fog-core (>= 1.35)
      fog-json (>= 1.0)
      fog-xml (>= 0.1)
      ipaddress (>= 0.8)
    fog-radosgw (0.0.5)
      fog-core (>= 1.21.0)
      fog-json
      fog-xml (>= 0.0.1)
    fog-riakcs (0.1.0)
      fog-core
      fog-json
      fog-xml
    fog-sakuracloud (1.7.5)
      fog-core
      fog-json
    fog-serverlove (0.1.2)
      fog-core
      fog-json
    fog-softlayer (1.1.4)
      fog-core
      fog-json
    fog-storm_on_demand (0.1.1)
      fog-core
      fog-json
    fog-terremark (0.1.0)
      fog-core
      fog-xml
    fog-vmfusion (0.1.0)
      fission
      fog-core
    fog-voxel (0.1.0)
      fog-core
      fog-xml
    fog-vsphere (1.6.0)
      fog-core
      rbvmomi (~> 1.9)
    fog-xenserver (0.2.3)
      fog-core
      fog-xml
    fog-xml (0.1.2)
      fog-core
      nokogiri (~> 1.5, >= 1.5.11)
    font-awesome-rails (4.7.0.1)
      railties (>= 3.2, < 5.1)
    formatador (0.2.5)
    globalid (0.3.7)
      activesupport (>= 4.1.0)
    http (2.1.0)
      addressable (~> 2.3)
      http-cookie (~> 1.0)
      http-form_data (~> 1.0.1)
      http_parser.rb (~> 0.6.0)
    http-cookie (1.0.3)
      domain_name (~> 0.5)
    http-form_data (1.0.1)
    http_parser.rb (0.6.0)
      qa
    i18n (0.7.0)
    inflecto (0.0.2)
    ipaddress (0.8.3)
    jbuilder (2.6.1)
      activesupport (>= 3.0.0, < 5.1)
      multi_json (~> 1.2)
    jquery-rails (4.2.2)
      rails-dom-testing (>= 1, < 3)
      railties (>= 4.2.0)
      thor (>= 0.14, < 2.0)
    json (2.0.2)
    launchy (2.4.3)
      addressable (~> 2.3)
    listen (3.0.8)
      rb-fsevent (~> 0.9, >= 0.9.4)
      rb-inotify (~> 0.9, >= 0.9.7)
    loofah (2.0.3)
      nokogiri (>= 1.5.9)
    mail (2.6.4)
      mime-types (>= 1.16, < 4)
    memoizable (0.4.2)
      thread_safe (~> 0.3, >= 0.3.1)
    method_source (0.8.2)
    mime-types (3.1)
      mime-types-data (~> 3.2015)
    mime-types-data (3.2016.0521)
    mini_portile2 (2.1.0)
    minitest (5.10.1)
    multi_json (1.12.1)
    multipart-post (2.0.0)
    naught (1.1.0)
      qa
    nio4r (1.2.1)
    nokogiri (1.7.0)
      mini_portile2 (~> 2.1.0)
    orm_adapter (0.5.0)
    pg (0.19.0)
    phantomjs (2.1.1.0)
    poltergeist (1.12.0)
      capybara (~> 2.1)
      cliver (~> 0.3.1)
      websocket-driver (>= 0.2.0)
    pry (0.10.4)
      coderay (~> 1.1.0)
      method_source (~> 0.8.1)
      slop (~> 3.4)
    pry-rails (0.3.4)
      pry (>= 0.9.10)
    public_suffix (2.0.5)
    puma (3.6.2)
    rack (2.0.1)
    rack-test (0.6.3)
      rack (>= 1.0)
    rails (5.0.1)
      actioncable (= 5.0.1)
      actionmailer (= 5.0.1)
      actionpack (= 5.0.1)
      actionview (= 5.0.1)
      activejob (= 5.0.1)
      activemodel (= 5.0.1)
      activerecord (= 5.0.1)
      activesupport (= 5.0.1)
      bundler (>= 1.3.0, < 2.0)
      railties (= 5.0.1)
      sprockets-rails (>= 2.0.0)
    rails-dom-testing (2.0.2)
      activesupport (>= 4.2.0, < 6.0)
      nokogiri (~> 1.6)
    rails-html-sanitizer (1.0.3)
      loofah (~> 2.0)
    railties (5.0.1)
      actionpack (= 5.0.1)
      activesupport (= 5.0.1)
      method_source
      rake (>= 0.8.7)
      thor (>= 0.18.1, < 2.0)
    rake (12.0.0)
    rb-fsevent (0.9.8)
    rb-inotify (0.9.7)
      ffi (>= 0.5.0)
    rbvmomi (1.9.4)
      builder (~> 3.2)
      json (>= 1.8)
      nokogiri (~> 1.5)
      trollop (~> 2.1)
    responders (2.3.0)
      railties (>= 4.2.0, < 5.1)
    rmagick (2.16.0)
    roo (2.7.0)
      nokogiri (~> 1)
      rubyzip (~> 1.1, < 2.0.0)
    rspec-core (3.5.4)
      rspec-support (~> 3.5.0)
    rspec-expectations (3.5.0)
      diff-lcs (>= 1.2.0, < 2.0)
      rspec-support (~> 3.5.0)
    rspec-mocks (3.5.0)
      diff-lcs (>= 1.2.0, < 2.0)
      rspec-support (~> 3.5.0)
    rspec-rails (3.5.0)
      actionpack (>= 3.0)
      activesupport (>= 3.0)
      railties (>= 3.0)
      rspec-core (~> 3.5.0)
      rspec-expectations (~> 3.5.0)
      rspec-mocks (~> 3.5.0)
      rspec-support (~> 3.5.0)
    rspec-support (3.5.0)
    rubyzip (1.2.0)
    sass (3.4.23)
    sass-rails (5.0.6)
      railties (>= 4.0.0, < 6)
      sass (~> 3.1)
      sprockets (>= 2.8, < 4.0)
      sprockets-rails (>= 2.0, < 4.0)
      tilt (>= 1.1, < 3)
    shoulda-matchers (3.1.1)
      activesupport (>= 4.0.0)
    simple_oauth (0.3.1)
    slop (3.6.0)
    spring (2.0.0)
      activesupport (>= 4.2)
    spring-watcher-listen (2.0.1)
      listen (>= 2.7, < 4.0)
      spring (>= 1.2, < 3.0)
    sprockets (3.7.1)
      concurrent-ruby (~> 1.0)
      rack (> 1, < 3)
    sprockets-rails (3.2.0)
      actionpack (>= 4.0)
      activesupport (>= 4.0)
      sprockets (>= 3.0.0)
    teaspoon (1.1.5)
      railties (>= 3.2.5, < 6)
    teaspoon-jasmine (2.3.4)
      teaspoon (>= 1.0.0)
    thor (0.19.4)
    thread_safe (0.3.5)
    tilt (2.0.5)
    trollop (2.1.2)
    turbolinks (5.0.1)
      turbolinks-source (~> 5)
    turbolinks-source (5.0.0)
    twitter (6.0.0)
      addressable (~> 2.5)
      buftok (~> 0.2.0)
      equalizer (= 0.0.11)
      faraday (~> 0.10.0)
      http (~> 2.1)
      http_parser.rb (~> 0.6.0)
      memoizable (~> 0.4.2)
      naught (~> 1.1)
      simple_oauth (~> 0.3.1)
    tzinfo (1.2.2)
      thread_safe (~> 0.1)
    uglifier (3.0.4)
      execjs (>= 0.3.0, < 3)
    unf (0.1.4)
      unf_ext
    unf_ext (0.0.7.2)
    warden (1.2.6)
      rack (>= 1.0)
    web-console (3.4.0)
      actionview (>= 5.0)
      activemodel (>= 5.0)
      debug_inspector
      railties (>= 5.0)
    websocket-driver (0.6.4)
      websocket-extensions (>= 0.1.0)
    websocket-extensions (0.1.2)
    xml-simple (1.1.5)
    xpath (2.0.0)
      nokogiri (~> 1.3)

PLATFORMS
  ruby

DEPENDENCIES
  angular-rails-templates
  byebug
  capybara (= 2.7.1)
  carrierwave
  coffee-rails (~> 4.2)
  database_cleaner
  devise
  dotenv-rails
  factory_girl_rails (~> 4.0)
  faker (~> 1.6)
  fog
  font-awesome-rails
  jbuilder (~> 2.5)
  jquery-rails
  json
  launchy (~> 2.4)
  listen (~> 3.0.5)
  pg (~> 0.18)
  phantomjs
  poltergeist
  pry-rails
  puma (~> 3.0)
  rails (~> 5.0.0)
  rmagick
  roo
  rspec-rails (= 3.5.0)
  sass-rails (~> 5.0)
  shoulda-matchers (~> 3.1)
  spring
  spring-watcher-listen (~> 2.0.0)
  teaspoon-jasmine
  turbolinks (~> 5)
  twitter
  tzinfo-data
  uglifier (>= 1.3.0)
  web-console

BUNDLED WITH
   1.12.5

--- TEMPLATE END ----------------------------------------------------------------

Unfortunately, an unexpected error occurred, and Bundler cannot continue.

First, try this link to see if there are any existing issue reports for this error: https://github.com/bundler/bundler/search?q=Unable+to+find+a+spec+satisfying+qa+%28%3E%3D+0%29+in+the+set.+Perhaps+the+lockfile+is+corrupted%3F&type=Issues

If there aren't any reports for this error yet, please create copy and paste the report template above into a new issue. Don't forget to anonymize any private data! The new issue form is located at: https://github.com/bundler/bundler/issues/new

Please help. :)

segiddins commented 7 years ago

Your lockfile appears to be corrupted -- it is indeed missing the qa specification in the list of specs

chijoy commented 7 years ago

Great! I assume you're referring to the Gemfile.lock, where there are a number of references to qa. And by specification do you mean a version number following it? And if so, which one, and how do I uncorrupt it? Or is it missing a qa specification in the Gemfile.lock, and if so, how do I add it? And how would this have happened? This is the first time I'm looking at this project's code. Thanks for your help!

segiddins commented 7 years ago

And how would this have happened?

Old versions of Bundler were buggy and somehow didn't put all the specs in the Lockfile. I haven't seen this happen with versions of bundler >= 1.13 so I don't know the specifics

colby-swandale commented 7 years ago

I'm closing this for now. If you're still experiencing your original issue or have any more questions don't be afraid to re-open this ticket.

anthony-vin65 commented 7 years ago

@colby-swandale - I am seeing the same issue with bundler 1.15.0 in AWS Elastic Beanstalk environment. I created a sample Rails app (eg. rails new sample) added .ebextensions/01_infra.config with the following environment variables being set just to satisfy the environment enough to get running:

option_settings: aws:elasticbeanstalk:application:environment: SECRET_KEY_BASE: <key> RAILS_SKIP_MIGRATIONS: true

And when I deploy I can see the following in the log file:

/opt/rubies/ruby-2.3.4/lib/ruby/gems/2.3.0/gems/bundler-1.15.0/lib/bundler/spec_set.rb:39:in 'block in for': Unable to find a spec satisfying byebug in the set. Perhaps the lockfile is corrupted? (RuntimeError) from /opt/rubies/ruby-2.3.4/lib/ruby/gems/2.3.0/gems/bundler-1.15.0/lib/bundler/spec_set.rb:24:in 'loop' from /opt/rubies/ruby-2.3.4/lib/ruby/gems/2.3.0/gems/bundler-1.15.0/lib/bundler/spec_set.rb:24:in 'for' from /opt/rubies/ruby-2.3.4/lib/ruby/gems/2.3.0/gems/bundler-1.15.0/lib/bundler/definition.rb:218:in 'specs_for' from ./check-for-gem.rb:27:in '<main>'

Doing some debugging, it looks like the call to Bundler.definitions.groups isn't returning the expected results. However, if I downgrade the bundler to 1.13.6 it seems to work. What is the difference between 1.13.6 and 1.15.0 in how Bundler determines the groups?

colby-swandale commented 7 years ago

@anthony-vin65 please open a new issue with the details of your problem.

kaoru commented 7 years ago

@anthony-vin65 @colby-swandale I'm also having this issue with AWS ElasticBeanstalk today, after upgrading to their latest Ruby Puma Amazon Linux image. Did Anthony open a new issue for this one yet?

Anthony - you said you were able to downgrade to 1.13.6 to solve the problem.

Colby - Elastic Beanstalk is failing in a script they've provided called check-for-gem.rb:

#!/usr/bin/env /opt/rubies/ruby-current/bin/ruby
#==============================================================================
# Copyright 2014 Amazon.com, Inc. or its affiliates. All Rights Reserved.
#
# Licensed under the Amazon Software License (the "License"). You may not use
# this file except in compliance with the License. A copy of the License is
# located at
#
#       https://aws.amazon.com/asl/
#
# or in the "license" file accompanying this file. This file is distributed on
# an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, express or
# implied. See the License for the specific language governing permissions
# and limitations under the License.
#==============================================================================
require 'bundler'

Dir.chdir '/var/app/ondeck'
groups = Bundler.definition.groups

begin
    Bundler.definition.resolve_with_cache!
rescue Bundler::GemNotFound
    Bundler.definition(true).resolve_remotely!
end

gems = Bundler.definition.specs_for(groups).collect(&:name)
exit 0 if gems.include? ARGV[0]

Tweaking that slightly I get:

irb(main):014:0> groups.map { |g| Bundler.definition.specs_for([g]).count rescue "#{g} failed" }
=> [197, 11, "development failed", "test failed"]

Whereas on an older AWS ElasticBeanstalk box running bundler 1.12.1 I get:

irb(main):005:0> groups.map { |g| Bundler.definition.specs_for([g]).count rescue "#{g} failed" }
=> [197, 11, 1, 1]
irb(main):007:0> groups.map { |g| Bundler.definition.specs_for([g]).collect(&:name).first rescue "#{g} failed" }
=> ["rake", "i18n", "bundler", "bundler"]

ie. it looks like the change in behaviour is that bundler always used to count itself in the definiton for empty groups, but now it doesn't and fails on empty groups.

Test and Development groups are "empty" because of:

$ cat .bundle/config 
---
BUNDLE_DISABLE_SHARED_GEMS: "true"
BUNDLE_WITHOUT: "test:development"

I think?


Sorry to dump this comment on a closed issue. Hopefully @anthony-vin65 has opened his new issue and these details can be copied over to that one if they're still relevant.

Thanks!

colby-swandale commented 7 years ago

@kaoru A new issue was never opened, it would be appreciated if you opened a new issue with the details of your problem. You can follow Bundler's ISSUES guide for more information.

kaoru commented 7 years ago

@colby-swandale I've managed to reproduce the issue with a small example, and opened an issue here: https://github.com/bundler/bundler/issues/6017

woo37830 commented 5 years ago

I did rbenv install 2.6.1 as per instructions on how to install rails on Mojave. I checked it's version, etc. Then cd'd to my rails-devise-user directory cloned from GitHub. It worked on a High Sierra laptop. Now, I type rails -v and it says: version 2.3.1 is not installed. It is specified in the Gemfile. I then do: rbenv install 2.3.1. It installs. Then type rails -v and get rbenv: rails: command not found

The `rails' command exists in these Ruby versions: 2.6.1

What is going on? On the high sierra laptop, that command works fine?