Formerly passing build now fails

Getting errors on Circle Ci that are inconsistent with local and Heroku builds

The stack you’re using

Ruby 2.3, Ruby on Rails 5.0.1

The exact error message you are getting

export RAILS_ENV=“test”
export RACK_ENV=“test”
bundle exec rake db:create db:schema:load --trace
rake aborted!
LoadError: libruby.so.2.3: cannot open shared object file: No such file or directory - /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/bcrypt-3.1.11/lib/bcrypt_ext.so
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.1/lib/active_support/dependencies.rb:293:in require' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.1/lib/active_support/dependencies.rb:293:in block in require’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.1/lib/active_support/dependencies.rb:259:in load_dependency' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.1/lib/active_support/dependencies.rb:293:in require’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/bcrypt-3.1.11/lib/bcrypt.rb:16:in rescue in <top (required)>' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/bcrypt-3.1.11/lib/bcrypt.rb:12:in <top (required)>’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:91:in require' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:91:in block (2 levels) in require’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:86:in each' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:86:in block in require’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:75:in each' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:75:in require’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler.rb:106:in require' /home/ubuntu/designershare-server/config/application.rb:19:in <top (required)>’
/home/ubuntu/designershare-server/Rakefile:4:in require_relative' /home/ubuntu/designershare-server/Rakefile:4:in <top (required)>’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/rake_module.rb:28:in load' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/rake_module.rb:28:in load_rakefile’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:687:in raw_load_rakefile' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:96:in block in load_rakefile’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:178:in standard_exception_handling' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:95:in load_rakefile’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:79:in block in run' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:178:in standard_exception_handling’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:77:in run' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/exe/rake:27:in <top (required)>’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/bin/rake:22:in load' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/bin/rake:22:in <top (required)>’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli/exec.rb:74:in load' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli/exec.rb:74:in kernel_load’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli/exec.rb:27:in run' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli.rb:332:in exec’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/vendor/thor/lib/thor/command.rb:27:in run' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in invoke_command’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/vendor/thor/lib/thor.rb:359:in dispatch' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli.rb:20:in dispatch’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/vendor/thor/lib/thor/base.rb:440:in start' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli.rb:11:in start’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/exe/bundle:34:in block in <top (required)>' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/friendly_errors.rb:100:in with_friendly_errors’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/exe/bundle:26:in <top (required)>' /opt/circleci/.rvm/gems/ruby-2.3.3/bin/bundle:22:in load’
/opt/circleci/.rvm/gems/ruby-2.3.3/bin/bundle:22:in <main>' LoadError: cannot load such file -- 2.3/bcrypt_ext /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.1/lib/active_support/dependencies.rb:293:in require’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.1/lib/active_support/dependencies.rb:293:in block in require' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.1/lib/active_support/dependencies.rb:259:in load_dependency’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.1/lib/active_support/dependencies.rb:293:in require' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/bcrypt-3.1.11/lib/bcrypt.rb:14:in <top (required)>’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:91:in require' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:91:in block (2 levels) in require’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:86:in each' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:86:in block in require’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:75:in each' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/runtime.rb:75:in require’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler.rb:106:in require' /home/ubuntu/designershare-server/config/application.rb:19:in <top (required)>’
/home/ubuntu/designershare-server/Rakefile:4:in require_relative' /home/ubuntu/designershare-server/Rakefile:4:in <top (required)>’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/rake_module.rb:28:in load' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/rake_module.rb:28:in load_rakefile’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:687:in raw_load_rakefile' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:96:in block in load_rakefile’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:178:in standard_exception_handling' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:95:in load_rakefile’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:79:in block in run' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:178:in standard_exception_handling’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/lib/rake/application.rb:77:in run' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/exe/rake:27:in <top (required)>’
/home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/bin/rake:22:in load' /home/ubuntu/designershare-server/vendor/bundle/ruby/2.3.0/bin/rake:22:in <top (required)>’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli/exec.rb:74:in load' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli/exec.rb:74:in kernel_load’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli/exec.rb:27:in run' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli.rb:332:in exec’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/vendor/thor/lib/thor/command.rb:27:in run' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in invoke_command’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/vendor/thor/lib/thor.rb:359:in dispatch' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli.rb:20:in dispatch’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/vendor/thor/lib/thor/base.rb:440:in start' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/cli.rb:11:in start’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/exe/bundle:34:in block in <top (required)>' /opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/lib/bundler/friendly_errors.rb:100:in with_friendly_errors’
/opt/circleci/.rvm/gems/ruby-2.3.3/gems/bundler-1.13.7/exe/bundle:26:in <top (required)>' /opt/circleci/.rvm/gems/ruby-2.3.3/bin/bundle:22:in load’
/opt/circleci/.rvm/gems/ruby-2.3.3/bin/bundle:22:in `’

export RAILS_ENV="test"
export RACK_ENV="test"
bundle exec rake db:create db:schema:load --trace
 returned exit code 1
Action failed: rake db:create db:schema:load

Which troubleshooting steps you’ve already taken

  • Tried locking down the nokogiri gem version to 1.7.0 , which we suspected to be the cause, but that didn’t change the behavior.
  • Tried to rebuild without cache, no dice

Any recent changes either in the codebase or the stack

None. We have previously passing builds now failing.

Build # 234 on our account is an example (can share link with support)

What happens when you run the tests locally

Full pass. Same with Heroku.

What is supposed to happen when your build runs

Full pass, as before

The build URL if the project is public

Private repo

Try rebuilding without cache. It worked for us.

1 Like

Any news on this?

We have to rebuild every single build without cache because of this issue.

Same here. Starting this morning we have random gems that fail during the bundle step. It’s not always the same gem, either.

I’ve already opened a support ticket on this as well.

Same issues - running Rails 5.0.2 - started on 4/7 - rerunning passed builds from 4/6 results in failures during bundle install. Starts with "ruby-2.3.1 is not installed - installing."
bundle install # from builds on 4/6/17
bundle check --path=vendor/bundle || bundle install --path=vendor/bundle --jobs=4 --retry=3
Warning: the running version of Bundler (1.13.7) is older than the version that created the lockfile (1.14.5).
The Gemfile’s dependencies are satisfied
emphasized text
bundle install # from rerun of builds on 4/7/17
bundle check --path=vendor/bundle || bundle install --path=vendor/bundle --jobs=4 --retry=3
ruby-2.3.1 is not installed - installing.
Searching for binary rubies, this might take some time.
Found remote file https://rubies.travis-ci.org/ubuntu/14.04/x86_64/ruby-2.3.1.tar.bz2

… # leading to error during install from some seemingly random gem

UPDATE - I got my builds to pass again by adding this to the circle.yml

dependencies:
pre:

  • gem install bundler -v 1.14.5