2

I have trouble with Heroku. My app succesffuly download on Heroku, but when I try to run rake db:migrate, I get this:

rake aborted!
LoadError: libruby.so.2.5: cannot open shared object file: No such file or directory - /app/vendor/bundle/ruby/2.5.0/gems/msgpack-1.3.1/lib/msgpack/msgpack.so
/app/vendor/bundle/ruby/2.5.0/gems/msgpack-1.3.1/lib/msgpack.rb:11:in `require'
/app/vendor/bundle/ruby/2.5.0/gems/msgpack-1.3.1/lib/msgpack.rb:11:in `rescue in <top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/msgpack-1.3.1/lib/msgpack.rb:8:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/load_path_cache/store.rb:4:in `require'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/load_path_cache/store.rb:4:in `block in <top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/explicit_require.rb:44:in `rescue in with_gems'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/explicit_require.rb:40:in `with_gems'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/load_path_cache/store.rb:4:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/load_path_cache.rb:74:in `require_relative'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/load_path_cache.rb:74:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap.rb:4:in `require_relative'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap.rb:4:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/setup.rb:2:in `require_relative'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/setup.rb:2:in `<top (required)>'
/app/config/boot.rb:4:in `require'
/app/config/boot.rb:4:in `<top (required)>'
/app/config/application.rb:1:in `require_relative'
/app/config/application.rb:1:in `<top (required)>'
/app/Rakefile:4:in `require_relative'
/app/Rakefile:4:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli/exec.rb:74:in `load'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli/exec.rb:74:in `kernel_load'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli/exec.rb:28:in `run'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli.rb:463:in `exec'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor.rb:387:in `dispatch'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli.rb:27:in `dispatch'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor/base.rb:466:in `start'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli.rb:18:in `start'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/exe/bundle:30:in `block in <top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/friendly_errors.rb:124:in `with_friendly_errors'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/exe/bundle:22:in `<top (required)>'
/app/bin/bundle:104:in `load'
/app/bin/bundle:104:in `<main>'


Caused by:
LoadError: cannot load such file -- msgpack/2.5/msgpack
/app/vendor/bundle/ruby/2.5.0/gems/msgpack-1.3.1/lib/msgpack.rb:9:in `require'
/app/vendor/bundle/ruby/2.5.0/gems/msgpack-1.3.1/lib/msgpack.rb:9:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/load_path_cache/store.rb:4:in `require'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/load_path_cache/store.rb:4:in `block in <top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/explicit_require.rb:41:in `with_gems'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/load_path_cache/store.rb:4:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/load_path_cache.rb:74:in `require_relative'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/load_path_cache.rb:74:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap.rb:4:in `require_relative'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap.rb:4:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/setup.rb:2:in `require_relative'
/app/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.4.6/lib/bootsnap/setup.rb:2:in `<top (required)>'
/app/config/boot.rb:4:in `require'
/app/config/boot.rb:4:in `<top (required)>'
/app/config/application.rb:1:in `require_relative'
/app/config/application.rb:1:in `<top (required)>'
/app/Rakefile:4:in `require_relative'
/app/Rakefile:4:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli/exec.rb:74:in `load'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli/exec.rb:74:in `kernel_load'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli/exec.rb:28:in `run'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli.rb:463:in `exec'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor.rb:387:in `dispatch'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli.rb:27:in `dispatch'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor/base.rb:466:in `start'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/cli.rb:18:in `start'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/exe/bundle:30:in `block in <top (required)>'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/lib/bundler/friendly_errors.rb:124:in `with_friendly_errors'
/app/vendor/bundle/ruby/2.5.0/gems/bundler-1.17.3/exe/bundle:22:in `<top (required)>'
/app/bin/bundle:104:in `load'
/app/bin/bundle:104:in `<main>'

In gemfile I set gem 'msgpack', '1.3.1', it doesn't help. I think that troublein my ruby version, because Heroku search this gem in folder '2.5.0', but I have ruby version '2.5.1'. I don't know how I can change version.

Also I try to recreate app in Heroku, but it doesn't help me.

DmitrBayan
  • 21
  • 2
  • Heroku is going to be looking at the .ruby-version file and the ruby version declaration in your Gemfile. So if you have .ruby-version as 2.5.0, Heroku is going to go with that version of Ruby, even if locally you're using version 2.5.1. However - this error suggests that you've been committing your vendor/bundle into source control, and it looks like this module isn't in that bundle. So make sure it isn't .gitignored if you *want* it committed - but in my experience is better *not* to commit this and let Heroku gem install dependencies. – tgmerritt May 05 '20 at 22:05
  • Thanks for you answer! I solve my problem by change SQLite gem on PostgresQL gem – DmitrBayan May 14 '20 at 13:11

0 Answers0