Discussion:
./bin/rake db:migrate db:seed db:test:prepare Fails
i***@tutanota.com
2018-06-20 10:57:39 UTC
Permalink
Referring to the link: [[https://www.openproject.org/development/setting-up-development-environment/ <https://www.openproject.org/development/setting-up-development-environment/>]]
I was setting up the development environment of an opensource project developed in Ruby  : openproject  in ubuntu 16, gnome-terminal. But it fails in the following step.
./bin/rake db:migrate db:seed db:test:prepare
Traceback (most recent call last):
    4: from ./bin/rake:2:in `<main>'
    3: from ./bin/rake:2:in `require_relative'
    2: from /home/tanzeem/openproject-dev/openproject/config/boot.rb:39:in `<top (required)>'
    1: from /home/tanzeem/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/rubygems/core_ext/kernel_require.rb:59:in `require'
/home/tanzeem/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/rubygems/core_ext/kernel_require.rb:59:in `require': cannot load such file -- bundler/setup (LoadError)

I tried again with the following command.
sudo ./bin/rake db:migrate db:seed db:test:prepareBut it gives the error
Your Ruby version is 2.3.1, but your Gemfile specified ~> 2.5.1

I tried again with the following command.bundle exec rake db:migrate db:seed db:test:prepareBut it gives the error
/usr/lib/ruby/2.3.0/rubygems/dependency.rb:319:in `to_specs': Could not find 'bundler' (>= 0.a) among 18 total gem(s) (Gem::LoadError)
Checked in 'GEM_PATH=/home/tanzeem/.rvm/gems/ruby-2.5.1:/home/tanzeem/.rvm/gems/ruby-***@global', execute `gem env` for more information
    from /usr/lib/ruby/2.3.0/rubygems/dependency.rb:328:in `to_spec'
    from /usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_gem.rb:65:in `gem'
    from /usr/local/bin/bundle:22:in `<main>'
I already has ruby2.3 installed. Since my requirement is ruby-2.5.1 I installed it through rvm and set it as default before doing the above steps.
Please help me in resolving the problem.
--
Securely sent with Tutanota. Claim your encrypted mailbox today!
https://tutanota.com <https://tutanota.com>
ag82pishi
2018-06-20 11:17:58 UTC
Permalink
set rvm
[[https://www.openproject.org/development/setting-up-development-environment/]]
I was setting up the development environment of an opensource project
developed in Ruby  : openproject  in ubuntu 16, gnome-terminal. But it
fails in the following step.
./bin/rake db:migrate db:seed db:test:prepare
    4: from ./bin/rake:2:in `<main>'
    3: from ./bin/rake:2:in `require_relative'
    2: from
/home/tanzeem/openproject-dev/openproject/config/boot.rb:39:in `<top
(required)>'
    1: from
/home/tanzeem/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/rubygems/core_ext/kernel_require.rb:59:in
`require'
/home/tanzeem/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/rubygems/core_ext/kernel_require.rb:59:in
`require': cannot load such file -- bundler/setup (LoadError)
I tried again with the following command.
sudo ./bin/rake db:migrate db:seed db:test:prepare
But it gives the error
Your Ruby version is 2.3.1, but your Gemfile specified ~> 2.5.1
I tried again with the following command.
bundle exec rake db:migrate db:seed db:test:prepare
But it gives the error
/usr/lib/ruby/2.3.0/rubygems/dependency.rb:319:in `to_specs': Could
not find 'bundler' (>= 0.a) among 18 total gem(s) (Gem::LoadError)
Checked in
execute `gem env` for more information
    from /usr/lib/ruby/2.3.0/rubygems/dependency.rb:328:in `to_spec'
    from /usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_gem.rb:65:in `gem'
    from /usr/local/bin/bundle:22:in `<main>'
I already has ruby2.3 installed. Since my requirement is ruby-2.5.1 I
installed it through rvm and set it as default before doing the above
steps.
Please help me in resolving the problem.
--
Securely sent with Tutanota. Claim your encrypted mailbox today!
https://tutanota.com
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-talk>
Hassan Schroeder
2018-06-20 14:38:02 UTC
Permalink
Post by i***@tutanota.com
./bin/rake db:migrate db:seed db:test:prepare
/home/tanzeem/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/rubygems/core_ext/kernel_require.rb:59:in
`require': cannot load such file -- bundler/setup (LoadError)
Do you have bundler installed?
Post by i***@tutanota.com
I tried again with the following command.
sudo ./bin/rake db:migrate db:seed db:test:prepare
Horrible idea; now you probably have files in your project owned
by root, which will cause further problems. Revert those before
anything else, and then fix the initial bundler issue.
--
Hassan Schroeder ------------------------ ***@gmail.com
twitter: @hassan
Consulting Availability : Silicon Valley or remote

Unsubscribe: <mailto:ruby-talk-***@ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-talk>
Loading...